From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1PiWMw-0006C9-1c for garchives@archives.gentoo.org; Thu, 27 Jan 2011 18:14:54 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 4567AE0AE9; Thu, 27 Jan 2011 18:13:26 +0000 (UTC) Received: from ksp.sk (element.ksp.sk [158.195.16.154]) by pigeon.gentoo.org (Postfix) with ESMTP id F02AAE0AE9 for ; Thu, 27 Jan 2011 18:13:25 +0000 (UTC) Received: by ksp.sk (Postfix, from userid 1004) id 3F7544C19E; Thu, 27 Jan 2011 19:13:25 +0100 (CET) Date: Thu, 27 Jan 2011 19:13:25 +0100 From: YoYo Siska To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] Re: Simultaneously emerging multiple packages with same dependencies Message-ID: <20110127181325.GA26616@ksp.sk> References: <20110127140525.GA4844@ksp.sk> <201101271512.50141.joost@antarean.org> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201101271512.50141.joost@antarean.org> X-YoYo: 47 X-Exotic-Header-Data: 47/2 User-Agent: Mutt/1.5.20 (2009-06-14) X-Archives-Salt: X-Archives-Hash: c4310c8654f6bca244a423815f3a8ed3 On Thu, Jan 27, 2011 at 03:12:49PM +0100, J. Roeleveld wrote: > On Thursday 27 January 2011 15:05:25 YoYo Siska wrote: > > On Thu, Jan 27, 2011 at 03:33:21PM +0200, Nikos Chantziaras wrote: > > > On 01/27/2011 03:11 PM, Dale wrote: > > > >[...] > > > >I am using the -j option for the first time now. I'm updating KDE. It > > > >seems to work fine. It doesn't scroll all the stuff like with a regular > > > >emerges but this new rig is so fast, I can't read it anyway. I did have > > > >a package to fail and it spit out the error for me to read. > > > > > > You don't need that if you have MAKEOPTS set in your make.conf, > > > which is preferred. The -j option of emerge emerges multiple > > > packages, while with MAKEOPTS set to "-j4" or whatever does a > > > parallel build in the same package (meaning compiling multiple > > > source files at the same time). > > > > > > It's preferred because with "emerge -jN" the last package will only > > > use one CPU, while with "-jN" in MAKEOPTS even the last package will > > > use N CPUs. Furthermore, emerge can't always build N packages at > > > the same time because one can depend on the other, so it will have > > > to wait until the dependency is built. > > > > On the other hand, unpacking, configure and install stages are not > > parallel and emerge can do those in parallel for different packages... > > The best would be somewhere in the middle ;) > > > > > > There are also the load-average options to -j, i.e.: > > MAKEOPTS="-j -l5" emerge -j --load-average=5 .... > > > > which makes make spawn parallel processes while load average is below 5 > > and the same for emerge spawning parallel ebuilds (when make isn't > > parallel enough) > > > > yoyo > > Hmmm... didn't know about that one yet. > Does that mean that by doing it like that, the emerge-process (and compile- > processes) will try to keep the load average at 5 and if that is lower, it > will keep adding more processes? > Yes. It might not be perfect, but mostly it works pretty well. Once make started 10 or so process, which ate all my ram, because I forgot to reenable swap, when I was playing with something before that :) yoyo