diff options
| author | Robin Voetter <robin@voetter.nl> | 2021-12-21 01:38:46 +0100 |
|---|---|---|
| committer | Robin Voetter <robin@voetter.nl> | 2021-12-21 01:47:27 +0100 |
| commit | e106e18d96595bdc4bc037e0b36900992a576160 (patch) | |
| tree | 950e169ddf58e761fb7b90fa4580cc26ef045cbf /src/codegen/c.zig | |
| parent | 964dbeb82623515b8392c8c7cb9317246812174e (diff) | |
| download | zig-e106e18d96595bdc4bc037e0b36900992a576160.tar.gz zig-e106e18d96595bdc4bc037e0b36900992a576160.zip | |
stage2: @shlWithOverflow
Diffstat (limited to 'src/codegen/c.zig')
| -rw-r--r-- | src/codegen/c.zig | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/codegen/c.zig b/src/codegen/c.zig index 68b700db17..12ce813a0f 100644 --- a/src/codegen/c.zig +++ b/src/codegen/c.zig @@ -1159,6 +1159,7 @@ fn genBody(f: *Function, body: []const Air.Inst.Index) error{ AnalysisFail, OutO .add_with_overflow => try airAddWithOverflow(f, inst), .sub_with_overflow => try airSubWithOverflow(f, inst), .mul_with_overflow => try airMulWithOverflow(f, inst), + .shl_with_overflow => try airShlWithOverflow(f, inst), .min => try airMinMax(f, inst, "<"), .max => try airMinMax(f, inst, ">"), @@ -1887,6 +1888,12 @@ fn airMulWithOverflow(f: *Function, inst: Air.Inst.Index) !CValue { return f.fail("TODO mul with overflow", .{}); } +fn airShlWithOverflow(f: *Function, inst: Air.Inst.Index) !CValue { + _ = f; + _ = inst; + return f.fail("TODO shl with overflow", .{}); +} + fn airNot(f: *Function, inst: Air.Inst.Index) !CValue { if (f.liveness.isUnused(inst)) return CValue.none; |
