Use -mcpu=cortex-a15 for gcc arch dependent compilation.

If TARGET_CPU_VARIANT=cortex-a15 is specified in the BoardConfig.mk file.

Bug: 7961327
Change-Id: Ic459df378293237c54263f5315ac3be62dad4273
This commit is contained in:
Ben Cheng 2013-01-14 13:45:45 -08:00
parent fc1c1a217b
commit 533aa2707e
2 changed files with 10 additions and 5 deletions

View File

@ -13,11 +13,13 @@ ARCH_ARM_HAVE_VFP := true
ARCH_ARM_HAVE_VFP_D32 := true
ARCH_ARM_HAVE_NEON := true
# Note: Hard coding the 'tune' value here is probably not ideal,
# and a better solution should be found in the future.
#
arch_variant_cflags := \
-march=armv7-a \
ifeq ($(strip $(TARGET_CPU_VARIANT)), cortex-a15)
arch_variant_cflags := -mcpu=cortex-a15
else
arch_variant_cflags := -march=armv7-a
endif
arch_variant_cflags += \
-mfloat-abi=softfp \
-mfpu=neon

View File

@ -97,6 +97,9 @@ $(call clang-flags-subst,-march=armv5e,-march=armv5)
$(call clang-flags-subst,-Wno-psabi,)
$(call clang-flags-subst,-Wno-unused-but-set-variable,)
# clang does not support -mcpu=cortex-a15 yet - fall back to armv7-a for now
$(call clang-flags-subst,-mcpu=cortex-a15,-march=armv7-a)
ADDRESS_SANITIZER_CONFIG_EXTRA_CFLAGS := -faddress-sanitizer
ADDRESS_SANITIZER_CONFIG_EXTRA_LDFLAGS := -Wl,-u,__asan_preinit
ADDRESS_SANITIZER_CONFIG_EXTRA_SHARED_LIBRARIES := libdl libasan_preload