diff options
author | Tom Rini <trini@konsulko.com> | 2020-05-14 08:30:07 -0400 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2020-07-01 11:48:05 -0400 |
commit | 1f1a0f3db338cdcaad4f83153d1163aa18e08ed5 (patch) | |
tree | 889b3304886199357b0bbd3a881a827c98774974 /Kconfig | |
parent | 67f51b40cacc70da44779cef0edb845fa0f0505d (diff) | |
download | u-boot-1f1a0f3db338cdcaad4f83153d1163aa18e08ed5.zip u-boot-1f1a0f3db338cdcaad4f83153d1163aa18e08ed5.tar.gz u-boot-1f1a0f3db338cdcaad4f83153d1163aa18e08ed5.tar.bz2 |
compiler_types.h: Re-introduce CONFIG_OPTIMIZE_INLINING for U-Boot
In the Linux kernel, support for forcing inline functions to be made
inline, rather than allowing the compiler to make its own choice has
been removed. With respect to performance, modern GCC (and Clang) do a
good job at deciding when to, or not to, inline code and there are no
run-time requirements in Linux anymore.
There is one downside to this, which is final binary size. On average
in U-Boot removing this support grows SPL by almost 1 kilobyte. But
there are cases where it shrinks the binary by making better inline
choices than we had forced.
Start by re-introducing CONFIG_OPTIMIZE_INLINING as a global which
essentially reverts 889b3c1245de ("compiler: remove CONFIG_OPTIMIZE_INLINING entirely")
from Linux.
Cc: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'Kconfig')
-rw-r--r-- | Kconfig | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -64,6 +64,15 @@ config CC_OPTIMIZE_FOR_SIZE This option is enabled by default for U-Boot. +config OPTIMIZE_INLINING + bool "Allow compiler to uninline functions marked 'inline'" + default n + help + This option determines if U-Boot forces gcc to inline the functions + developers have marked 'inline'. Doing so takes away freedom from gcc to + do what it thinks is best, which is desirable in some cases for size + reasons. + config CC_COVERAGE bool "Enable code coverage analysis" depends on SANDBOX |