This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[参考译文] TMS320F28375S:在哪里应该使用内存对齐

Guru**** 2378650 points
请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/microcontrollers/c2000-microcontrollers-group/c2000/f/c2000-microcontrollers-forum/1472049/tms320f28375s-where-should-memory-align-be-used

器件型号:TMS320F28375S

工具与软件:

你好

我有一个从 RAM 运行的应用程序。 链接器文件中有四种不同类型的链接段:

1)主存储器段(.cinit / .const /.econst /.pinit  /.switch /.text /.TI.ramfunc ) 被链接到从闪存加载和从 RAM 运行(它们将在使用汇编指令进入 main ()之前从闪存复制到 RAM。) 例如:

  .text      : 负载=闪存,  页面= 0    
             RUN = RAMGS7_11、 PAGE = 0   
             load_start (_text_loadstart)
             RUN_START (_TEXT_RUNSTART)
             大小(_TEXT_SIZE)



 2) 2)中的汇编指令(codestart/wddisable  / copySECTIONS /initram )只被链接到闪存。 例如:

codestart   :> beging,   page = 0  
wddisable   :> flash_0、   page = 0

3) 3)我有另一个部分用于在闪存中写入校验和及版本。 这个还链接到闪存

4) 4)一些仅链接到 RAM 的其他扇区。

我的问题是:对于前三种类型(以某种方式链接到闪存)中的哪一种类型、我应该使用 Align (8)? 原因是什么? 即使是1类器件? 请具体说明。


此致
Saeed