In most cases you (a little inaccurately) call gcc the compiler. A reason is that you can run the whole tool chain, at least for simple projects, with a single gcc command. Let's say you have this main.c

// main.c
#include <stdio.h>
int main(void)
{
    printf("Hello, world!\n");
}

and compile it with

gcc main.c

Then everything you mentioned, cpp, cc1, as and ld will be involved in creating the executable a.out. Well, almost. cpp is old and newer versions of the compiler has the preprocessor integrated.

If you want to see the output of the preprocessor, use gcc -E main.c

As I mentioned, the preprocessor and the compiler is integrated nowadays, so you cannot really run cc1 without the preprocessor. But you can generate an assembly file with gcc -S main.c and this will produce main.s. You can assemble that to an object file with gcc -c main.s which will produce main.o and then you can link it with gcc main.o to produce your final a.out

https://renenyffenegger.ch/notes/development/languages/C-C-plus-plus/GCC/cc1/index (Emphasis mine)

cc1 is also referred to as the compiler proper.

cc1 preprocesses a c translation unit and compiles it into assembly code. The assembly code is converted into an object file with the assembler.

Earlier versions of cc1 used /usr/bin/cpp for the preprocessing stage.

https://renenyffenegger.ch/notes/Linux/fhs/usr/bin/cpp (Emphasis mine)

The preprocessor.

cpp is not bo be confused with c++.

The preprocessor is concerned with things like

  • macro expansion
  • removing comments
  • trigraph conversion
  • escaped newline splicing
  • processing of directives

Newer version of gcc don't invoke /usr/bin/cpp directly for preprocessing a translation unit. Rather, the preprocessing is performed by the compiler proper cc1.

I would almost consider this as a dup of this, but it's impossible to create cross site dupes. Relationship between cc1 and gcc?

Related: 'Compiler proper' command for C program

and what does "1" means in cc1, why it is called cc1, not cc2, cc3 ...etc?

Don't know. My first guess was that they just added a 1 to cc which was and is the standard compiler on Unix (excluding Linux) systems. On most Linux system, cc is just a link to gcc. But another good guess is that it stands for the first phase in compilation. Have not found a good source though.

Answer from klutt on Stack Overflow
๐ŸŒ
Arm Learning
learn.arm.com โ€บ install-guides โ€บ gcc
GNU Compiler | Arm Learning Paths
There are multiple flavors of GCC, the GNU Compiler Collection , for the Arm architecture, and for different use cases.
๐ŸŒ
GNU
gcc.gnu.org โ€บ onlinedocs โ€บ gcc
Top (Using the GNU Compiler Collection (GCC))
This manual documents how to use the GNU compilers, as well as their features and incompatibilities, and how to report bugs. It corresponds to the compilers (GCC) version 16.0.1. The internals of the GNU compilers, including how to port them to new targets and some information about how to ...
Discussions

c - Is GCC a compiler or is it a collection of tools for the compilation process? - Stack Overflow
I'm new to GNU and GCC, sorry if my question sounds dumb. We know that GCC stands for GNU Compiler Collection, so I think gcc is just a compiler (from a compiler collection). But I also read that g... More on stackoverflow.com
๐ŸŒ stackoverflow.com
GCC, the GNU Compiler Collection 15.1 released
The new default is -std=gnu23, which means C23's breaking changes are now the default. In my experience so far the most disruptive has been old-style prototypes, particularly empty parameter lists. This: void f(); Now means: void f(void); Instead of "unspecified number of arguments." Projects depending on the old behavior include GDB, GMP, GNU Make, and Vim. These require special consideration when building with GCC 15. More on reddit.com
๐ŸŒ r/C_Programming
51
60
April 25, 2025
Why is installation so complicated?
Those are really the build instructions, and yes, building gcc is painful. If you were on Linux I'd just say install the gcc package and be done, but on Windows I don't know. Let's ask Google ... Um, actually, it looks like a bit of a joke (I just searched for "install gcc on windows"), I wouldn't fancy it either. However, if you do want to run gcc on Windows, have a look at MinGW . Or else, bite the bullet and put Linux on a VM and discover how to do software development! (I may be biased here.) More on reddit.com
๐ŸŒ r/gcc
10
11
April 4, 2017
GNU GCC is still the best C compiler!
GCC for the win! More on reddit.com
๐ŸŒ r/linuxmasterrace
13
92
February 24, 2021
๐ŸŒ
Quora
quora.com โ€บ Is-the-GCC-GNU-compiler-open-source
Is the GCC GNU compiler open source? - Quora
Answer (1 of 4): GCC is not open source, it is free software distributed under a GPL (GNU General Public License). See Is there a difference between free software and open source software? See What is free software?
๐ŸŒ
SageMath
doc.sagemath.org โ€บ html โ€บ en โ€บ reference โ€บ spkg โ€บ gcc.html
gcc: The GNU Compiler Collection or other suitable C and C++ compilers - Packages and Features
This package represents the required C and C++ compilers. GCC (GNU Compiler Collection) versions 8.x (>= 8.4.0) to 13.x are supported.
Top answer
1 of 1
2

