From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: Rui Salvaterra Date: Fri, 19 Jun 2020 10:45:25 +0100 Subject: [PATCH 6/8] ARM Cortex-A9: build the userspace with Thumb-2 instructions Thumb-2 code is denser than pure ARM, reducing RAM usage and improving performance due to better instruction cache footprint. There's no reason for not enabling this feature on other ARMv7 targets (cortex-a7 and cortex-a8), but I don't have the hardware to test it. Signed-off-by: Rui Salvaterra Tested-by: Tad --- include/target.mk | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/target.mk b/include/target.mk index d5807ba01a..9e988f3a96 100644 --- a/include/target.mk +++ b/include/target.mk @@ -278,6 +278,11 @@ ifeq ($(DUMP),1) CPU_TYPE = sparc CPU_CFLAGS_ultrasparc = -mcpu=ultrasparc endif + ifeq ($(ARCH),arm) + CPU_CFLAGS_cortex-a7 = -mthumb + CPU_CFLAGS_cortex-a8 = -mthumb + CPU_CFLAGS_cortex-a9 = -mthumb + endif ifeq ($(ARCH),aarch64) CPU_TYPE ?= generic CPU_CFLAGS_generic = -mcpu=generic