1
0
Fork 0

kbuild: gcov: enable -fno-tree-loop-im if supported

Clang does not recognize this compiler option.

Reported-by: Prasad Sodagudi <psodagud@codeaurora.org>
Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
hifive-unleashed-5.1
Nick Desaulniers 2018-04-26 14:28:07 -07:00 committed by Masahiro Yamada
parent 75bc37fefc
commit c64ba044ed
1 changed files with 3 additions and 1 deletions

View File

@ -623,7 +623,9 @@ all: vmlinux
KBUILD_CFLAGS += $(call cc-option,-fno-PIE)
KBUILD_AFLAGS += $(call cc-option,-fno-PIE)
CFLAGS_GCOV := -fprofile-arcs -ftest-coverage -fno-tree-loop-im $(call cc-disable-warning,maybe-uninitialized,)
CFLAGS_GCOV := -fprofile-arcs -ftest-coverage \
$(call cc-option,-fno-tree-loop-im) \
$(call cc-disable-warning,maybe-uninitialized,)
export CFLAGS_GCOV CFLAGS_KCOV
# The arch Makefile can set ARCH_{CPP,A,C}FLAGS to override the default