kconfig: llvm: Set default opt level to -Oz when building with LLVM
Experimentally, -Oz seems to give size results closer to GCC's -Os (though GCC does now support -Oz as well). Set -Oz as the default for LLVM to give the better codesize. Signed-off-by: Jonathon Penix <jpenix@quicinc.com>
This commit is contained in:
parent
d6041d62b3
commit
eaa903d852
1 changed files with 1 additions and 0 deletions
|
@ -478,6 +478,7 @@ choice COMPILER_OPTIMIZATIONS
|
||||||
prompt "Optimization level"
|
prompt "Optimization level"
|
||||||
default NO_OPTIMIZATIONS if COVERAGE
|
default NO_OPTIMIZATIONS if COVERAGE
|
||||||
default DEBUG_OPTIMIZATIONS if DEBUG
|
default DEBUG_OPTIMIZATIONS if DEBUG
|
||||||
|
default SIZE_OPTIMIZATIONS_AGGRESSIVE if "$(ZEPHYR_TOOLCHAIN_VARIANT)" = "llvm"
|
||||||
default SIZE_OPTIMIZATIONS
|
default SIZE_OPTIMIZATIONS
|
||||||
help
|
help
|
||||||
Note that these flags shall only control the compiler
|
Note that these flags shall only control the compiler
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue