以下是在Debian上优化GCC性能的方法:
-O2
-O3
-march=native
-flto
make -j$(nproc)
ccache
sccache
gprof
perf
根据项目需求选择合适方案,优先测试验证优化效果。