e^{\log a + \log b}b \cdot a
double f(double a, double b) {
double r9539 = a;
double r9540 = log(r9539);
double r9541 = b;
double r9542 = log(r9541);
double r9543 = r9540 + r9542;
double r9544 = exp(r9543);
return r9544;
}
double f(double a, double b) {
double r9545 = b;
double r9546 = a;
double r9547 = r9545 * r9546;
return r9547;
}




Bits error versus a




Bits error versus b
Results
| Original | 5.7 |
|---|---|
| Target | 0 |
| Herbie | 0 |
Initial program 5.7
Simplified0
Final simplification0
herbie shell --seed 2019310
(FPCore (a b)
:name "Exp of sum of logs"
:precision binary64
:herbie-target
(* a b)
(exp (+ (log a) (log b))))