Hello,
Le 25/11/2024 à 17:04, Sam Russell a écrit :
I've added a sample benchmarking program to measure the difference without
hitting disk, looking like a 40% speedup
$ time ./cksum_bench_pclmul 1048576 10000
Hash: EFA0B24F, length: 1048576
real 0m3.018s
user 0m3.018s
sys 0m0.000s
$ time ./cksum_bench_avx2 1048576 10000
Hash: EFA0B24F, length: 1048576
real 0m1.824s
user 0m1.804s
sys 0m0.020s
If I may, you might be interested in looking into
https://github.com/sharkdp/hyperfine for benchmarking this type of change.
(it is available in Debian & Ubuntu).
As a side note, samply is amazing for performance profiling:
https://github.com/mstange/samply
Cheers,
Sylvestre