Skip to content

Instantly share code, notes, and snippets.

@darach
Created November 7, 2014 00:37
Show Gist options
  • Save darach/7e3622088df89ba72ac7 to your computer and use it in GitHub Desktop.
Save darach/7e3622088df89ba72ac7 to your computer and use it in GitHub Desktop.
rebar get-deps compile
==> cake (get-deps)
==> jch-erl (get-deps)
==> cake (compile)
==> jch-erl (compile)
Checking whether the PLT .plt is up-to-date... yes
Proceeding with analysis...
Unknown functions:
done in 0m0.42s
done (passed successfully)
rebar skip_deps=true eunit ct
==> jch-erl (eunit)
There were no tests to run.
==> jch-erl (ct)
WARN: test directory not present - skipping
gcc -O3 -I c_src perf/ch.c c_src/jch.o -o perf/ch
perf/ch 10000000 10
ch/perf: n: 10000000 b: 10 elapsed: 0.526528 (5265280.000000 hps, 52.652800 nsh).
perf/ch 10000000 100
ch/perf: n: 10000000 b: 100 elapsed: 0.876230 (8762300.000000 hps, 87.623000 nsh).
perf/ch 10000000 1000
ch/perf: n: 10000000 b: 1000 elapsed: 1.158390 (8632671.207452 hps, 115.839000 nsh).
perf/ch 10000000 10000
ch/perf: n: 10000000 b: 10000 elapsed: 1.427135 (7007045.584335 hps, 142.713500 nsh).
perf/ch 10000000 100000
ch/perf: n: 10000000 b: 100000 elapsed: 1.718047 (5820562.534087 hps, 171.804700 nsh).
perf/ch 10000000 1000000
ch/perf: n: 10000000 b: 1000000 elapsed: 1.999667 (5000832.638634 hps, 199.966700 nsh).
perf/ch 10000000 10000000
ch/perf: n: 10000000 b: 10000000 elapsed: 2.270849 (4403639.343699 hps, 227.084900 nsh).
perf/ch 10000000 100000000
ch/perf: n: 10000000 b: 100000000 elapsed: 2.552204 (3918182.088893 hps, 255.220400 nsh).
erlc -pa ebin perf/bench.erl -o perf
ERL_LIBS=deps erl +sfwi 1 +scl false -pa ebin -pa perf -noinput -eval "bench:main([])"
JCH. Performance microbenchmark suite.
warmup N: 10 Min: -----0 Max: ---920 Median: -----0 Avg: ----92 Elapsed: 2465
warmup N: 10 Min: -----0 Max: -----1 Median: -----0 Avg: -----0 Elapsed: 12
warmup N: 10 Min: -----0 Max: -----1 Median: -----0 Avg: -----0 Elapsed: 11
warmup N: 10 Min: -----0 Max: -----1 Median: -----0 Avg: -----0 Elapsed: 11
warmup N: 10 Min: -----0 Max: -----1 Median: -----0 Avg: -----0 Elapsed: 11
warmup N: 10 Min: -----0 Max: -----1 Median: -----0 Avg: -----0 Elapsed: 11
- 100 Buckets. Hash performance.
ch100 N: 10 Min: -----0 Max: -----0 Median: -----0 Avg: -----0 Elapsed: 10
ch100 N: 100 Min: -----0 Max: -----1 Median: -----0 Avg: -----0 Elapsed: 90
ch100 N: 1000 Min: -----0 Max: -----2 Median: -----0 Avg: -----0 Elapsed: 912
ch100 N: 10000 Min: -----0 Max: -----9 Median: -----0 Avg: -----0 Elapsed: 8898
ch100 N: 100000 Min: -----0 Max: ----30 Median: -----0 Avg: -----0 Elapsed: 90837
ch100 N: 1000000 Min: -----0 Max: ----71 Median: -----0 Avg: -----0 Elapsed: 873615
ch100 N: 10000000 Min: -----0 Max: --2462 Median: -----0 Avg: -----0 Elapsed: 8889208
- 10K Buckets. Hash performance.
ch10k N: 10 Min: -----0 Max: -----2 Median: -----0 Avg: -----0 Elapsed: 15
ch10k N: 100 Min: -----0 Max: -----1 Median: -----0 Avg: -----0 Elapsed: 89
ch10k N: 1000 Min: -----0 Max: -----2 Median: -----0 Avg: -----0 Elapsed: 967
ch10k N: 10000 Min: -----0 Max: -----1 Median: -----0 Avg: -----0 Elapsed: 8348
ch10k N: 100000 Min: -----0 Max: ----15 Median: -----0 Avg: -----0 Elapsed: 93468
ch10k N: 1000000 Min: -----0 Max: --3228 Median: -----0 Avg: -----0 Elapsed: 855458
ch10k N: 10000000 Min: -----0 Max: --3013 Median: -----0 Avg: -----0 Elapsed: 9588398
- 1M Buckets. Hash performance.
ch1m N: 10 Min: -----0 Max: -----3 Median: -----1 Avg: -----1 Elapsed: 16
ch1m N: 100 Min: -----0 Max: -----1 Median: -----0 Avg: -----0 Elapsed: 93
ch1m N: 1000 Min: -----0 Max: ----10 Median: -----0 Avg: -----0 Elapsed: 1178
ch1m N: 10000 Min: -----0 Max: ----10 Median: -----0 Avg: -----0 Elapsed: 9208
ch1m N: 100000 Min: -----0 Max: ---184 Median: -----0 Avg: -----0 Elapsed: 99821
ch1m N: 1000000 Min: -----0 Max: ----21 Median: -----0 Avg: -----0 Elapsed: 901366
ch1m N: 10000000 Min: -----0 Max: --3629 Median: -----0 Avg: -----0 Elapsed: 10124898
- 1B Buckets. Hash performance.
ch1b N: 10 Min: -----1 Max: -----3 Median: -----1 Avg: -----1 Elapsed: 17
ch1b N: 100 Min: -----0 Max: -----1 Median: -----1 Avg: -----1 Elapsed: 101
ch1b N: 1000 Min: -----0 Max: -----9 Median: -----0 Avg: -----0 Elapsed: 1108
ch1b N: 10000 Min: -----0 Max: ----10 Median: -----0 Avg: -----0 Elapsed: 9764
ch1b N: 100000 Min: -----0 Max: ----76 Median: -----0 Avg: -----0 Elapsed: 109074
ch1b N: 1000000 Min: -----0 Max: ---968 Median: -----0 Avg: -----0 Elapsed: 981378
ch1b N: 10000000 Min: -----0 Max: -10314 Median: -----0 Avg: -----0 Elapsed: 11058174
- 32 Buckets. 1M hashes Uniform Distribution Check.
31154 31240 31211 31471 31355 31312 31127 31305
30953 31338 31155 31125 31264 31207 31215 31064
31225 31333 31456 31354 30981 31214 31449 31511
31314 31075 31037 31315 31191 31378 31374 31297
oOo| Min: -30953 Max: -31511 Median: -31240 Avg: -31250 Elapsed: 1656319
Worst: 98.2292 Med: 99.1400 Avg: 99.1717 RSD: 2.5097
- 4096 (4K) Buckets. 100M hashes Uniform Distribution Check.
CTRL-C ... VM goes kaffluey at this point ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment