Andre Poenitz wrote:
On Fri, Mar 23, 2007 at 09:28:24AM +0100, Georg Baum wrote:
Andre Poenitz wrote:

I just ttried binutils from cvs and got:

real    0m58.744s
user    0m8.969s
sys     0m2.604s

'top' shows a load of 1.3 (with nothing else reallyh running), at most
25% CPU and plenty of RAM free. So what happens there?
Seems they did some optimization :-) I have lost a bit of faith into
binutils lately (do you remember this strange 'discarded section' linker
bug?). Fortunately it seems the situation is improving.

Well, some optimization, yes.
I wonder, however, where the 46 seconds between  user+sys  and  real  are
spent. This is an otherwise _really_ quite system.
For a compile, the only place to spend this time is io-wait.
Typically, disk heads seeking all over the place in search of the
next file to read. (Or swapping, if your machine
don't have enough memory for compiling.)

No matter how much memory, the files will have to be read in once.
If you have enough memory, then a second (make clean ; make)
will be faster as there will be no need to read the cached files again.

For a machine with tons of memory, consider copying the source
tree into a ramdisk and compile from there. This avoids all io-related
waiting. Of course you loose the ramdisk contents upon the next reboot...

Helge Hafting



Reply via email to