diff options
Diffstat (limited to 'contrib/arm-optimized-routines/math/log2f.c')
-rw-r--r-- | contrib/arm-optimized-routines/math/log2f.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/contrib/arm-optimized-routines/math/log2f.c b/contrib/arm-optimized-routines/math/log2f.c index acb629e6846c..7d47379b41cb 100644 --- a/contrib/arm-optimized-routines/math/log2f.c +++ b/contrib/arm-optimized-routines/math/log2f.c @@ -1,13 +1,15 @@ /* * Single-precision log2 function. * - * Copyright (c) 2017-2018, Arm Limited. - * SPDX-License-Identifier: MIT + * Copyright (c) 2017-2024, Arm Limited. + * SPDX-License-Identifier: MIT OR Apache-2.0 WITH LLVM-exception */ #include <math.h> #include <stdint.h> #include "math_config.h" +#include "test_defs.h" +#include "test_sig.h" /* LOG2F_TABLE_BITS = 4 @@ -78,3 +80,10 @@ log2f (float x) strong_alias (log2f, __log2f_finite) hidden_alias (log2f, __ieee754_log2f) #endif + +TEST_SIG (S, F, 1, log2, 0.01, 11.1) +TEST_ULP (log2f, 0.26) +TEST_ULP_NONNEAREST (log2f, 0.5) +TEST_INTERVAL (log2f, 0, 0xffff0000, 10000) +TEST_INTERVAL (log2f, 0x1p-4, 0x1p4, 50000) +TEST_INTERVAL (log2f, 0, inf, 50000) |