Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Which x86 C++ compilers are multithreaded by itself?

Now almost an every user have a 2 or 4 cores on desktop (and on high number of notebooks). Power users have 6-12 cores with amd or i7.

Which x86/x86_64 C/C++ compilers can use several threads to do the compilation?

There is already a 'make -j N'-like solutions, but sometimes (for -fwhole-program or -ipo) there is the last big and slow step, which started sequentially.

Does any of these can: GCC, Intel C++ Compiler, Borland C++ compiler, Open64, LLVM/GCC, LLVM/Clang, Sun compiler, MSVC, OpenWatcom, Pathscale, PGI, TenDRA, Digital Mars ?

Is there some higher limit of thread number for compilers, which are multithreaded?

Thanks!

like image 826
osgx Avatar asked Dec 13 '10 14:12

osgx


1 Answers

Gcc has -flto=n or -flto=jobserver to make the linking step (which with LTO does optimization and code generation) parallel. According to the documentation, these have been available since version 4.6, although I am not sure how good it was in those early versions.

like image 125
Marc Glisse Avatar answered Sep 18 '22 14:09

Marc Glisse