In most cases you (a little inaccurately) call gcc the compiler. A reason is that you can run the whole tool chain, at least for simple projects, with a single gcc command. Let's say you have this main.c

// main.c
#include <stdio.h>
int main(void)
{
    printf("Hello, world!\n");
}

and compile it with

gcc main.c

Then everything you mentioned, cpp, cc1, as and ld will be involved in creating the executable a.out. Well, almost. cpp is old and newer versions of the compiler has the preprocessor integrated.

If you want to see the output of the preprocessor, use gcc -E main.c

As I mentioned, the preprocessor and the compiler is integrated nowadays, so you cannot really run cc1 without the preprocessor. But you can generate an assembly file with gcc -S main.c and this will produce main.s. You can assemble that to an object file with gcc -c main.s which will produce main.o and then you can link it with gcc main.o to produce your final a.out

https://renenyffenegger.ch/notes/development/languages/C-C-plus-plus/GCC/cc1/index (Emphasis mine)

cc1 is also referred to as the compiler proper.

cc1 preprocesses a c translation unit and compiles it into assembly code. The assembly code is converted into an object file with the assembler.

Earlier versions of cc1 used /usr/bin/cpp for the preprocessing stage.

https://renenyffenegger.ch/notes/Linux/fhs/usr/bin/cpp (Emphasis mine)

The preprocessor.

cpp is not bo be confused with c++.

The preprocessor is concerned with things like

  • macro expansion
  • removing comments
  • trigraph conversion
  • escaped newline splicing
  • processing of directives

Newer version of gcc don't invoke /usr/bin/cpp directly for preprocessing a translation unit. Rather, the preprocessing is performed by the compiler proper cc1.

I would almost consider this as a dup of this, but it's impossible to create cross site dupes. Relationship between cc1 and gcc?

Related: 'Compiler proper' command for C program

and what does "1" means in cc1, why it is called cc1, not cc2, cc3 ...etc?

Don't know. My first guess was that they just added a 1 to cc which was and is the standard compiler on Unix (excluding Linux) systems. On most Linux system, cc is just a link to gcc. But another good guess is that it stands for the first phase in compilation. Have not found a good source though.

