[pacman-dev] [PATCH 5/5] filelist_sort: check if filelist is presorted

Andrew Gregory andrew.gregory.8 at gmail.com
Tue Jan 3 07:15:58 UTC 2017

On 01/03/17 at 02:20pm, Allan McRae wrote:
> On 10/12/16 02:14, Andrew Gregory wrote:
> > Signed-off-by: Andrew Gregory <andrew.gregory.8 at gmail.com>
> > ---
> > 
> > This patch obviously won't do any good until packages start being built with
> > their file lists presorted, so we may want to defer it, but in the handful of
> > packages I tested, it did not cause a significant delay either.
> > 
> Would it be best to just recommend that repo databases are regenerated
> with the updated repo-add?   Not including this would result in the
> qsort operations on the pre-sorted file lists having the worst possible
> performance.

I wouldn't expect pre-sorting to degrade performance for modern qsort
implementations (it certainly didn't for me), but the performance hit
for unsorted dbs/packages is probably modest enough that it's better
to just go ahead and merge this.


More information about the pacman-dev mailing list