diff options
| author | Jacob Young <jacobly0@users.noreply.github.com> | 2022-11-02 22:57:10 -0400 |
|---|---|---|
| committer | Jacob Young <jacobly0@users.noreply.github.com> | 2022-11-02 23:00:10 -0400 |
| commit | 085f6fd8f729423158b6f7a5f8e6f50f78fef18f (patch) | |
| tree | 3765fe467ab9f75b70591eb9fab4d798aac97284 /src/codegen | |
| parent | 4537c1b8b6575c853ceaa7ab329e8b84d946249d (diff) | |
| download | zig-085f6fd8f729423158b6f7a5f8e6f50f78fef18f.tar.gz zig-085f6fd8f729423158b6f7a5f8e6f50f78fef18f.zip | |
cbe: use wrapping for left shifts
Diffstat (limited to 'src/codegen')
| -rw-r--r-- | src/codegen/c.zig | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/codegen/c.zig b/src/codegen/c.zig index 4473f680c4..980dfb5ff2 100644 --- a/src/codegen/c.zig +++ b/src/codegen/c.zig @@ -2434,7 +2434,7 @@ fn genBody(f: *Function, body: []const Air.Inst.Index) error{ AnalysisFail, OutO .bool_or, .bit_or => try airBinOp(f, inst, "|", "or", .None), .xor => try airBinOp(f, inst, "^", "xor", .None), .shr, .shr_exact => try airBinBuiltinCall(f, inst, "shr", .None), - .shl, => try airBinBuiltinCall(f, inst, "shl", .None), + .shl, => try airBinBuiltinCall(f, inst, "shlw", .Bits), .shl_exact => try airBinOp(f, inst, "<<", "shl", .None), .not => try airNot (f, inst), |
