Hi, On Fri, 5 May 2006 18:49:29 +0530 Farhan Ahmed <[EMAIL PROTECTED]> wrote:
> > The difference is: with -j2 box is slow. A lot of packages do not > > compile because of ooms. > > > > with -j1 box is normal. No ooms. Compiling does not take longer as > > with -j2. > > This is the first time I'm hearing this.. Even with -j2 my system > functions normally.. Has anyone encountered same problem? Not really. GCC does eat some memory, but it's not that worse. Well, this does absolutely depend on RAM+Swap. Whenever I had oom conditions in the past 4 years, that was because of a leaky, long-running application. I've yet to see a gcc process that claims 100MB of physical memory. I did see Apache eat such an amount of mem after running some days and calling leaky skripts (integrated as a module, of course). Another way to get OOMs here would probably to limit maximum memory usage too much. The only thing that breaks -j<N> for make are Makefiles that base on broken assumptions. Those Makefiles are buggy and to be reported. Running -j<N> for N>1 on a UP machine won't likely bring too much speed. It may have some small positive effects due to better distribution of IO load and process creation. That's the real culprit when compiling: Lots of context switches for each make process. So what probably gives a little more speed is setting the scheduler HZ value to >100 (but this isn't the default any more). "vmstat" is a good tool to >monitor the amount of context switches. -hwh -- gentoo-user@gentoo.org mailing list