stage2: @returnAddress()

This commit is contained in:
Robin Voetter
2021-12-18 06:11:46 +01:00
parent 2f7e98c129
commit ddd2ef822f
10 changed files with 46 additions and 1 deletions

View File

@@ -1125,6 +1125,7 @@ fn genBody(f: *Function, body: []const Air.Inst.Index) error{ AnalysisFail, OutO
.arg => airArg(f),
.breakpoint => try airBreakpoint(f),
.ret_addr => try airRetAddr(f),
.unreach => try airUnreach(f),
.fence => try airFence(f, inst),
@@ -2191,6 +2192,10 @@ fn airBreakpoint(f: *Function) !CValue {
return CValue.none;
}
fn airRetAddr(f: *Function) !CValue {
return f.fail("TODO implement codegen for airRetAddr", .{});
}
fn airFence(f: *Function, inst: Air.Inst.Index) !CValue {
const atomic_order = f.air.instructions.items(.data)[inst].fence;
const writer = f.object.writer();