[libc-commits] [libc] 6aa7403 - [libc] Fix fpbits test running 80bit ld everywhere (#115937)
via libc-commits
libc-commits at lists.llvm.org
Tue Nov 12 12:52:13 PST 2024
Author: Michael Jones
Date: 2024-11-12T12:52:08-08:00
New Revision: 6aa74038588ed47e3fc0d829c1e7538cc110ba39
URL: https://github.com/llvm/llvm-project/commit/6aa74038588ed47e3fc0d829c1e7538cc110ba39
DIFF: https://github.com/llvm/llvm-project/commit/6aa74038588ed47e3fc0d829c1e7538cc110ba39.diff
LOG: [libc] Fix fpbits test running 80bit ld everywhere (#115937)
After #115084 the 80 bit long double tests error if sizeof(long double)
isn't 96 or 128 bits. This caused failures in long double is double
systems (since long double is 64 bits) so I've disabled the 80 bit long
double tests on systems that don't use them.
Added:
Modified:
libc/test/src/__support/FPUtil/fpbits_test.cpp
Removed:
################################################################################
diff --git a/libc/test/src/__support/FPUtil/fpbits_test.cpp b/libc/test/src/__support/FPUtil/fpbits_test.cpp
index edb04c24ae3876..6953d3aace58f3 100644
--- a/libc/test/src/__support/FPUtil/fpbits_test.cpp
+++ b/libc/test/src/__support/FPUtil/fpbits_test.cpp
@@ -124,6 +124,7 @@ TEST(LlvmLibcFPBitsTest, FPType_IEEE754_Binary128) {
UInt128(Rep::quiet_nan()));
}
+#ifdef LIBC_TYPES_LONG_DOUBLE_IS_X86_FLOAT80
TEST(LlvmLibcFPBitsTest, FPType_X86_Binary80) {
using Rep = FPRep<FPType::X86_Binary80>;
@@ -269,6 +270,7 @@ TEST(LlvmLibcFPBitsTest, FPType_X86_Binary80_IsNan) {
#error "unhandled long double type"
#endif
}
+#endif // LIBC_TYPES_LONG_DOUBLE_IS_X86_FLOAT80
enum class FP {
ZERO,
More information about the libc-commits
mailing list