[libc-commits] [libc] 11da3de - [libc][Obvious] Reduce the size of the tests for hypot(f).

Tue Ly via libc-commits libc-commits at lists.llvm.org
Thu Mar 16 18:18:57 PDT 2023


Author: Tue Ly
Date: 2023-03-16T21:17:20-04:00
New Revision: 11da3de82d35afb8011c7aea42d76bb57d0e23cd

URL: https://github.com/llvm/llvm-project/commit/11da3de82d35afb8011c7aea42d76bb57d0e23cd
DIFF: https://github.com/llvm/llvm-project/commit/11da3de82d35afb8011c7aea42d76bb57d0e23cd.diff

LOG: [libc][Obvious] Reduce the size of the tests for hypot(f).

Added: 
    

Modified: 
    libc/test/src/math/HypotTest.h

Removed: 
    


################################################################################
diff  --git a/libc/test/src/math/HypotTest.h b/libc/test/src/math/HypotTest.h
index e8b4cf06ad973..8d3fd88dec31d 100644
--- a/libc/test/src/math/HypotTest.h
+++ b/libc/test/src/math/HypotTest.h
@@ -59,7 +59,7 @@ class HypotTestTemplate : public __llvm_libc::testing::Test {
   }
 
   void test_subnormal_range(Func func) {
-    constexpr UIntType COUNT = 1000001;
+    constexpr UIntType COUNT = 100001;
     for (unsigned scale = 0; scale < 4; ++scale) {
       UIntType max_value = FPBits::MAX_SUBNORMAL << scale;
       UIntType step = (max_value - FPBits::MIN_SUBNORMAL) / COUNT;
@@ -84,7 +84,7 @@ class HypotTestTemplate : public __llvm_libc::testing::Test {
   }
 
   void test_normal_range(Func func) {
-    constexpr UIntType COUNT = 1000001;
+    constexpr UIntType COUNT = 100001;
     constexpr UIntType STEP = (FPBits::MAX_NORMAL - FPBits::MIN_NORMAL) / COUNT;
     for (int signs = 0; signs < 4; ++signs) {
       for (UIntType v = FPBits::MIN_NORMAL, w = FPBits::MAX_NORMAL;


        


More information about the libc-commits mailing list