Modified April 28, 2019
I (Bjarne Stroustrup) am often asked to recommend a C++ compiler. However, I don't make recommendations; that would be too much like taking sides in commercial wars. Also, I don't know every C++ compiler; there are simply too many 'out there'.
Online C Compiler, Online C Editor, Online C IDE, C Coding Online, Practice C Online, Execute C Online, Compile C Online, Run C Online, Online C Interpreter, Compile and Execute C Online (GNU GCC v7.1.1). Step #1: Install C/C compiler and related tools. If you are using Fedora, Red Hat, CentOS, or Scientific Linux, use the following yum command to install GNU c/c compiler: # yum groupinstall 'Development Tools'. If you are using Debian or Ubuntu Linux, type the following apt-get command to install GNU c/c compiler.
I recommend that people take Standard conformance very seriously when considering a compiler. If you can, avoid any compiler that doesn't closely approximate the ISO standard or fails to supply a solid implementation of the standard library. The recent releases from all the major C++ vendors do that.
Most of these compilers are embedded in frameworks of software development tools and libraries. These frameworks, environments, and libraries can be most helpful, but do remember that their use can lock you into a single vendor and that some uses have significant run-time performance implications.
When looking for C++ on the web, you find that much of the information is 'hidden' under various product names. In fact, I had more luck finding C++ compilers using google.com than by going directly to vendors that I knew sold them. Here, I have chosen to list C++ implementations simply by the name of their provider, ignoring marketing labels.
C Compiler Online
Some compilers that can be downloaded for free (do check their conditions/licenses before attempting commercial use):
- Apple C++. Xcode. It also comes with OS X on the developer tools CD.
- Bloodshed Dev-C++. A GCC-based (Mingw) IDE.
- Clang C++. A relatively very active development associated with the analysis and code generation framework, LLVM.
- MINGW - 'Minimalist GNU for Windows'. Another GCC version for Windows including a free (non-GPL) w32api.
- IBM C++ for IBM power, System Z, Bluegene, and Cell.
- Microsoft Visual C++.
- Oracle C++.
Some compilers that require payment (some allow free downloads for trial periods):
- Edison Design Group C++ Front End - used by many C++ compiler suppliers
- Green Hills C++ for many embedded systems platforms
- Intel C++ for Windows, Linux, and some embedded systems.
- Mentor Graphics Sourcery CodeBench An extensive 'Workbench' for many embedded systems platforms.
- Paradigm C++, for x86 embedded systems
- The Portland Group C++ (parallelization and GPUs)
- WindRiver's Diab C++ used in many embedded systems.
Other lists of C++ compilers:
- Compilers.net: A list of free C and C++ compilers.
A filter to improve error messages from many compilers see STLfilt.