| Issue |
176818
|
| Summary |
[LoongArch] Zig's `log2` tests started failing with LLVM 22
|
| Labels |
miscompilation,
backend:loongarch,
regression:22
|
| Assignees |
|
| Reporter |
alexrp
|
We only see these on LoongArch:
```
test-modules
└─ test-behavior
└─ run test behavior-loongarch64-linux-none-la64v1_0-Debug 4 pass, 1 skip, 3 fail (8 total)
error: 'behavior.floatop.test.@log2 f16' failed:
/home/alexrp/Sources/ziglang/zig-llvm22/lib/std/testing.zig:615:14: 0x11b5be3 in expect (test)
if (!ok) return error.TestUnexpectedResult;
^
/home/alexrp/Sources/ziglang/zig-llvm22/test/behavior/floatop.zig:954:5: 0x11b5df7 in testLog2__anon_35916 (test)
try expect(math.approxEqAbs(T, @log2(six), 2.5849625007212, eps));
^
/home/alexrp/Sources/ziglang/zig-llvm22/test/behavior/floatop.zig:919:5: 0x11b60f3 in test.@log2 f16 (test)
try testLog2(f16);
^
error: 'behavior.floatop.test.@log2 f32/f64' failed:
/home/alexrp/Sources/ziglang/zig-llvm22/lib/std/testing.zig:615:14: 0x11b5be3 in expect (test)
if (!ok) return error.TestUnexpectedResult;
^
/home/alexrp/Sources/ziglang/zig-llvm22/test/behavior/floatop.zig:954:5: 0x11b62d7 in testLog2__anon_35977 (test)
try expect(math.approxEqAbs(T, @log2(six), 2.5849625007212, eps));
^
/home/alexrp/Sources/ziglang/zig-llvm22/test/behavior/floatop.zig:929:5: 0x11b689f in test.@log2 f32/f64 (test)
try testLog2(f32);
^
error: 'behavior.floatop.test.@log2 with vectors' failed:
/home/alexrp/Sources/ziglang/zig-llvm22/lib/std/testing.zig:615:14: 0x11b5be3 in expect (test)
if (!ok) return error.TestUnexpectedResult;
^
/home/alexrp/Sources/ziglang/zig-llvm22/test/behavior/floatop.zig:979:5: 0x11b7a8f in testLog2WithVectors (test)
try expect(@log2(@as(f32, 1.1)) == result[0]);
^
/home/alexrp/Sources/ziglang/zig-llvm22/test/behavior/floatop.zig:971:5: 0x11b7c73 in test.@log2 with vectors (test)
try testLog2WithVectors();
^
failed command: qemu-loongarch64 ./.zig-cache/o/8fef89cfb464b38c352badafc91870c8/test --cache-dir=./.zig-cache --seed=0xa8633959 --listen=-
test-modules
└─ test-std
└─ run test std-loongarch64-linux-none-la64v1_0-Debug 67 pass, 1 fail (68 total)
error: 'math.log2.decltest.log2' failed:
/home/alexrp/Sources/ziglang/zig-llvm22/lib/std/testing.zig:615:14: 0x1231423 in expect (test)
if (!ok) return error.TestUnexpectedResult;
^
/home/alexrp/Sources/ziglang/zig-llvm22/lib/std/math/log2.zig:47:5: 0x1234017 in decltest.log2 (test)
try expect(log2(@as(f32, 0.2)) == @log2(0.2));
^
failed command: qemu-loongarch64 ./.zig-cache/o/c7cad71a90740cec4662186077312aeb/test --cache-dir=./.zig-cache --seed=0xa8633959 --listen=-
```
I suspect this may have been regressed by https://github.com/llvm/llvm-project/pull/162978.
Will provide a reduced repro soon.
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs