View previous topic :: View next topic |
Author |
Message |
infogerance n00b
Joined: 31 May 2006 Posts: 27 Location: France
|
Posted: Sat Jan 06, 2007 12:44 am Post subject: [SMP] real multi core exploitation |
|
|
Hi,
I have a core 2 duo CPU.
I made a SMP capable kernel (up to 2 CPUs).
Then I booted on it.
MAKEOPTS="-j3".
# emerge -e system
I randomly have a look at the "top" output, and noticed that when compiling big softwares (Perl,...) only one "cc1" is running at a time (on one CPU).
The other one is idle. Waste of time!
What would be a solution to make "make" to really use simultaneously multiple CPUs? |
|
Back to top |
|
|
theotherjoe Guru
Joined: 22 Nov 2003 Posts: 393
|
Posted: Sat Jan 06, 2007 1:18 am Post subject: |
|
|
Assuming that you build your kernel properly and
you booted your new kernel, have a look into
dmesg and check if both cpus are brought up.
Another possibilty to check:
ls /sys/devices/system/cpu
there should be two subdirs (cpu0, cpu1) with
entries.
regarding MAKEOPTS, you may want to set your
parameter to -j4 or -j5. parallel makes are working but
there are some packages which are filtering the -j option,
esp. the GCC in some parts. |
|
Back to top |
|
|
nixnut Bodhisattva
Joined: 09 Apr 2004 Posts: 10974 Location: the dutch mountains
|
Posted: Sat Jan 06, 2007 1:00 pm Post subject: |
|
|
Moved from Installing Gentoo to Kernel & Hardware.
Not about getting gentoo installed, so moved here. _________________ Please add [solved] to the initial post's subject line if you feel your problem is resolved. Help answer the unanswered
talk is cheap. supply exceeds demand |
|
Back to top |
|
|
infogerance n00b
Joined: 31 May 2006 Posts: 27 Location: France
|
Posted: Sat Jan 06, 2007 2:06 pm Post subject: [solved] Fully using multi cores |
|
|
theotherjoe wrote: |
Another possibilty to check:
ls /sys/devices/system/cpu
there should be two subdirs (cpu0, cpu1) with
entries. |
There are cpu0 and cpu1.
theotherjoe wrote: |
regarding MAKEOPTS, you may want to set your
parameter to -j4 or -j5. |
Uh man it rooooocks! 4 parallell cc1 dispatched on the two cores!
CPU storming rulez!
I dont know why -j3 si adviced for dual core... It's -j5 man! |
|
Back to top |
|
|
|