xbps icon indicating copy to clipboard operation
xbps copied to clipboard

Replace `xbps_file_hash_check_dictionary`

Open Duncaen opened this issue 1 year ago • 0 comments

Updated version of https://github.com/void-linux/xbps/pull/359, same results slightly different with less changes and ready to merge.

xbps_file_hash_check_dictionary was called for every file that is getting unpacked, because the files list is an array it iterated over the whole files array to find the matching file. With a lot of files this is really slow and a lot of time was spend in locking the proplib array and iterating over it.

Time from my Ryzen 3700X system with nvme disk updating texlive-fontsextra with files 86375:

time xbps-install -y texlive-fontsextra
    6m34.61s real     6m27.71s user     0m03.95s system

And with this patch:

time xbps-install -y texlive-fontsextra
    0m08.40s real     0m07.34s user     0m00.98s system

Duncaen avatar Jan 10 '24 18:01 Duncaen