diff --git a/libc/src/math/generic/cos.cpp b/libc/src/math/generic/cos.cpp index 923ea96852d88..568b1254c6f02 100644 --- a/libc/src/math/generic/cos.cpp +++ b/libc/src/math/generic/cos.cpp @@ -93,7 +93,7 @@ LLVM_LIBC_FUNCTION(double, cos, (double x)) { } return ans; }; - DoubleDouble sin_k = get_idx_dd(k + 128); + DoubleDouble msin_k = get_idx_dd(k + 128); DoubleDouble cos_k = get_idx_dd(k + 64); #else // Fast look up version, but needs 256-entry table. diff --git a/libc/src/math/generic/range_reduction_double_common.h b/libc/src/math/generic/range_reduction_double_common.h index e23bbff144bee..bcab82f6c9c3a 100644 --- a/libc/src/math/generic/range_reduction_double_common.h +++ b/libc/src/math/generic/range_reduction_double_common.h @@ -278,6 +278,7 @@ struct LargeRangeReduction { DoubleDouble y_mid; }; +#ifndef LIBC_MATH_HAS_SKIP_ACCURATE_PASS static Float128 range_reduction_small_f128(double x) { constexpr Float128 PI_OVER_128_F128 = { Sign::POS, -133, 0xc90f'daa2'2168'c234'c4c6'628b'80dc'1cd1_u128}; @@ -300,7 +301,6 @@ static Float128 range_reduction_small_f128(double x) { return fputil::quick_mul(y, PI_OVER_128_F128); } -#ifndef LIBC_MATH_HAS_SKIP_ACCURATE_PASS static constexpr Float128 SIN_K_PI_OVER_128_F128[65] = { {Sign::POS, 0, 0}, {Sign::POS, -133, 0xc90a'afbd'1b33'efc9'c539'edcb'fda0'cf2c_u128},