This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Question: single CPU usage


On Thu, 16 Aug 2001, Joy Woodford wrote:

> I have been advised that gcc will only use one CPU on any machine that
> it is running. Is this true? Are there any plans to make gcc take
> advantage of additional CPUs in a system?

There is no need to do so; your build tools can handle this for you. For
example, doing

make -j N foo

will build foo running at most N jobs in parrallel (with most makes; some
don't have this feature - use GNU make if yours doesn't). Presuming that
your OS is SMP-aware and you have N CPUs, your compilation will use all of
them. If you're refering to parrelelizing the interals of GCC (ie,
compiling a single file will use all available CPUs via with threads or
something), that would probably be pretty hard.

Jack


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]