aboutsummaryrefslogtreecommitdiff
path: root/src/llvm_backend_expr.cpp
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2021-10-20 12:48:48 +0100
committergingerBill <bill@gingerbill.org>2021-10-20 12:48:48 +0100
commit1bfbed0e02b4cd947acf9693f09016ec609356e1 (patch)
tree13793af9dc90f514708c1aefa0927fad80696a8c /src/llvm_backend_expr.cpp
parent0fd525d7789d2a0786b28677c5dd4cbd263f4537 (diff)
Add `llvm_vector_reduce_add`
Diffstat (limited to 'src/llvm_backend_expr.cpp')
-rw-r--r--src/llvm_backend_expr.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/llvm_backend_expr.cpp b/src/llvm_backend_expr.cpp
index 6cb221a94..18d5e267b 100644
--- a/src/llvm_backend_expr.cpp
+++ b/src/llvm_backend_expr.cpp
@@ -619,9 +619,10 @@ lbValue lb_emit_matrix_mul_vector(lbProcedure *p, lbValue lhs, lbValue rhs, Type
Type *elem = mt->Matrix.elem;
LLVMTypeRef elem_type = lb_type(p->module, elem);
- unsigned stride = cast(unsigned)matrix_type_stride_in_elems(mt);
if (lb_matrix_elem_simple(mt)) {
+ unsigned stride = cast(unsigned)matrix_type_stride_in_elems(mt);
+
unsigned row_count = cast(unsigned)mt->Matrix.row_count; gb_unused(row_count);
unsigned column_count = cast(unsigned)mt->Matrix.column_count;
auto m_columns = slice_make<LLVMValueRef>(permanent_allocator(), column_count);