View previous topic :: View next topic |
Author |
Message |
StrCrssd n00b
Joined: 17 Apr 2002 Posts: 68 Location: McAllen, TX USA
|
Posted: Tue May 28, 2002 10:23 pm Post subject: -j make switch |
|
|
Where is the setting that allows multiple processors to be used during compiling? This would normally be make -j x where x is (#of processors+1).
I haven't been able to locate a place to put this switch?
--StrCrssd |
|
Back to top |
|
|
lx Veteran
Joined: 28 May 2002 Posts: 1012 Location: Netherlands
|
Posted: Tue May 28, 2002 10:39 pm Post subject: |
|
|
look in /etc/make.globals ... MAKEOPTS="-j2" you can probably override it from /etc/make.conf but I haven't tried it. Hope this helps,
Cya lX _________________ "Remember there's a big difference between kneeling down and bending over.", Frank Zappa |
|
Back to top |
|
|
Curious Bodhisattva
Joined: 13 May 2002 Posts: 395 Location: Sydney, Australia
|
Posted: Wed May 29, 2002 2:53 am Post subject: Re: -j make switch |
|
|
StrCrssd wrote: | Where is the setting that allows multiple processors to be used during compiling? This would normally be make -j x where x is (#of processors+1). |
Hi... you might be interested, but this doesn't have to necessarily be related to the number of processors you have. The -j switch controls how many compile processes you spawn - so yeah, it's usually best to have 1 per processor, +1 to soak up any spare cycles, but there are circumstances where you might want to run more in parallel, even on a uniprocessor.
Regards,
Curious. _________________ Are you down with the Hawk? |
|
Back to top |
|
|
StrCrssd n00b
Joined: 17 Apr 2002 Posts: 68 Location: McAllen, TX USA
|
Posted: Wed May 29, 2002 6:41 am Post subject: RE: # of processes |
|
|
Actually I already knew that but needed to get the question posted quickly. |
|
Back to top |
|
|
lasa n00b
Joined: 17 May 2002 Posts: 63 Location: Stockholm, Sweden
|
Posted: Wed May 29, 2002 8:49 am Post subject: |
|
|
I entered MAKEOPTS="-j3" in my make.conf on my dual system and I can confirm that it overrides the setting in make.globals.
-lasa- |
|
Back to top |
|
|
id10t Tux's lil' helper
Joined: 18 May 2002 Posts: 100
|
Posted: Wed May 29, 2002 12:52 pm Post subject: |
|
|
Don't forget that buliding in parallel breaks some things...
Safer/easier to do
alias make="make -j4"; emerge foo
When you need/want it... _________________ ---
this space for rent |
|
Back to top |
|
|
tgnb Apprentice
Joined: 16 Apr 2002 Posts: 208 Location: New York, NY
|
Posted: Wed May 29, 2002 6:14 pm Post subject: dual |
|
|
Actually from what i have read at 2cpu.com -j 16 is supposedly the sweet spot for compiling the kernel (and presumably other things). The number after -j according to them determines the amount of simultaneous threads that get executed. The article can be found here:
http://www.2cpu.com/OSs/Linux/kerneltweak.html
I have also read about -j 16 being the sweet spot elsewhere but i dont remember where.
---
Thanks StrCrssd i'll try out your tip next time. |
|
Back to top |
|
|
|