diff options
| author | Ginger Bill <bill@gingerbill.org> | 2017-05-01 15:05:56 +0100 |
|---|---|---|
| committer | Ginger Bill <bill@gingerbill.org> | 2017-05-01 15:05:56 +0100 |
| commit | fae5df2ed8663d52c691802a7c11105ea28267ed (patch) | |
| tree | 15e9e07fa6bbe1f85b8c221c1fd14e45c6bf89ac /src | |
| parent | 01d9161772270aab523cea47f02db26e95218b43 (diff) | |
Fix IR vector arith conv bug
Diffstat (limited to 'src')
| -rw-r--r-- | src/ir.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -1820,6 +1820,8 @@ irValue *ir_emit_arith(irProcedure *proc, TokenKind op, irValue *left, irValue * ir_emit_comment(proc, str_lit("vector.arith.begin")); // IMPORTANT TODO(bill): This is very wasteful with regards to stack memory Type *tl = base_type(t_left); + left = ir_emit_conv(proc, left, type); + right = ir_emit_conv(proc, right, type); irValue *lhs = ir_address_from_load_or_generate_local(proc, left); irValue *rhs = ir_address_from_load_or_generate_local(proc, right); GB_ASSERT(is_type_vector(type)); |