A given (particular) gcc
is built for a particular given target. Use gcc -v
to find out which.
Often, cross-compilers are installed as different commands, e.g. avr-gcc
on Debian for the Atmel AVR processor (with specific options ...)
On some architectures and systems (typically x86 & Linux) you may compile for a different variant. See this. In particular you may want to use -mtune=native
or -march=haswell
or -m32
...
If you build gcc
yourself from its source tarball, you'll give it at configure time specific configure options (e.g. --program-suffix=-avr
and --target=avr
for the avr-gcc
etc....)