authorgravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2026-01-20 00:04:49+01:00
committergravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2026-04-22 15:31:57+02:00
log7ca4489fdc6172bc587f4397c196c87866a0b8e6
treed7a2c9e9ba349c169289c605afc6ac56c78928e3
parentfa03fd5248856ff9b9db30a3d73ee943f5cb6604
signaturebadge-check Signed by SSH key SHA256:7B/LJ7bpR1eX8aCXSr4mtd5M45VMPKcx9zY8e95b5QM

Revert "std.mem: work around LoongArch inline asm bug in doNotOptimizeAway()"

This reverts commit e7f1624e6ea11bb30c779963f9fdfabd51902276. The bug was fixed in LLVM 22.

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

lib/std/mem.zig+1-2
......@@ -4809,8 +4809,7 @@ pub fn doNotOptimizeAway(val: anytype) void {
48094809 } else doNotOptimizeAway(&val);
48104810 },
48114811 .float => {
4812 // https://github.com/llvm/llvm-project/issues/159200
4813 if ((t.float.bits == 32 or t.float.bits == 64) and builtin.zig_backend != .stage2_c and !builtin.cpu.arch.isLoongArch()) {
4812 if ((t.float.bits == 32 or t.float.bits == 64) and builtin.zig_backend != .stage2_c) {
48144813 asm volatile (""
48154814 :
48164815 : [_] "rm" (val),