Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Check libm vs Eps1Over1e3Erf performance #61

Open
hombit opened this issue Dec 4, 2024 · 0 comments
Open

Check libm vs Eps1Over1e3Erf performance #61

hombit opened this issue Dec 4, 2024 · 0 comments

Comments

@hombit
Copy link
Member

hombit commented Dec 4, 2024

Currently it looks like they have the same performance and we can safely drop Eps1Over1e3Erf.

cargo bench

Benchmarking erf_eps_1over1e3 for f32: Collecting 100 samples in estimated 5.0000 s (2
erf_eps_1over1e3 for f32
                        time:   [1.9824 ns 1.9927 ns 2.0038 ns]
Found 7 outliers among 100 measurements (7.00%)
  3 (3.00%) high mild
  4 (4.00%) high severe

Benchmarking libm::erf(f) for f32: Collecting 100 samples in estimated 5.0000 s (2.5B
libm::erf(f) for f32    time:   [1.9677 ns 1.9789 ns 1.9913 ns]
Found 3 outliers among 100 measurements (3.00%)
  3 (3.00%) high mild

But also

Benchmarking DmDt<f32>::convert_lc_to_gausses, erf type is Eps1Over1e3Erf: Warming up
Benchmarking DmDt<f32>::convert_lc_to_gausses, erf type is Eps1Over1e3Erf: Collecting
DmDt<f32>::convert_lc_to_gausses, erf type is Eps1Over1e3Erf
                        time:   [184.31 µs 184.62 µs 184.96 µs]
Found 3 outliers among 100 measurements (3.00%)
  1 (1.00%) high mild
  2 (2.00%) high severe

Benchmarking DmDt<f64>::convert_lc_to_gausses, erf type is ExactErf: Warming up for 3.0000 s
Warning: Unable to complete 100 samples in 5.0s. You may wish to increase target time to 5.1s, enable flat sampling, or reduce sample count to 60.
Benchmarking DmDt<f64>::convert_lc_to_gausses, erf type is ExactErf: Collecting 100 sa
DmDt<f64>::convert_lc_to_gausses, erf type is ExactErf
                        time:   [1.0261 ms 1.0298 ms 1.0337 ms]
Found 3 outliers among 100 measurements (3.00%)
  1 (1.00%) low mild
  2 (2.00%) high mild
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant