Merge pull request #21571 from alexrp/14366-progress

Re-enable some tests that were disabled due to #14366
This commit is contained in:
Alex Rønne Petersen 2024-10-04 00:31:26 +02:00 committed by GitHub
commit 6b231b9e3f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 7 additions and 7 deletions

View File

@ -172,9 +172,6 @@ test nan {
}
test snan {
// TODO: https://github.com/ziglang/zig/issues/14366
if (builtin.zig_backend == .stage2_llvm and comptime builtin.cpu.arch.isArmOrThumb()) return error.SkipZigTest;
const snan_u16: u16 = 0x7D00;
const snan_u32: u32 = 0x7FA00000;
const snan_u64: u64 = 0x7FF4000000000000;

View File

@ -32,7 +32,13 @@ test isSignalNan {
// TODO: Signalling NaN values get converted to quiet NaN values in
// some cases where they shouldn't such that this can fail.
// See https://github.com/ziglang/zig/issues/14366
// try expect(isSignalNan(math.snan(T)));
if (!builtin.cpu.arch.isArmOrThumb() and
!builtin.cpu.arch.isAARCH64() and
!builtin.cpu.arch.isPowerPC() and
builtin.zig_backend != .stage2_c)
{
try expect(isSignalNan(math.snan(T)));
}
try expect(!isSignalNan(math.nan(T)));
try expect(!isSignalNan(@as(T, 1.0)));
try expect(!isSignalNan(math.inf(T)));

View File

@ -429,9 +429,6 @@ test "bitcast nan float does not modify signaling bit" {
if (builtin.zig_backend == .stage2_x86_64 and builtin.target.ofmt != .elf and builtin.target.ofmt != .macho) return error.SkipZigTest;
if (builtin.zig_backend == .stage2_riscv64) return error.SkipZigTest;
// TODO: https://github.com/ziglang/zig/issues/14366
if (builtin.zig_backend == .stage2_llvm and comptime builtin.cpu.arch.isArmOrThumb()) return error.SkipZigTest;
const snan_u16: u16 = 0x7D00;
const snan_u32: u32 = 0x7FA00000;
const snan_u64: u64 = 0x7FF4000000000000;