Hi @kyf
attached is working example.
For more details about linker syntax, see please this document:
c:\NXP\S32DS.3.4\S32DS\build_tools\gcc_v10.2\gcc-10.2-arm32-eabi\arm-none-eabi\share\docs\pdf\ld.pdf
What is necessary to do:
Define section like this in the linker file. You can use .shareable_data as a template for itcm. "AT" directive is important.
lukaszadrapa_0-1674817906402.png
Second step - define the RAM and ROM addresses which will be used for copy-down:
lukaszadrapa_1-1674817983828.png
Next step - update the init_table. Add one more entry like this and increase the entries count:
lukaszadrapa_2-1674818061791.png
Then use the attribute for some function:
lukaszadrapa_3-1674818094736.png
And now it works:
lukaszadrapa_4-1674818126698.png
It will the same for interrupt vector table. By default, it's in normal RAM. Just remove it from the RAM and add it to the ITCM.
Hope this helps.
Regards,
Lukas