]> git.ipfire.org Git - thirdparty/rsync.git/commit
Improve performance of file_checksum()
authorJorrit Jongma <git@jongma.org>
Sun, 24 May 2020 22:30:55 +0000 (00:30 +0200)
committerWayne Davison <wayne@opencoder.net>
Mon, 25 May 2020 03:33:33 +0000 (20:33 -0700)
commitd474f2986e656a848780bc8b36a02297e75eb3ab
treea27436d2f7559fdebff09a5be4c1896dd833fdd0
parenta863c62cd191b4bfa196d2c898bc1780eab24deb
Improve performance of file_checksum()

Previously files were hashed in blocks of CSUM_CHUNK (64) bytes. This
causes significant overhead. The CSUM_CHUNK define cannot be changed as
md5.c depends on it, but there is no obvious reason to use it in
file_checksum(). By using CHUNK_SIZE (32 kB) instead, in some test
cases throughput more than doubles.
checksum.c