


Bits error versus re



Bits error versus im
Results
Initial program 37.7
Simplified13.4
Final simplification13.4
herbie shell --seed 2019007 +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: 8.2s)Debug log
1 calls. Slowest were:
| 105.0ms | (* 0.5 (sqrt (* 2.0 (- (sqrt (+ (* re re) (* im im))) re)))) |
2 alts after pruning (2 fresh and 0 done)
Merged error: 11.9b
Found 2 expressions with local error:
| 0.5b | (- (hypot re im) re) |
| 0.0b | (sqrt (* (- (hypot re im) re) 2.0)) |
2 calls. Slowest were:
| 8.0ms | (- (hypot re im) re) |
| 5.0ms | (sqrt (* (- (hypot re im) re) 2.0)) |
2 calls. Slowest were:
| 98.0ms | (sqrt (* (- (hypot re im) re) 2.0)) |
| 45.0ms | (- (hypot re im) re) |
11 calls. Slowest were:
| 163.0ms | (sqrt (* (- (* (hypot re im) (hypot re im)) (* re re)) 2.0)) |
| 55.0ms | (sqrt (* (- (pow (hypot re im) 3) (pow re 3)) 2.0)) |
| 3.0ms | (sqrt (- (hypot re im) re)) |
5 alts after pruning (4 fresh and 1 done)
Merged error: 11.7b
Found 2 expressions with local error:
| 0.5b | (- (hypot re im) re) |
| 0.4b | (* (sqrt (- (hypot re im) re)) (sqrt 2.0)) |
2 calls. Slowest were:
| 7.0ms | (* (sqrt (- (hypot re im) re)) (sqrt 2.0)) |
| 3.0ms | (- (hypot re im) re) |
2 calls. Slowest were:
| 91.0ms | (* (sqrt (- (hypot re im) re)) (sqrt 2.0)) |
| 32.0ms | (- (hypot re im) re) |
23 calls. Slowest were:
| 221.0ms | (* (* (* (sqrt (- (hypot re im) re)) (sqrt (- (hypot re im) re))) (sqrt (- (hypot re im) re))) (* (* (sqrt 2.0) (sqrt 2.0)) (sqrt 2.0))) |
| 100.0ms | (* (sqrt (- (* (hypot re im) (hypot re im)) (* re re))) (sqrt 2.0)) |
| 30.0ms | (* (sqrt (- (pow (hypot re im) 3) (pow re 3))) (sqrt 2.0)) |
5 alts after pruning (4 fresh and 1 done)
Merged error: 11.7b
Found 4 expressions with local error:
| 14.5b | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
| 0.0b | (sqrt (* (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) 2.0)) |
| 0.0b | (sqrt (hypot re im)) |
| 0.0b | (sqrt (hypot re im)) |
4 calls. Slowest were:
| 3.0ms | (sqrt (* (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) 2.0)) |
| 2.0ms | (sqrt (hypot re im)) |
| 2.0ms | (sqrt (hypot re im)) |
4 calls. Slowest were:
| 137.0ms | (sqrt (* (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) 2.0)) |
| 111.0ms | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
| 46.0ms | (sqrt (hypot re im)) |
| 45.0ms | (sqrt (hypot re im)) |
21 calls. Slowest were:
| 5.0ms | (sqrt (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re))) |
| 4.0ms | (sqrt (* (cbrt (hypot re im)) (cbrt (hypot re im)))) |
| 3.0ms | (- im re) |
11 alts after pruning (10 fresh and 1 done)
Merged error: 11.7b
Found 4 expressions with local error:
| 14.5b | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
| 14.5b | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
| 0.4b | (* (sqrt (fma (sqrt (hypot re im)) (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:
| 5.0ms | (* (sqrt (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re))) (sqrt (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)))) |
| 1.0ms | (sqrt (hypot re im)) |
| 0.0ms | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
4 calls. Slowest were:
| 116.0ms | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
| 96.0ms | (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) |
| 92.0ms | (* (sqrt (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re))) (sqrt (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)))) |
| 58.0ms | (sqrt (hypot re im)) |
39 calls. Slowest were:
| 113.0ms | (* (* (* (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)))) (* (* (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))))) |
| 47.0ms | (* (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re))) |
| 42.0ms | (* (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re)) (fma (sqrt (hypot re im)) (sqrt (hypot re im)) (- re))) |
12 alts after pruning (10 fresh and 2 done)
Merged error: 11.7b
0% (0.2b remaining)
Error of 13.4b against oracle of 13.2b and baseline of 13.4b