From aa9d306ecfc597567b1db7e591e8a22f4d07f458 Mon Sep 17 00:00:00 2001 From: Kazuki Hashimoto Date: Mon, 14 Feb 2022 07:05:28 +0900 Subject: [PATCH] Makefile: Apply tuning flags from lazerl0rd Signed-off-by: Kazuki Hashimoto --- Makefile | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Makefile b/Makefile index 9140114be20b..eb5973b86161 100644 --- a/Makefile +++ b/Makefile @@ -766,6 +766,11 @@ else ifdef CONFIG_CC_OPTIMIZE_FOR_SIZE KBUILD_CFLAGS += -Os endif +ifdef CONFIG_CC_IS_CLANG +KBUILD_CFLAGS += -mllvm -inline-threshold=600 +KBUILD_CFLAGS += -mllvm -inlinehint-threshold=750 +endif + # Tell gcc to never replace conditional load with a non-conditional one KBUILD_CFLAGS += $(call cc-option,--param=allow-store-data-races=0) KBUILD_CFLAGS += $(call cc-option,-fno-allow-store-data-races)