d \cdot 10 + d \cdot 20
d \cdot 30
double f(double d) {
double r3411113 = d;
double r3411114 = 10.0;
double r3411115 = r3411113 * r3411114;
double r3411116 = 20.0;
double r3411117 = r3411113 * r3411116;
double r3411118 = r3411115 + r3411117;
return r3411118;
}
double f(double d) {
double r3411119 = d;
double r3411120 = 30.0;
double r3411121 = r3411119 * r3411120;
return r3411121;
}




Bits error versus d
Results
| Original | 0.3 |
|---|---|
| Target | 0 |
| Herbie | 0 |
Initial program 0.3
Simplified0
Final simplification0
herbie shell --seed 2019154 +o rules:numerics
(FPCore (d)
:name "FastMath test1"
:herbie-target
(* d 30)
(+ (* d 10) (* d 20)))