| ... | @@ -1048,7 +1048,7 @@ fn Function(comptime arch: std.Target.Cpu.Arch) type { | ... | @@ -1048,7 +1048,7 @@ fn Function(comptime arch: std.Target.Cpu.Arch) type { |
| 1048 | | 1048 | |
| 1049 | pub fn spillInstruction(self: *Self, reg: Register, inst: Air.Inst.Index) !void { | 1049 | pub fn spillInstruction(self: *Self, reg: Register, inst: Air.Inst.Index) !void { |
| 1050 | const stack_mcv = try self.allocRegOrMem(inst, false); | 1050 | const stack_mcv = try self.allocRegOrMem(inst, false); |
| 1051 | log.debug("spilling {*} to stack mcv {any}", .{ inst, stack_mcv }); | 1051 | log.debug("spilling {d} to stack mcv {any}", .{ inst, stack_mcv }); |
| 1052 | const reg_mcv = self.getResolvedInstValue(inst); | 1052 | const reg_mcv = self.getResolvedInstValue(inst); |
| 1053 | assert(reg == toCanonicalReg(reg_mcv.register)); | 1053 | assert(reg == toCanonicalReg(reg_mcv.register)); |
| 1054 | const branch = &self.branch_stack.items[self.branch_stack.items.len - 1]; | 1054 | const branch = &self.branch_stack.items[self.branch_stack.items.len - 1]; |
| ... | @@ -3115,7 +3115,7 @@ fn Function(comptime arch: std.Target.Cpu.Arch) type { | ... | @@ -3115,7 +3115,7 @@ fn Function(comptime arch: std.Target.Cpu.Arch) type { |
| 3115 | } | 3115 | } |
| 3116 | } | 3116 | } |
| 3117 | }; | 3117 | }; |
| 3118 | log.debug("consolidating else_entry {*} {}=>{}", .{ else_key, else_value, canon_mcv }); | 3118 | log.debug("consolidating else_entry {d} {}=>{}", .{ else_key, else_value, canon_mcv }); |
| 3119 | // TODO make sure the destination stack offset / register does not already have something | 3119 | // TODO make sure the destination stack offset / register does not already have something |
| 3120 | // going on there. | 3120 | // going on there. |
| 3121 | try self.setRegOrMem(self.air.typeOfIndex(else_key), canon_mcv, else_value); | 3121 | try self.setRegOrMem(self.air.typeOfIndex(else_key), canon_mcv, else_value); |
| ... | @@ -3142,7 +3142,7 @@ fn Function(comptime arch: std.Target.Cpu.Arch) type { | ... | @@ -3142,7 +3142,7 @@ fn Function(comptime arch: std.Target.Cpu.Arch) type { |
| 3142 | } | 3142 | } |
| 3143 | } | 3143 | } |
| 3144 | }; | 3144 | }; |
| 3145 | log.debug("consolidating then_entry {*} {}=>{}", .{ then_key, parent_mcv, then_value }); | 3145 | log.debug("consolidating then_entry {d} {}=>{}", .{ then_key, parent_mcv, then_value }); |
| 3146 | // TODO make sure the destination stack offset / register does not already have something | 3146 | // TODO make sure the destination stack offset / register does not already have something |
| 3147 | // going on there. | 3147 | // going on there. |
| 3148 | try self.setRegOrMem(self.air.typeOfIndex(then_key), parent_mcv, then_value); | 3148 | try self.setRegOrMem(self.air.typeOfIndex(then_key), parent_mcv, then_value); |