boards/sim: Change -fprofile-arcs to -fprofile-generate

to generate more information for profile feedback optimization
and remove -lgcov from STDLIBS since gcc/clang will automatically
add the profile help lirary(triggered by -fprofile-generate).

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
Xiang Xiao 2022-05-04 02:38:54 +08:00 committed by Alan Carvalho de Assis
parent 3983efa47e
commit eba185b04b
2 changed files with 1 additions and 5 deletions

View File

@ -103,10 +103,6 @@ ifeq ($(CONFIG_STACK_COLORATION),y)
CSRCS += up_checkstack.c CSRCS += up_checkstack.c
endif endif
ifeq ($(CONFIG_ARCH_COVERAGE),y)
STDLIBS += -lgcov
endif
ifeq ($(CONFIG_SPINLOCK),y) ifeq ($(CONFIG_SPINLOCK),y)
HOSTSRCS += up_testset.c HOSTSRCS += up_testset.c
endif endif

View File

@ -68,7 +68,7 @@ ifeq ($(CONFIG_STACK_CANARIES),y)
endif endif
ifeq ($(CONFIG_ARCH_COVERAGE),y) ifeq ($(CONFIG_ARCH_COVERAGE),y)
ARCHOPTIMIZATION += -fprofile-arcs -ftest-coverage ARCHOPTIMIZATION += -fprofile-generate -ftest-coverage
endif endif
# Add -fno-common because macOS "ld -r" doesn't seem to pick objects # Add -fno-common because macOS "ld -r" doesn't seem to pick objects