[pacman-dev] more efficient use of db_cache needed

Nagy Gabor ngaba at petra.hos.u-szeged.hu
Wed Feb 28 14:40:55 EST 2007

It's common practise that you load pkgcache with INFRQ_DEPENDS or
similar which is slow, because you must read the whole db directory.
Instead it would be more optimal, if you'd load db_cache with
INFRQ_NONE almost always (in case of thransactions where only few
packages are affected), because that is very fast (name and version are
computed from the directory name, so you need to read only the root
directory of the repo). And if you find the required package by name,
you can read the required info. So first _alpm_db_scan with INFRQ_NONE
then _alpm_db_read
Bye, Nagy Gabor

More information about the pacman-dev mailing list