请问汇编代码如何分配在指定的段或位置,类似C语言使用 #pragma CODE_SECTION()
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.
可以汇编代码中用.sect "section_name:subsection_name"定义,请看下面汇编手册中2.4.6 Subsections的例程。
https://www.ti.com/lit/ug/sprui03b/sprui03b.pdf
.sect ".text:_func"
然后在cmd文件中分配到固定的地址。
如
SECTIONS
{
.text:_func > 0x11800000
}