What are the pros and cons of different C++ compilers for scientific computing?

  • Context: C/C++ 
  • Thread starter Thread starter orstats
  • Start date Start date
  • Tags Tags
    C++ Compiler
Click For Summary
SUMMARY

The discussion focuses on selecting the most suitable C++ compiler for numerical integration and Fast Fourier transforms on Intel Duo core processors running MS OS. Key contenders include Intel C++ Compiler, MS Visual Studio 2005, and MS Visual Studio 2008, with the latter noted for its superior standard compliance. The Intel compiler is highlighted for its optimization capabilities, particularly when paired with optimized libraries like Intel's MLK library. Ultimately, the consensus is that testing various compilers and optimization flags is essential to determine the best fit for specific applications.

PREREQUISITES
  • Understanding of C++ programming and numerical methods
  • Familiarity with Intel MKL (Math Kernel Library)
  • Knowledge of compiler optimization techniques
  • Experience with MS Visual Studio and GCC
NEXT STEPS
  • Research the performance differences between Intel C++ Compiler and MS Visual Studio 2008
  • Explore optimization flags in GCC for numerical computing
  • Learn how to utilize Intel MKL for enhanced performance in C++ applications
  • Conduct benchmarking tests on different compilers for specific numerical tasks
USEFUL FOR

Software developers, computational scientists, and engineers involved in scientific computing who are evaluating C++ compilers for performance optimization.

orstats
Messages
14
Reaction score
0
Hello:

I need to write some numerical integration and do Fast Fourier transforms in c++. I am running MS OS on Intel Duo core processors. Earlier post suggested downloading libraries such as MLK. Since I am running on Intel, I have found Intel's MLK library. I will need other libraries along the way. However, before that I need to choose a C++ compiler to download.

What are you suggestions? E.g., Intel C++ Compiler vs. MS Visual Studio 2005 vs. MS Visual Studio 2008 etc.

Because our problem may not be solved easily in MATLAB. We're moving into C++. Thank you!
 
Technology news on Phys.org
VS2008 compiler (version 9) has much better standard compliance than previous MS compilers. GCC always had very good optimisation because it's output format allowed link-level function optimisation. Intel's compiler should have an advantage.


What is probably mor elikely to have a bigger effect is the libraries - especially if they are optomisedfor a particular processor. Intel used to ship different versions of it's image libs which autodetected your processor.

You will have to do some testing to find out which is best for your app. With pipelines, cache effects and the number of possible optimisations in modern compilers you really have to test - even with different optimise flags on the same compiler.
 

Similar threads

  • · Replies 29 ·
Replies
29
Views
4K
  • · Replies 25 ·
Replies
25
Views
15K
  • · Replies 1 ·
Replies
1
Views
4K
Replies
3
Views
1K
Replies
59
Views
9K
  • · Replies 20 ·
Replies
20
Views
4K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 13 ·
Replies
13
Views
6K
  • · Replies 2 ·
Replies
2
Views
3K