How to set the linking parameter to put data in a special section [message #1871883] |
Tue, 15 October 2024 02:24  |
Eclipse User |
|
|
|
Hi,
My eclipse version is Version: 2023-09 (4.29.0) and Build id: 20230907-1323.
I define a section in link file and try to put some data in it, But i can't find it in Map file and get an unreasonable result. The address of the data is weird.
The same code and link file work well in another Makefile build system , so i think the problem is in the GCC linking or building parameter.
I really appreciate it if someone can give me a hand.
Code:
uint8_t g_azifft_buf[3][DDMA_STAGEB_AZIFFT_BUF_SIZE] __attribute__((aligned(16), section(".L3DATA")));
Linker file:
.L3DATA (NOLOAD):
{
*(.L3DATA)
} > L3DATA
Map file:
I can't find it in map file:
Build log(I remove some redundant info, like *.o and -I*):
Building file: D:/ARCO/B2/b2_sdk/component/ARCO/datapath/ddmastageB/test/ddma_stageB_test.c
Invoking: GNU Arm Cross C Compiler
arm-none-eabi-gcc -mcpu=cortex-a7 -marm -mlittle-endian -mfloat-abi=hard -mfpu=neon-fp16 -mno-unaligned-access -O3 -ffunction-sections -fdata-sections -fno-common -ffreestanding -flto -fno-strict-aliasing -Wall -g3 -DARCO_ASS_CHIP -DCONFIG_CORTEX_A -I"D:\ARCO\B2\b2_sdk\component\CMSIS\Core_A\incl" -std=gnu11 -MMD -MP -MF"component/ARCO/datapath/ddmastageB/test/ddma_stageB_test.d" -MT"component/ARCO/datapath/ddmastageB/test/ddma_stageB_test.o" -c -o "component/ARCO/datapath/ddmastageB/test/ddma_stageB_test.o" "D:/ARCO/B2/b2_sdk/component/ARCO/datapath/ddmastageB/test/ddma_stageB_test.c"
Finished building: D:/ARCO/B2/b2_sdk/component/ARCO/datapath/ddmastageB/test/ddma_stageB_test.c
Building target: ass_firmware.elf
Invoking: GNU Arm Cross C Linker
arm-none-eabi-gcc -mcpu=cortex-a7 -marm -mlittle-endian -mfloat-abi=hard -mfpu=neon-fp16 -mno-unaligned-access -O3 -ffunction-sections -fdata-sections -fno-common -ffreestanding -flto -fno-strict-aliasing -Wall -g3 -T "D:\ARCO\B2\b2_sdk\project\ASS_DEMO\link.lds" -nostartfiles -Wl,-Map,"ass_firmware.map" --specs=nano.specs -u _printf_float --specs=nosys.specs -Wl,--wrap,_malloc_r -Wl,--wrap,_calloc_r -Wl,--wrap,_free_r -fno-strict-aliasing -o "ass_firmware.elf" ./user/src/ass_radar_demo.o -lm
Finished building target: ass_firmware.elf
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.08769 seconds