cc and gcc

To make clear about these 2 compilers:

1- cc is QSSL’s compiler around 30k
2- gcc is GNU compiler. around 60k

3-qcc is the same thing as cc.

Correct ?

Stefan Parvu <sparvu@cc.hut.fi> wrote:

To make clear about these 2 compilers:

1- cc is QSSL’s compiler around 30k
2- gcc is GNU compiler. around 60k

3-qcc is the same thing as cc.

Correct ?

Nope. Both gcc, cc, and qcc are wrappers for the gnu compiler collection. :slight_smile:
In the end, they all call the compiler and linker.

chris

\

cdm@qnx.com > “The faster I go, the behinder I get.”

Chris McKillop – Lewis Carroll –
Software Engineer, QSSL
<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<

Ok. But why do you provide cc and gcc and qcc. Isn’t a bit confusing ?

cc is a binary, which from UNIX point of view you think it is a
proprietary compiler.
Why cc is around 30k and gcc is 60k around when they all are almost the
same ? I don’t get it.

stefan

Chris McKillop wrote:

Stefan Parvu <> sparvu@cc.hut.fi> > wrote:
To make clear about these 2 compilers:

1- cc is QSSL’s compiler around 30k
2- gcc is GNU compiler. around 60k

3-qcc is the same thing as cc.

Correct ?

Nope. Both gcc, cc, and qcc are wrappers for the gnu compiler collection. > :slight_smile:
In the end, they all call the compiler and linker.

chris

cdm@qnx.com > “The faster I go, the behinder I get.”
Chris McKillop – Lewis Carroll –
Software Engineer, QSSL

Stefan Parvu <sparvu@cc.hut.fi> wrote:

Ok. But why do you provide cc and gcc and qcc. Isn’t a bit confusing ?

cc is a binary, which from UNIX point of view you think it is a
proprietary compiler.
Why cc is around 30k and gcc is 60k around when they all are almost the
same ? I don’t get it.

Both qcc and gcc are compiler drivers. They process the options,
do some inference based on filename extensions, and then invoke the
compiler backend programs. These are the same for both gcc and qcc.

cpp - C pre processor
cc1 - C compiler
cc1plus - C++ compiler
as - assembler
ld - linker

You can see how these are executed by passing the -v option
to qcc and gcc.

The reason for qcc is a long story. Originally it was because
we wanted to support multiple compiler backends behind the one
compiler driver.

You can use either - for porting projects I generally use gcc.
For original projects I usually use qcc, since it is more convenient
in some respects.

Also, qcc does the old QNX4 trick of dropping the priority of the
backend down one level from the driver. This has the effect of
not freezing the machine up when you are compiling.


cburgess@qnx.com