Skip to content

Use xxhash

This MR replaces our previous thumbnail hashing using md5 with XXhash (https://github.com/Cyan4973/xxHash)

On my machine, with a test folder containing 855 audio media it makes the percentage of time spent computing the thumbnail hash from ≃10% to ≃0.5%

Which, in term of time, translates to:

./test/discoverer/discoverer file:///home/chouquette/Music  1.32s user 1.48s system 5% cpu 53.102 total
./test/discoverer/discoverer file:///home/chouquette/Music  1.17s user 1.56s system 5% cpu 54.040 total
./test/discoverer/discoverer file:///home/chouquette/Music  1.30s user 1.50s system 5% cpu 54.042 total

when using MD5, which averages to ≃86.3s

./test/discoverer/discoverer file:///home/chouquette/Music  1.09s user 1.61s system 4% cpu 54.018 total
./test/discoverer/discoverer file:///home/chouquette/Music  1.14s user 1.56s system 5% cpu 53.601 total
./test/discoverer/discoverer file:///home/chouquette/Music  1.19s user 1.56s system 5% cpu 53.972 total

when using XXHash, which averages to 74s

So this seems to cause about a 15.3% time gain

Edited by Hugo Beauzée-Luyssen

Merge request reports

Loading