authorgravatar for jacobly@ziglang.orgJacob Young <jacobly@ziglang.org> 2025-08-26 19:15:29-04:00
committergravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2025-08-28 05:30:04+02:00
log49f0122e413ee5d4640878985320e36b7ce7cc26
tree6799e487443de6599f64f96e43caf52dc5fcec0c
parent9dc3fce4c4a299df57a664f0c4dd6d8dfd07986d
signaturebadge-check Signed by SSH key SHA256:7B/LJ7bpR1eX8aCXSr4mtd5M45VMPKcx9zY8e95b5QM

x86_64: fix multiplication overflow detection with adx

Closes #24965

1 files changed, 6 insertions(+), 6 deletions(-)

src/arch/x86_64/CodeGen.zig+6-6
...@@ -31490,7 +31490,7 @@ fn genBody(cg: *CodeGen, body: []const Air.Inst.Index) InnerError!void {...@@ -31490,7 +31490,7 @@ fn genBody(cg: *CodeGen, body: []const Air.Inst.Index) InnerError!void {
31490 .{ ._, ._x, .ado, .tmp8q, .tmp3q, ._, ._ },31490 .{ ._, ._x, .ado, .tmp8q, .tmp3q, ._, ._ },
31491 .{ ._, ._x, .adc, .tmp8q, .tmp3q, ._, ._ },31491 .{ ._, ._x, .adc, .tmp8q, .tmp3q, ._, ._ },
31492 .{ ._, ._mp, .j, .@"2f", ._, ._, ._ },31492 .{ ._, ._mp, .j, .@"2f", ._, ._, ._ },
31493 .{ .@"1:", ._, .@"or", .tmp8q, .leai(.tmp1q, .tmp4), ._, ._ },31493 .{ .@"1:", ._, .@"or", .tmp8q, .leaid(.tmp1q, .tmp4, 8), ._, ._ },
31494 .{ .@"2:", ._, .sub, .tmp4d, .si(8), ._, ._ },31494 .{ .@"2:", ._, .sub, .tmp4d, .si(8), ._, ._ },
31495 .{ ._, ._ae, .j, .@"1b", ._, ._, ._ },31495 .{ ._, ._ae, .j, .@"1b", ._, ._, ._ },
31496 .{ ._, ._, .@"or", .tmp2q, .tmp8q, ._, ._ },31496 .{ ._, ._, .@"or", .tmp2q, .tmp8q, ._, ._ },
...@@ -31814,7 +31814,7 @@ fn genBody(cg: *CodeGen, body: []const Air.Inst.Index) InnerError!void {...@@ -31814,7 +31814,7 @@ fn genBody(cg: *CodeGen, body: []const Air.Inst.Index) InnerError!void {
31814 .{ ._, ._x, .ado, .tmp8q, .tmp3q, ._, ._ },31814 .{ ._, ._x, .ado, .tmp8q, .tmp3q, ._, ._ },
31815 .{ ._, ._x, .adc, .tmp8q, .tmp3q, ._, ._ },31815 .{ ._, ._x, .adc, .tmp8q, .tmp3q, ._, ._ },
31816 .{ ._, ._mp, .j, .@"2f", ._, ._, ._ },31816 .{ ._, ._mp, .j, .@"2f", ._, ._, ._ },
31817 .{ .@"1:", ._, .@"or", .tmp8q, .leai(.tmp1q, .tmp4), ._, ._ },31817 .{ .@"1:", ._, .@"or", .tmp8q, .leaid(.tmp1q, .tmp4, 8), ._, ._ },
31818 .{ .@"2:", ._, .sub, .tmp4d, .si(8), ._, ._ },31818 .{ .@"2:", ._, .sub, .tmp4d, .si(8), ._, ._ },
31819 .{ ._, ._ae, .j, .@"1b", ._, ._, ._ },31819 .{ ._, ._ae, .j, .@"1b", ._, ._, ._ },
31820 .{ ._, ._, .@"or", .tmp2q, .tmp8q, ._, ._ },31820 .{ ._, ._, .@"or", .tmp2q, .tmp8q, ._, ._ },
...@@ -32175,7 +32175,7 @@ fn genBody(cg: *CodeGen, body: []const Air.Inst.Index) InnerError!void {...@@ -32175,7 +32175,7 @@ fn genBody(cg: *CodeGen, body: []const Air.Inst.Index) InnerError!void {
32175 .{ ._, ._x, .ado, .tmp8q, .tmp3q, ._, ._ },32175 .{ ._, ._x, .ado, .tmp8q, .tmp3q, ._, ._ },
32176 .{ ._, ._x, .adc, .tmp8q, .tmp3q, ._, ._ },32176 .{ ._, ._x, .adc, .tmp8q, .tmp3q, ._, ._ },
32177 .{ ._, ._mp, .j, .@"2f", ._, ._, ._ },32177 .{ ._, ._mp, .j, .@"2f", ._, ._, ._ },
32178 .{ .@"1:", ._, .@"or", .tmp8q, .leai(.tmp1q, .tmp4), ._, ._ },32178 .{ .@"1:", ._, .@"or", .tmp8q, .leaid(.tmp1q, .tmp4, 8), ._, ._ },
32179 .{ .@"2:", ._, .sub, .tmp4d, .si(8), ._, ._ },32179 .{ .@"2:", ._, .sub, .tmp4d, .si(8), ._, ._ },
32180 .{ ._, ._ae, .j, .@"1b", ._, ._, ._ },32180 .{ ._, ._ae, .j, .@"1b", ._, ._, ._ },
32181 .{ ._, ._, .@"or", .tmp2q, .tmp8q, ._, ._ },32181 .{ ._, ._, .@"or", .tmp2q, .tmp8q, ._, ._ },
...@@ -55062,7 +55062,7 @@ fn genBody(cg: *CodeGen, body: []const Air.Inst.Index) InnerError!void {...@@ -55062,7 +55062,7 @@ fn genBody(cg: *CodeGen, body: []const Air.Inst.Index) InnerError!void {
55062 .{ ._, ._x, .ado, .tmp8q, .tmp3q, ._, ._ },55062 .{ ._, ._x, .ado, .tmp8q, .tmp3q, ._, ._ },
55063 .{ ._, ._x, .adc, .tmp8q, .tmp3q, ._, ._ },55063 .{ ._, ._x, .adc, .tmp8q, .tmp3q, ._, ._ },
55064 .{ ._, ._mp, .j, .@"2f", ._, ._, ._ },55064 .{ ._, ._mp, .j, .@"2f", ._, ._, ._ },
55065 .{ .@"1:", ._, .@"or", .tmp8q, .leai(.tmp1q, .tmp4), ._, ._ },55065 .{ .@"1:", ._, .@"or", .tmp8q, .leaid(.tmp1q, .tmp4, 8), ._, ._ },
55066 .{ .@"2:", ._, .sub, .tmp4d, .si(8), ._, ._ },55066 .{ .@"2:", ._, .sub, .tmp4d, .si(8), ._, ._ },
55067 .{ ._, ._ae, .j, .@"1b", ._, ._, ._ },55067 .{ ._, ._ae, .j, .@"1b", ._, ._, ._ },
55068 .{ ._, ._, .@"or", .tmp2q, .tmp8q, ._, ._ },55068 .{ ._, ._, .@"or", .tmp2q, .tmp8q, ._, ._ },
...@@ -55361,7 +55361,7 @@ fn genBody(cg: *CodeGen, body: []const Air.Inst.Index) InnerError!void {...@@ -55361,7 +55361,7 @@ fn genBody(cg: *CodeGen, body: []const Air.Inst.Index) InnerError!void {
55361 .{ ._, ._x, .ado, .tmp8q, .tmp3q, ._, ._ },55361 .{ ._, ._x, .ado, .tmp8q, .tmp3q, ._, ._ },
55362 .{ ._, ._x, .adc, .tmp8q, .tmp3q, ._, ._ },55362 .{ ._, ._x, .adc, .tmp8q, .tmp3q, ._, ._ },
55363 .{ ._, ._mp, .j, .@"2f", ._, ._, ._ },55363 .{ ._, ._mp, .j, .@"2f", ._, ._, ._ },
55364 .{ .@"1:", ._, .@"or", .tmp8q, .leai(.tmp1q, .tmp4), ._, ._ },55364 .{ .@"1:", ._, .@"or", .tmp8q, .leaid(.tmp1q, .tmp4, 8), ._, ._ },
55365 .{ .@"2:", ._, .sub, .tmp4d, .si(8), ._, ._ },55365 .{ .@"2:", ._, .sub, .tmp4d, .si(8), ._, ._ },
55366 .{ ._, ._ae, .j, .@"1b", ._, ._, ._ },55366 .{ ._, ._ae, .j, .@"1b", ._, ._, ._ },
55367 .{ ._, ._, .@"or", .tmp2q, .tmp8q, ._, ._ },55367 .{ ._, ._, .@"or", .tmp2q, .tmp8q, ._, ._ },
...@@ -55690,7 +55690,7 @@ fn genBody(cg: *CodeGen, body: []const Air.Inst.Index) InnerError!void {...@@ -55690,7 +55690,7 @@ fn genBody(cg: *CodeGen, body: []const Air.Inst.Index) InnerError!void {
55690 .{ ._, ._x, .ado, .tmp8q, .tmp3q, ._, ._ },55690 .{ ._, ._x, .ado, .tmp8q, .tmp3q, ._, ._ },
55691 .{ ._, ._x, .adc, .tmp8q, .tmp3q, ._, ._ },55691 .{ ._, ._x, .adc, .tmp8q, .tmp3q, ._, ._ },
55692 .{ ._, ._mp, .j, .@"2f", ._, ._, ._ },55692 .{ ._, ._mp, .j, .@"2f", ._, ._, ._ },
55693 .{ .@"1:", ._, .@"or", .tmp8q, .leai(.tmp1q, .tmp4), ._, ._ },55693 .{ .@"1:", ._, .@"or", .tmp8q, .leaid(.tmp1q, .tmp4, 8), ._, ._ },
55694 .{ .@"2:", ._, .sub, .tmp4d, .si(8), ._, ._ },55694 .{ .@"2:", ._, .sub, .tmp4d, .si(8), ._, ._ },
55695 .{ ._, ._ae, .j, .@"1b", ._, ._, ._ },55695 .{ ._, ._ae, .j, .@"1b", ._, ._, ._ },
55696 .{ ._, ._, .@"or", .tmp2q, .tmp8q, ._, ._ },55696 .{ ._, ._, .@"or", .tmp2q, .tmp8q, ._, ._ },