LLVM Clang Adds "-march=native" Support For The Apple M1

While "-march=native" is popular and widely used on x86/x86_64 processors for targeting the native/in-use processor's capabilities, the -march=native support on non-x86 CPUs has been spotty and not always supported for other architectures.
With this commit (it was reverted and then re-landed shortly afterwards last week) to LLVM Clang Git, -march=native now works (and correctly) for Apple M1 SoCs.
Asahi Linux on the Apple M1 Mac Mini.
So whether you are running Clang on macOS with an Apple M1 SoC or the likes of running Linux rather well on the Apple M1 hardware, you can now use "-march=native" if so desired for more optimized code generation.
1 Comment