authorgravatar for koachan@protonmail.comKoakuma <koachan@protonmail.com> 2022-07-09 18:44:35+07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2022-09-14 16:57:31-07:00
log0e1c68d90a39142c7ba73aa5cb0dddaebe96b6c1
tree5c73945cc15b899dcac0958f6ec436136d25197a
parent0464512f2efe67d9fe853c8f4fac6448d8f48b9c

stage2: sparc64: Don't track condition_flags_inst in checked binOps

This stops the emission of spurious CCR spills.

1 files changed, 0 insertions(+), 3 deletions(-)

src/arch/sparc64/CodeGen.zig-3
......@@ -765,7 +765,6 @@ fn airAddSubWithOverflow(self: *Self, inst: Air.Inst.Index) !void {
765765 };
766766
767767 try self.spillConditionFlagsIfOccupied();
768 self.condition_flags_inst = inst;
769768
770769 const dest = blk: {
771770 if (rhs_immediate_ok) {
......@@ -1825,7 +1824,6 @@ fn airMulWithOverflow(self: *Self, inst: Air.Inst.Index) !void {
18251824 switch (int_info.bits) {
18261825 1...32 => {
18271826 try self.spillConditionFlagsIfOccupied();
1828 self.condition_flags_inst = inst;
18291827
18301828 const dest = try self.binOp(.mul, lhs, rhs, lhs_ty, rhs_ty, null);
18311829
......@@ -2037,7 +2035,6 @@ fn airShlWithOverflow(self: *Self, inst: Air.Inst.Index) !void {
20372035 const int_info = lhs_ty.intInfo(self.target.*);
20382036 if (int_info.bits <= 64) {
20392037 try self.spillConditionFlagsIfOccupied();
2040 self.condition_flags_inst = inst;
20412038
20422039 const lhs_lock: ?RegisterLock = if (lhs == .register)
20432040 self.register_manager.lockRegAssumeUnused(lhs.register)