Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 13 May 2007 10:58:22 +0200
From:      "[LoN]Kamikaze" <LoN_Kamikaze@gmx.de>
To:        Kris Kennaway <kris@obsecurity.org>
Cc:        Stephen Montgomery-Smith <stephen@math.missouri.edu>, freebsd-ports@freebsd.org
Subject:   Re: Time to abandon recursive pulling of dependencies?
Message-ID:  <4646D32E.8020507@gmx.de>
In-Reply-To: <20070513084931.GA35696@xor.obsecurity.org>
References:  <464597C6.3030406@gmx.de>	<20070512174011.GA22526@xor.obsecurity.org> <4645FF71.60100@gmx.de>	<20070512175824.GA23103@xor.obsecurity.org>	<20070512133054.B5588@math.missouri.edu>	<4646193E.5040503@gmx.de> <464665D5.1090509@math.missouri.edu>	<4646AC48.1010107@gmx.de> <4646CFE3.1020105@gmx.de> <20070513084931.GA35696@xor.obsecurity.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Kris Kennaway wrote:
> On Sun, May 13, 2007 at 10:44:19AM +0200, [LoN]Kamikaze wrote:
>> [LoN]Kamikaze wrote:
>>> Stephen Montgomery-Smith wrote:
>>>> OK chaps, this is what I came up with.  So for example, if I do "make
>>>> install" on /usr/ports/x11/xorg (having made all the dependencies), on
>>>> my computer it turns the pkg_create from taking about 4 minutes to the
>>>> blink of an eye.  Now people need to figure out how to speed up the
>>>> "make package-depends" in bsd.ports.mk, but that is beyond my abilities.
>>> I will give that a try, I've been experimenting with make a lot lately. Thank
>>> you for your patch, the second attempt seems to work fine on my system.
>> So far I've got a 20% performance increase, not really satisfying. The trouble
>> is that for every dependency the whole bsd.port.mk and whatever else is pulled
>> in by the dependency has to be parsed again. So the only way to make a
>> significant improvement is to have a short bsd.port.mk.
> 
> Again, what evidence do you have that *that* is really the problem?
> Please try to be more scientific in your approach, it will help all of
> us to figure this out.
> 
> Kris

Well, it takes about 1 minute and 15 seconds for x11/xorg on my system, which
has 273 dependencies, with my optimizations it still takes 60 seconds.

Parsing bsd.port.mk takes an average of 0.2 seconds on my system. 0.2 * 273 =
54.6 seconds. Which looks like the major part of computation time to me.

The only way to avoid this I see, is to abandon the recursive pulling in.
Packages wouldn't know all their dependencies any more, but the dependencies
would still know what they depend on and so forth.

I will just change my system and see weather it breaks. I suspect that some
things like pkg_add -r would have to be slightly adjusted to support such a change.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4646D32E.8020507>