diff options
| author | Andrew Kelley <superjoe30@gmail.com> | 2017-01-05 03:29:50 -0500 |
|---|---|---|
| committer | Andrew Kelley <superjoe30@gmail.com> | 2017-01-05 03:29:50 -0500 |
| commit | 9d94c2ccd0341961ffb18ec7eb40ef6099d71794 (patch) | |
| tree | 0aea7ad32eadd1db0756e40468e859e6bb73087d /src | |
| parent | 349cd79fe433e165bf6cc7fc614dc5851ac86b6e (diff) | |
| download | zig-9d94c2ccd0341961ffb18ec7eb40ef6099d71794.tar.gz zig-9d94c2ccd0341961ffb18ec7eb40ef6099d71794.zip | |
fix mul and sub overflow ops being rendered as addition
Diffstat (limited to 'src')
| -rw-r--r-- | src/codegen.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/codegen.cpp b/src/codegen.cpp index c5d8144143..a1c89c239b 100644 --- a/src/codegen.cpp +++ b/src/codegen.cpp @@ -1983,10 +1983,10 @@ static LLVMValueRef ir_render_overflow_op(CodeGen *g, IrExecutable *executable, add_sub_mul = AddSubMulAdd; break; case IrOverflowOpSub: - add_sub_mul = AddSubMulAdd; + add_sub_mul = AddSubMulSub; break; case IrOverflowOpMul: - add_sub_mul = AddSubMulAdd; + add_sub_mul = AddSubMulMul; break; case IrOverflowOpShl: return render_shl_with_overflow(g, instruction); |
