[pacman-dev] Various code-cleanups
VMiklos
vmiklos at frugalware.org
Fri Jan 19 11:48:59 EST 2007
On Wed, Jan 17, 2007 at 03:27:33PM -0600, Aaron Griffin <aaronmgriffin at gmail.com> wrote:
> On 1/17/07, Dan McGee <dpmcgee at gmail.com> wrote:
> >/* TODO only use of a math.h function in entire libalpm,
> > * can we get rid of it? Former code line:
> > *if(numscans > numtargs) {
> > */
> > if(numscans > sqrt(numtargs)) {
>
> Interesting point. It does appear that the sqrt is merely an
> optimization.
yes, it is. sorting ~3000 pkgs on my machine now takes ~45sec while
before it "never ended" (probably it would after a few hours)
if you want to add a test, then just add all the packages in the sync
repo to a transaction using the noconfilcts option then you'll see how
much time will the sort take with numtargs/2
udv / greetings,
VMiklos
--
Developer of Frugalware Linux, to make things frugal - http://frugalware.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://archlinux.org/pipermail/pacman-dev/attachments/20070119/42b1bea5/attachment.pgp>
More information about the pacman-dev
mailing list