Skip to content

Commit

Permalink
[libc] suppress uninitialized werrors (#98710)
Browse files Browse the repository at this point in the history
suppress uninitialized werrors when building with gcc
  • Loading branch information
SchrodingerZhu authored Jul 13, 2024
1 parent fb19649 commit 0ecb983
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions libc/src/math/generic/tan.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ LLVM_LIBC_FUNCTION(double, tan, (double x)) {

DoubleDouble y;
unsigned k;
generic::LargeRangeReduction<NO_FMA> range_reduction_large;
generic::LargeRangeReduction<NO_FMA> range_reduction_large{};

// |x| < 2^32 (with FMA) or |x| < 2^23 (w/o FMA)
if (LIBC_LIKELY(x_e < FPBits::EXP_BIAS + FAST_PASS_EXPONENT)) {
Expand All @@ -160,7 +160,7 @@ LLVM_LIBC_FUNCTION(double, tan, (double x)) {
if (LIBC_UNLIKELY(x == 0.0))
return x;

// For |x| < 2^-27, |tan(x) - x| < ulp(x)/2.
// For |x| < 2^-27, |tan(x) - x| < ulp(x)/2.
#ifdef LIBC_TARGET_CPU_HAS_FMA
return fputil::multiply_add(x, 0x1.0p-54, x);
#else
Expand Down

0 comments on commit 0ecb983

Please sign in to comment.