Did i just made the fastest dependency checker in the world? (198 packages in 1.5 seconds)

Mark markg85 at gmail.com
Thu Apr 12 07:28:16 UTC 2007


yea it`s interesting indeed.
but just to clear it up.. php is just used because i know php. the actual
speed is in MySQL
the final script should be done in c/c++ with mysql and i expect that to be
alot faster in total parsetime.
mysql won`t speed up much.. even likely to slow down more with all the
checks that needs to be done.


2007/4/12, Panu Matilainen <pmatilai at laiskiainen.org>:
>
> On Wed, 11 Apr 2007, Rahul Sundaram wrote:
>
> > Mark wrote:
> >> forgive me if i sound hard but:
> >> do you really need proof to see that the dependency checking is a
> highly
> >> time consuming thing.
> >> i just did a yum update.
> >> i had a 100% cpu usage for a few minutes during the dep checking.
> that`s
> >> _TOO_ much for just a update. (oke.. this is a update of 148 packages
> but
> >> still)
> >>
> >> it just seems overkill for me.. specially now that i know that it can
> all
> >> be done in well under a second in a logic way :P
> >>
> >
> > You  _don't_ know that. What you are doing might be logical in a
> simplistic
> > way but it just doesn't deal with a lot of real world cases. When you
> actual
> > start dealing with all of the logic that is required to solve the
> > dependencies properly you would lose the speed advantage that you
> currently
> > have.
>
> Well, depsolving *can* be that fast, the proof can be found in apt-rpm
> which takes just a few seconds (depends on the computer speed of course)
> to calculate something like fc5 -> fc6 upgrade with over thousand
> packages. Apt does pay some penalty for abstracting packaging systems
> (deb vs rpm) and for all the wacko pinning + other package priority
> calculations, plain rpm depsolve in C would be quite a bit faster still.
>
> As for yum depsolve speed... the folks just rewrote the yum depsolver to
> avoid having to download headers for depsolving, a no small feat.
> Correctness needs to come first, speed is secondary (although important)
> issue. Just how fast it can be made with just python remains to be seen
> (people are working on improving the speed all the time), but writing
> mockup depsolvers in PHP isn't going to help that cause. Writing a
> depsolver in any language is of course an interesting self-education,
> nothing wrong with that :)
>
>        - Panu -
>
>
>
> --
> fedora-devel-list mailing list
> fedora-devel-list at redhat.com
> https://www.redhat.com/mailman/listinfo/fedora-devel-list
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/fedora-devel-list/attachments/20070412/d67b38d8/attachment.htm>


More information about the fedora-devel-list mailing list