Skip to content

Commit

Permalink
change reference_relaxed_exp to use float type to calculate reference…
Browse files Browse the repository at this point in the history
… value
  • Loading branch information
Anilava Kundu committed Nov 26, 2024
1 parent e9a248f commit 3c470fd
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions test_conformance/math_brute_force/reference_math.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5084,7 +5084,10 @@ static long double reference_scalblnl(long double x, long n)
#endif
}

double reference_relaxed_exp(double x) { return reference_exp(x); }
double reference_relaxed_exp(double x)
{
return reference_exp2(((float)x) * HEX_FLT(+, 1, 715476, +, 0));
}

double reference_exp(double x)
{
Expand Down Expand Up @@ -5771,4 +5774,4 @@ long double reference_erfcl(long double x) { return erfc(x); }
long double reference_erfl(long double x) { return erf(x); }

double reference_erfc(double x) { return erfc(x); }
double reference_erf(double x) { return erf(x); }
double reference_erf(double x) { return erf(x); }

0 comments on commit 3c470fd

Please sign in to comment.