From 52fb23eef8e4c331ae7cfa21e26d07918cfebd5e Mon Sep 17 00:00:00 2001 From: Zorojuro Date: Thu, 2 Apr 2026 04:31:44 +0530 Subject: [PATCH] [libc][math] Remove static from log1pf implementation (#190042) Reflecting changes according to https://github.com/llvm/llvm-project/commit/823e3e001724ca2e93ce410a675f3b538f8a74b3 --- libc/src/__support/math/log1pf.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libc/src/__support/math/log1pf.h b/libc/src/__support/math/log1pf.h index 749c63218c59..49244f38f890 100644 --- a/libc/src/__support/math/log1pf.h +++ b/libc/src/__support/math/log1pf.h @@ -21,7 +21,7 @@ #include "src/__support/macros/properties/cpu_features.h" #include "src/__support/math/acoshf_utils.h" -// This is an algorithm for log10(x) in single precision which is +// This is an algorithm for log(1+x) in single precision which is // correctly rounded for all rounding modes. // - An exhaustive test show that when x >= 2^45, log1pf(x) == logf(x) // for all rounding modes. @@ -37,7 +37,7 @@ namespace LIBC_NAMESPACE_DECL { namespace math { -LIBC_INLINE static float log1pf(float x) { +LIBC_INLINE float log1pf(float x) { using FPBits = typename fputil::FPBits; FPBits xbits(x); uint32_t x_u = xbits.uintval(); @@ -62,7 +62,7 @@ LIBC_INLINE static float log1pf(float x) { } #endif // !LIBC_MATH_HAS_SKIP_ACCURATE_PASS - // Polymial generated by Sollya with: + // Polynomial generated by Sollya with: // > P = fpminimax(log(1 + x)/x, 7, [|D...|], [-2^-6; 2^-6]); // > dirtyinfnorm((log(1 + x) - x*P)/log(1 + x), [-2^-6, 2^-6]); // 0x1.1447755e54a327941f7db7316f8dcd7cf33d15ffp-58