From 606ad9272bbc0e10b4c5f0fa1fdb27b80d373fd3 Mon Sep 17 00:00:00 2001 From: guo Date: Thu, 18 May 2023 21:54:17 +0800 Subject: [PATCH] [tools] llvm-arm reduce code size. --- bsp/stm32/stm32l475-atk-pandora/rtconfig.py | 1 + 1 file changed, 1 insertion(+) diff --git a/bsp/stm32/stm32l475-atk-pandora/rtconfig.py b/bsp/stm32/stm32l475-atk-pandora/rtconfig.py index 6b54a18e1..7b2ac5813 100644 --- a/bsp/stm32/stm32l475-atk-pandora/rtconfig.py +++ b/bsp/stm32/stm32l475-atk-pandora/rtconfig.py @@ -192,6 +192,7 @@ elif PLATFORM == 'llvm-arm': OBJDUMP = PREFIX + 'objdump' OBJCPY = PREFIX + 'objcopy' DEVICE = ' --config armv7em_hard_fpv4_sp_d16.cfg' + DEVICE += ' -ffunction-sections -fdata-sections' CFLAGS = DEVICE CFLAGS += ' -mfloat-abi=hard -march=armv7em -mfpu=fpv4-sp-d16' AFLAGS = ' -c' + DEVICE + ' -Wa,-mimplicit-it=thumb ' ## -x assembler-with-cpp -- GitLab