I wasn't able to figure out how to run die harder on this library (cabal-plan seems to be some javascript-related doobry) but here, for reference, are some results after adding -O2 -fllvm to the ghc-options in the cabal file. cabal test, which I was expecting to do the diehard validation seems to complete v quickly (and successfully).
⇒ cabal bench master ✱
Build profile: -w ghc-8.8.3 -O1
In order, the following will be built (use -v for more details):
- splitmix-0.0.4 (bench:comparison) (first run)
- splitmix-0.0.4 (bench:range) (first run)
- splitmix-0.0.4 (bench:simple-sum) (first run)
Preprocessing benchmark 'range' for splitmix-0.0.4..
Preprocessing benchmark 'simple-sum' for splitmix-0.0.4..
Preprocessing benchmark 'comparison' for splitmix-0.0.4..
Building benchmark 'simple-sum' for splitmix-0.0.4..
Building benchmark 'comparison' for splitmix-0.0.4..
Building benchmark 'range' for splitmix-0.0.4..
Running 1 benchmarks...
Benchmark simple-sum: RUNNING...
Summing randoms...
Running 1 benchmarks...
Benchmark comparison: RUNNING...
benchmarking list/random
Running 1 benchmarks...
Benchmark range: RUNNING...
[8,3,6,4,4,5,9,3,8,3,9,2,0,6,8,3,6,1,6,9,9,3,7,9,7,7,6,3,6,3,4,9,2,6,7,0,1,7,4,0,7,4,6,6,5,1,7,8,6,1,0,0,0,3,9,8,2,6,6,0,0,3,8,1,8,4,7,2,5,9]
773728671
Benchmark simple-sum: FINISH
4193221127
loop: 214.406ms
[8,2,3,7,5,4,6,6,3,8,8,9,5,1,3,3,3,2,6,9,5,1,0,0,9,4,8,0,8,8,9,1,5,8,6,3,8,6,9,3,2,9,5,1,4,5,3,3,3,7,9,5,6,8,5,1,6,8,5,1,9,8,2,9,2,2,3,6,1,9]
184201478
loop: 24.328ms
[2,9,0,1,5,2,6,9,3,9,2,1,2,6,9,8,0,4,3,6,2,3,5,0,6,7,1,1,5,2,1,7,0,7,6,1,6,6,7,7,3,0,6,4,1,9,1,6,9,5,4,7,5,4,9,9,5,9,5,9,5,8,4,5,4,2,5,3,6,9]
399431642
loop: 22.441ms
[5,7,4,1,2,7,1,3,6,8,5,3,8,8,8,8,6,8,1,9,8,2,9,1,3,3,1,5,9,5,1,8,0,1,1,9,8,2,8,9,0,3,5,4,0,0,4,9,0,2,0,1,8,6,9,6,4,7,4,3,4,3,2,6,8,1,3,8,4,4]
4059709080
loop: 11.869ms
Benchmark range: FINISH
time 77.11 μs (75.32 μs .. 78.78 μs)
0.996 R² (0.995 R² .. 0.998 R²)
mean 78.16 μs (76.81 μs .. 80.03 μs)
std dev 5.283 μs (3.834 μs .. 7.376 μs)
variance introduced by outliers: 68% (severely inflated)
benchmarking list/tf-random
time 43.53 μs (43.31 μs .. 43.78 μs)
0.999 R² (0.999 R² .. 1.000 R²)
mean 43.89 μs (43.62 μs .. 44.27 μs)
std dev 1.111 μs (796.4 ns .. 1.469 μs)
variance introduced by outliers: 24% (moderately inflated)
benchmarking list/splitmix
time 10.50 μs (10.44 μs .. 10.59 μs)
0.999 R² (0.999 R² .. 1.000 R²)
mean 10.60 μs (10.53 μs .. 10.70 μs)
std dev 283.8 ns (216.5 ns .. 397.5 ns)
variance introduced by outliers: 30% (moderately inflated)
benchmarking list/splitmix32
time 53.10 μs (52.67 μs .. 53.65 μs)
0.999 R² (0.999 R² .. 1.000 R²)
mean 53.37 μs (53.02 μs .. 53.92 μs)
std dev 1.496 μs (1.077 μs .. 2.141 μs)
variance introduced by outliers: 27% (moderately inflated)
benchmarking tree/random
time 78.27 μs (77.75 μs .. 79.02 μs)
0.999 R² (0.998 R² .. 1.000 R²)
mean 78.80 μs (78.19 μs .. 80.15 μs)
std dev 2.952 μs (1.674 μs .. 5.519 μs)
variance introduced by outliers: 39% (moderately inflated)
benchmarking tree/tf-random
time 97.22 μs (96.57 μs .. 98.01 μs)
1.000 R² (0.999 R² .. 1.000 R²)
mean 97.81 μs (97.35 μs .. 98.93 μs)
std dev 2.319 μs (1.257 μs .. 4.271 μs)
variance introduced by outliers: 20% (moderately inflated)
benchmarking tree/splitmix
time 31.19 μs (30.90 μs .. 31.66 μs)
0.999 R² (0.997 R² .. 1.000 R²)
mean 31.33 μs (31.07 μs .. 31.76 μs)
std dev 1.113 μs (776.6 ns .. 1.565 μs)
variance introduced by outliers: 40% (moderately inflated)
benchmarking tree/splitmix32
time 54.17 μs (53.95 μs .. 54.40 μs)
1.000 R² (1.000 R² .. 1.000 R²)
mean 54.11 μs (53.92 μs .. 54.42 μs)
std dev 814.4 ns (560.5 ns .. 1.120 μs)
benchmarking list 64/random
time 690.3 μs (686.6 μs .. 694.7 μs)
0.999 R² (0.999 R² .. 1.000 R²)
mean 695.4 μs (690.1 μs .. 707.7 μs)
std dev 25.56 μs (15.74 μs .. 45.50 μs)
variance introduced by outliers: 28% (moderately inflated)
benchmarking list 64/tf-random
time 96.02 μs (95.22 μs .. 96.70 μs)
1.000 R² (0.999 R² .. 1.000 R²)
mean 95.70 μs (95.23 μs .. 96.72 μs)
std dev 2.201 μs (1.335 μs .. 3.679 μs)
variance introduced by outliers: 19% (moderately inflated)
benchmarking list 64/splitmix
time 10.52 μs (10.47 μs .. 10.59 μs)
0.999 R² (0.999 R² .. 1.000 R²)
mean 10.72 μs (10.56 μs .. 10.99 μs)
std dev 668.3 ns (360.0 ns .. 1.091 μs)
variance introduced by outliers: 71% (severely inflated)
benchmarking list 64/splitmix32
time 47.42 μs (47.15 μs .. 47.83 μs)
1.000 R² (0.999 R² .. 1.000 R²)
mean 47.34 μs (47.16 μs .. 47.66 μs)
std dev 798.2 ns (588.7 ns .. 1.131 μs)
variance introduced by outliers: 12% (moderately inflated)
benchmarking tree 64/random
time 393.0 μs (388.9 μs .. 397.5 μs)
0.999 R² (0.999 R² .. 1.000 R²)
mean 392.6 μs (391.2 μs .. 395.1 μs)
std dev 6.418 μs (4.380 μs .. 9.662 μs)
benchmarking tree 64/tf-random
time 118.6 μs (117.8 μs .. 119.5 μs)
1.000 R² (0.999 R² .. 1.000 R²)
mean 118.6 μs (118.1 μs .. 119.6 μs)
std dev 2.304 μs (1.638 μs .. 3.345 μs)
variance introduced by outliers: 13% (moderately inflated)
benchmarking tree 64/splitmix
time 30.04 μs (29.92 μs .. 30.22 μs)
1.000 R² (0.999 R² .. 1.000 R²)
mean 30.27 μs (30.10 μs .. 30.59 μs)
std dev 748.5 ns (507.9 ns .. 1.235 μs)
variance introduced by outliers: 24% (moderately inflated)
benchmarking tree 64/splitmix32
time 50.58 μs (50.43 μs .. 50.76 μs)
1.000 R² (0.999 R² .. 1.000 R²)
mean 50.99 μs (50.72 μs .. 51.53 μs)
std dev 1.311 μs (644.3 ns .. 2.098 μs)
variance introduced by outliers: 24% (moderately inflated)
Benchmark comparison: FINISH
And this is how fast die harder ran, for comparison.
I wasn't able to figure out how to run die harder on this library (cabal-plan seems to be some javascript-related doobry) but here, for reference, are some results after adding
-O2 -fllvmto theghc-optionsin the cabal file.cabal test, which I was expecting to do the diehard validation seems to complete v quickly (and successfully).And this is how fast die harder ran, for comparison.