[libc-commits] [libc] 7578c31 - [libc] Disable fpexcept testing on the GPU

Joseph Huber via libc-commits libc-commits at lists.llvm.org
Wed Jun 5 07:54:43 PDT 2024


Author: Joseph Huber
Date: 2024-06-05T09:54:34-05:00
New Revision: 7578c31823ff1b23f1f15607f8abf57bc173b843

URL: https://github.com/llvm/llvm-project/commit/7578c31823ff1b23f1f15607f8abf57bc173b843
DIFF: https://github.com/llvm/llvm-project/commit/7578c31823ff1b23f1f15607f8abf57bc173b843.diff

LOG: [libc] Disable fpexcept testing on the GPU

Summary:
These new tests fails on the GPU due to the exception testing. Disable
it for now because these aren't supported and can't be supported on
NVPTX.

Added: 
    

Modified: 
    libc/test/src/math/smoke/RoundToIntegerTest.h

Removed: 
    


################################################################################
diff  --git a/libc/test/src/math/smoke/RoundToIntegerTest.h b/libc/test/src/math/smoke/RoundToIntegerTest.h
index 02ae601716afc..fd3fbde92b963 100644
--- a/libc/test/src/math/smoke/RoundToIntegerTest.h
+++ b/libc/test/src/math/smoke/RoundToIntegerTest.h
@@ -12,6 +12,7 @@
 #include "src/__support/CPP/algorithm.h"
 #include "src/__support/FPUtil/FEnvImpl.h"
 #include "src/__support/FPUtil/FPBits.h"
+#include "src/__support/macros/properties/architectures.h"
 #include "test/UnitTest/FEnvSafeTest.h"
 #include "test/UnitTest/FPMatcher.h"
 #include "test/UnitTest/Test.h"
@@ -50,10 +51,12 @@ class RoundToIntegerTestTemplate
     // 0 for errno and exceptions, but this doesn't hold for
     // all math functions using RoundToInteger test:
     // https://github.com/llvm/llvm-project/pull/88816
+#ifndef LIBC_TARGET_ARCH_IS_GPU
     if (expectError) {
       ASSERT_FP_EXCEPTION(FE_INVALID);
       ASSERT_MATH_ERRNO(EDOM);
     }
+#endif
   }
 
 public:


        


More information about the libc-commits mailing list