


Bits error versus re



Bits error versus im
Results
Initial program 37.1
Simplified12.9
Final simplification12.9
herbie shell --seed 2019002 +o rules:numerics
(FPCore (re im)
:name "math.sqrt on complex, imaginary part, im greater than 0 branch"
(* 0.5 (sqrt (* 2.0 (- (sqrt (+ (* re re) (* im im))) re)))))
Time bar (total: 12.4s)Debug log
1 calls. Slowest were:
| 81.0ms | (* 0.5 (sqrt (* 2.0 (- (sqrt (+ (* re re) (* im im))) re)))) |
2 alts after pruning (2 fresh and 0 done)
Merged error: 13.5b
Found 3 expressions with local error:
| 1.0b | (- (hypot re im) re) |
| 0.0b | (sqrt (* (- (hypot re im) re) 2.0)) |
| 0.0b | (hypot re im) |
3 calls. Slowest were:
| 5.0ms | (- (hypot re im) re) |
| 3.0ms | (sqrt (* (- (hypot re im) re) 2.0)) |
| 0.0ms | (hypot re im) |
3 calls. Slowest were:
| 119.0ms | (sqrt (* (- (hypot re im) re) 2.0)) |
| 57.0ms | (- (hypot re im) re) |
| 33.0ms | (hypot re im) |
14 calls. Slowest were:
| 243.0ms | (sqrt (* (- (* (hypot re im) (hypot re im)) (* re re)) 2.0)) |
| 77.0ms | (sqrt (* (- (pow (hypot re im) 3) (pow re 3)) 2.0)) |
| 6.0ms | (sqrt (- (hypot re im) re)) |
9 alts after pruning (8 fresh and 1 done)
Merged error: 13.2b
Found 4 expressions with local error:
| 1.0b | (- (hypot re im) re) |
| 1.0b | (- (hypot re im) re) |
| 0.4b | (* (sqrt (- (hypot re im) re)) (sqrt (- (hypot re im) re))) |
| 0.0b | (sqrt (* (* (sqrt (- (hypot re im) re)) (sqrt (- (hypot re im) re))) 2.0)) |
4 calls. Slowest were:
| 17.0ms | (sqrt (* (* (sqrt (- (hypot re im) re)) (sqrt (- (hypot re im) re))) 2.0)) |
| 12.0ms | (* (sqrt (- (hypot re im) re)) (sqrt (- (hypot re im) re))) |
| 4.0ms | (- (hypot re im) re) |
4 calls. Slowest were:
| 118.0ms | (sqrt (* (* (sqrt (- (hypot re im) re)) (sqrt (- (hypot re im) re))) 2.0)) |
| 49.0ms | (- (hypot re im) re) |
| 49.0ms | (- (hypot re im) re) |
| 46.0ms | (* (sqrt (- (hypot re im) re)) (sqrt (- (hypot re im) re))) |
59 calls. Slowest were:
| 450.0ms | (* (* (* (sqrt (- (hypot re im) re)) (sqrt (- (hypot re im) re))) (sqrt (- (hypot re im) re))) (* (* (sqrt (- (hypot re im) re)) (sqrt (- (hypot re im) re))) (sqrt (- (hypot re im) re)))) |
| 223.0ms | (sqrt (* (* (sqrt (- (* (hypot re im) (hypot re im)) (* re re))) (sqrt (- (hypot re im) re))) 2.0)) |
| 205.0ms | (sqrt (* (* (sqrt (- (hypot re im) re)) (sqrt (- (* (hypot re im) (hypot re im)) (* re re)))) 2.0)) |
11 alts after pruning (9 fresh and 2 done)
Merged error: 13.2b
Found 4 expressions with local error:
| 15.3b | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
| 1.0b | (- (hypot re im) re) |
| 0.4b | (* (sqrt (- (hypot re im) re)) (sqrt (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)))) |
| 0.0b | (sqrt (hypot re im)) |
4 calls. Slowest were:
| 17.0ms | (* (sqrt (- (hypot re im) re)) (sqrt (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)))) |
| 7.0ms | (- (hypot re im) re) |
| 2.0ms | (sqrt (hypot re im)) |
4 calls. Slowest were:
| 294.0ms | (* (sqrt (- (hypot re im) re)) (sqrt (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)))) |
| 74.0ms | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
| 56.0ms | (sqrt (hypot re im)) |
| 36.0ms | (- (hypot re im) re) |
36 calls. Slowest were:
| 214.0ms | (* (sqrt (- (* (hypot re im) (hypot re im)) (* re re))) (sqrt (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)))) |
| 186.0ms | (* (* (* (sqrt (- (hypot re im) re)) (sqrt (- (hypot re im) re))) (sqrt (- (hypot re im) re))) (* (* (sqrt (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re))) (sqrt (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)))) (sqrt (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re))))) |
| 80.0ms | (* (- (hypot re im) re) (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re))) |
12 alts after pruning (11 fresh and 1 done)
Merged error: 13.2b
Found 4 expressions with local error:
| 15.3b | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
| 15.3b | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
| 1.0b | (- (hypot re im) re) |
| 1.0b | (- (hypot re im) re) |
4 calls. Slowest were:
| 7.0ms | (- (hypot re im) re) |
| 6.0ms | (- (hypot re im) re) |
| 0.0ms | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
4 calls. Slowest were:
| 102.0ms | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
| 86.0ms | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
| 38.0ms | (- (hypot re im) re) |
| 30.0ms | (- (hypot re im) re) |
16 calls. Slowest were:
| 2.0ms | (- im re) |
| 1.0ms | (- im re) |
| 1.0ms | (- im re) |
12 alts after pruning (11 fresh and 1 done)
Merged error: 13.2b
0% (0.2b remaining)
Error of 12.9b against oracle of 12.6b and baseline of 12.9b