๐ŸŒ
Compiler Explorer
godbolt.org
Compiler Explorer
To add a library, search for one you want and select the version in the dropdown. Or if you have favorited it before, just click the library name in the Favorites section. Libraries are installed using the conan.io package manager. Please note that Windows-based compilers currently do not support libraries.
Find elsewhere
๐ŸŒ
Wikipedia
en.wikipedia.org โ€บ wiki โ€บ GNU_Compiler_for_Java
GNU Compiler for Java - Wikipedia
August 6, 2025 - The GNU Compiler for Java (GCJ) is a discontinued free compiler for the Java programming language. It was part of the GNU Compiler Collection. GCJ compiles Java source code to Java virtual machine (JVM) bytecode or to machine code for a number ...
๐ŸŒ
GNU
gcc.gnu.org
GCC, the GNU Compiler Collection - GNU Project
The GNU Compiler Collection includes front ends for C, C++, Objective-C, Objective-C++, Fortran, Ada, Go, D, Modula-2, COBOL, Rust, and Algol 68 as well as libraries for these languages (libstdc++,...). GCC was originally written as the compiler for the GNU operating system.
๐ŸŒ
GNU
gnu.org โ€บ software โ€บ gcc
GCC, the GNU Compiler Collection - GNU Project
The GNU Compiler Collection includes front ends for C, C++, Objective-C, Fortran, Ada, Go, D, Modula-2, and COBOL as well as libraries for these languages (libstdc++,...). GCC was originally written as the compiler for the GNU operating system. The GNU system was developed to be 100% free software, ...
๐ŸŒ
Wikipedia
en.wikipedia.org โ€บ wiki โ€บ GNU_Compiler_Collection
GNU Compiler Collection - Wikipedia
3 weeks ago - The GNU Compiler Collection (GCC) (formerly GNU C Compiler) is a collection of compilers from the GNU Project that support various programming languages, hardware architectures, and operating systems.
๐ŸŒ
SourceForge
sourceforge.net โ€บ projects โ€บ gcc-win64
gcc-win64 download | SourceForge.net
Download gcc-win64 for free. x64 build of GCC for Windows. x64 C/C++ compiler for Windows using (unofficial build): - gmp - mpfr - mpc - isl - cloog - mingw-w64 - gcc - seh You need at least core2 command set support to run this application. Note that every version with bundled gdb needs at ...
๐ŸŒ
Kiddle
kids.kiddle.co โ€บ GNU_Compiler_Collection
GNU Compiler Collection facts for kids
March 22, 1987 - The GNU Compiler Collection, usually called GCC, is a powerful set of tools created by the GNU Project. Think of it as a master translator for computers. Programmers write instructions in languages like C++ or Rust, but computers only understand ...
๐ŸŒ
Ucartz Online Pvt Ltd
ucartz.com โ€บ clients โ€บ knowledgebase โ€บ 2370 โ€บ What-Is-GNU-Compiler-Collection-Or-GCC.html
What Is GNU Compiler Collection Or GCC? - Ucartz
The GCC or GNU Compiler Collection is a compiler and related auxiliary tools which are used to collect different programming languages into binary and related formats. GCC has been built and is currently provided by the GNU Project. GCC is very popular in the open-source community and used ...
๐ŸŒ
Reddit
reddit.com โ€บ r/c_programming โ€บ gcc, the gnu compiler collection 15.1 released
r/C_Programming on Reddit: GCC, the GNU Compiler Collection 15.1 released
April 25, 2025 -

https://gcc.gnu.org/gcc-15/

Some discussion on hackernews: https://news.ycombinator.com/item?id=43792248

Awhile back, there was some discussion of code like this:

char a[3] = "123";

which results in a an array of 3 chars with no terminating NUL byte, and no warning from the compiler about this (was not able to find that discussion or I would have linked it). This new version of gcc does have a warning for that. https://gcc.gnu.org/pipermail/gcc-patches/2024-June/656014.html And that warning and attempts to fix code triggering it have caused a little bit of drama on the linux kernel mailing list: https://news.ycombinator.com/item?id=43790855

๐ŸŒ
Incredibuild
incredibuild.com โ€บ home โ€บ integrations โ€บ gcc
What is GNU Compiler Collection (GCC) | Incredibuild
September 17, 2024 - The GNU Compiler Collection, commonly known as GCC, is a set of compilers and development tools available for Linux, Windows, various BSDs, and a wide assortment of other operating systems.
๐ŸŒ
Visual Studio Code
code.visualstudio.com โ€บ docs โ€บ cpp โ€บ config-mingw
Using GCC with MinGW
November 3, 2021 - Get the latest version of MinGW-w64 via MSYS2, which provides up-to-date native builds of GCC, MinGW-w64, and other helpful C++ tools and libraries. This will provide you with the necessary tools to compile your code, debug it, and configure ...
๐ŸŒ
Lumi-supercomputer
docs.lumi-supercomputer.eu โ€บ development โ€บ compiling โ€บ gnu
GNU compilers - Documentation
The GNU Compiler Collection (GCC) includes front ends for the C (gcc), C++ (g++), and Fortran (gfortran) programming languages.
๐ŸŒ
OnlineGDB
onlinegdb.com โ€บ online_c_compiler
Online C Compiler - online editor
/****************************************************************************** Online C Compiler. Code, Compile, Run and Debug C program online. Write your code in this editor and press "Run" button to compile and execute it.
๐ŸŒ
Ohio Supercomputer Center
osc.edu โ€บ resources โ€บ available_software โ€บ software_list โ€บ gnu_compilers
GNU Compilers | Ohio Supercomputer Center
July 29, 2025 - Fortran, C and C++ compilers produced by the GNU Project. Availability and Restrictions Versions The GNU Compiler Collection (GCC) are available on all our clusters. These are the versions currently available: Version Pitzer Ascend Cardinal Notes 11.4.1 X# X# X# 12.3.0 X X X* 13.2.0 X X X * ...