awohld has asked for the wisdom of the Perl Monks concerning the following question:

I'm configuring CPAN and it's asking me this:
Parameters for the 'make' command? Typical frequently used setting: -j3 dual processor system Your choice: []

I have a single P4 processor with hyper threading which Linux treats as a dual processor. Should I enable the -j3 option?

Replies are listed 'Best First'.
Re: Configuring CPAN (MAKE) with P4 Hyper Threading Processor
by Tanktalus (Canon) on Apr 02, 2006 at 20:20 UTC

    I do. It can be faster, but for most CPAN modules, you won't notice a difference. I also have it enabled for my gentoo emerging - there it makes a bigger difference where there are files that really do take billions of cycles to compile.

    On a scale of 1 to 5, 1 being "don't you dare" and 5 being "you should have done this months ago", I give it a solid "eh, whatever." :-)

Re: Configuring CPAN (MAKE) with P4 Hyper Threading Processor
by ambrus (Abbot) on Apr 02, 2006 at 20:39 UTC

    If you expect that the makes succeed, then do enable it. However, when you get compilation errors, then the output of a paralel make can be very confusing, so don't enable -j3 in that case.

Re: Configuring CPAN (MAKE) with P4 Hyper Threading Processor
by sgifford (Prior) on Apr 02, 2006 at 23:29 UTC
    You should realize that this only affects the speed of building the modules, not the speed of the modules once they're installed. It's not a flag telling the compiler or perl anything, it's just telling make it should try to run more than one thing in parallel if possible. So if you get it wrong, you'll just spend a little extra time watching messages fly by from the CPAN shell.