出現的警告內容:
Warning[25] : Label 'xxxxx' is defined pubweak in a section implicitly declared root
把SECTION .text:CODE:REORDER(1)
改成SECTION .text:CODE:REORDER:NOROOT(1)
或
SECTION .text:CODE:REORDER:ROOT(1)
NOROOT和 ROOT 的區別,NOROOT表示如果符號沒有被關聯的時候是被優化掉的,如果想不被優化則使用ROOT.
官網解決方法:SECTION .text:CODE:REORDER:NOROOT(1),文件鏈接
https://www.iar.com/support/tech-notes/assembler/warning25-label-xxxxx-is-defined-pubweak-in-a-section-implicitly-declared-root/