suggest 'make -j2' for SMP machines?

Deskin Miller deskinm at
Sun Jun 3 14:36:56 PDT 2007

I'm new to the list, having recently built an LFS system on an old
Pentium Pro machine, and I'm now in the middle of building another on
an SMP Pentium II box.  I noticed, while timing the SBU compilation of
binutils in Section 5.3, if I put 'make && make install', that the
wall-clock time was about 12m56s; while user time was about 7m.  If
instead I compiled with 'make -j2 && make -j2 install', wall-clock
time went down to about 8m, with negligible change to user time, i.e.
output something like the following:

$ time {../binutils/configure <options> && make && make install ; }

real      12m56s
user     7m15s
sys       1m10s

Compare to:

$ time {../binutils/configure <options> && make -j2 && make -j2 install ; }

real      8m31s
user     7m16s
sys       1m10s

Note that user+sys time (the time our build process was actually on a
CPU somewhere) varied hardly at all, but wall-clock time came down
appreciably.  This suggests that make -j2 will improve performance
somewhat on SMP systems, since make can exploit more parallelism; I'm
suggesting that this option be raised at the beginning of Section 4 or
5 somewhere, perhaps in SBU discussion (4.5 'About SBUs'), to let SMP
users know.

Is this worth adding to the book?  I'm continuing building using make
-j2, and haven't had any issues with it thus far; if I do discover
any, I'll be sure to post about it.

-Deskin Miller

More information about the lfs-dev mailing list