-mcpu=cortex-a53 指定了CPU内核款型
-march=armv8-a+fp+simd+crc+crypto
armv8-a 架构
+simd Single Instruction Multiple Data,单指令多数据流,能够复制多个操作数,并把它们打包在大型寄存器的一组指令集。
以加法指令为例,单指令单数据(SISD)的CPU对加法指令译码后,执行部件先访问内存,取得第一个操作数;之后再一次访问内存,取得第二个操作数;随后才能进行求和运算。而在SIMD型的CPU中,指令译码后几个执行部件同时访问内存,一次性获得所有操作数进行运算。这个特点使SIMD特别适合于多媒体应用等数据密集型运算。
crypto
Enable Crypto extension. This implies Advanced SIMD is enabled.
使能加密扩展功能,这意味着高级SIMD功能启用
fp Enable floating-point instructions.
启用浮点运算指令
simd
Enable Advanced SIMD instructions. This implies floating-point
instructions are enabled. This is the default for all current
possible values for options -march and -mcpu=.
启用高级SIMD指令。这意味着浮点指示启用。这是所有当前的默认值选项对于-march和 –mcpu来说
-funroll-all-loops
Unroll all loops, even if their number of iterations is uncertain
when the loop is entered. This usually makes programs run more
slowly. -funroll-all-loops implies the same options as
-funroll-loops,
展开所有循环,即使在进入循环之前,迭代数量不确定。这种方式下通常会使程序变慢,-funroll-all-loops隐含选项-funroll-loops
--param
max-inline-insns-auto
When you use -finline-functions (included in -O3), a lot of
functions that would otherwise not be considered for inlining
by the compiler are investigated. To those functions, a
different (more restrictive) limit compared to functions
declared inline can be applied. The default value is 40.
指定-finline-functions选项(-O3中包含)下,修改自动内联函数的最大指令条数,默认情况下是40行。
case-values-threshold
The smallest number of different values for which it is best to
use a jump-table instead of a tree of conditional branches. If
the value is 0, use the default for the machine. The default
is 0.
用跳转表代替分支树的最小值,如果是0表明是默认使用机器默认值
-falign-functions
-falign-functions=n
Align the start of functions to the next power-of-two greater than
n, skipping up to n bytes. For instance, -falign-functions=32
aligns functions to the next 32-byte boundary, but
-falign-functions=24 aligns to the next 32-byte boundary only if
this can be done by skipping 23 bytes or less.
函数起始对齐,对齐数字节数为大于n的2的幂,跳过n个字节对齐。例如-falign-functions=32,对齐函数到下一个32 byte的边界,但是-falign-functions=24,则跳到下一个32byte对齐的边界。(因为24不是2的幂。)
-fno-align-functions and -falign-functions=1 are equivalent and
mean that functions are not aligned.
-fno-align-functions 和-falign-functions=1是相同的意思表示不启用函数对齐
Some assemblers only support this flag when n is a power of two;in
that case, it is rounded up.
对于汇编器来说只支持2的幂,这种情况下会自动修改到2的幂对应的值。
If n is not specified or is zero, use a machine-dependent default.
Enabled at levels -O2, -O3.
如果是n不特殊指定或指定0则使用机器默认值,默认在-O2 ,-O3开启
-ftracer
Perform tail duplication to enlarge superblock size. This
transformation simplifies the control flow of the functionallowing
other optimizations to do a better job.
ftrace大致理解即允许增加跟踪记录便于更好的优化程序。