Young Hyun Yoo Young Hyun Yoo - 1 year ago 79
Linux Question

What is the definition of target in cross-compiling

I know that "target" is the machine which the binary will be on.

But because the arm has so many chip, there is a -march option in gcc.

Today, there is Aarch64 and Aarch64 tool chain. Gcc did not made a new option like -march=Aarch64

As I found this thread (, I got more confused.

What is the target definition and why did gcc did not make likfe arm-none-linux-eabi -march=Aarch64 but made Aarch64-none-linux-eabi?

Answer Source

The A64 instruction set used when a core is in AArch64 state is not an extension to the existing A32/T32 instruction sets, but a completely new instruction set. So while technically it may have been possible to stuff both AArch32 and AArch64 instruction sets into the same gcc compiler binary, this was not considered worthwhile by the gcc developers.

Possibly also see this answer for further details.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download