23.10.2014 Views

RealView - ARM Information Center

RealView - ARM Information Center

RealView - ARM Information Center

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Thumb 指 令 参 考<br />

用 法<br />

LDR 伪 指 令 用 于 两 个 主 要 用 途 :<br />

• 当 一 个 直 接 值 因 为 超 出 MOV 指 令 的 范 围 而 不 能 被 移 动 到 寄 存 器 中 时 , 用 于<br />

生 成 文 本 常 数 。<br />

• 将 相 对 于 程 序 的 地 址 或 外 部 地 址 装 载 到 一 个 寄 存 器 中 。 不 管 链 接 程 序 将 包<br />

含 LDR 的 ELF 段 放 在 何 处 , 该 地 址 仍 保 持 有 效 。<br />

示 例<br />

LDR r1, =0xfff ; loads 0xfff into r1<br />

LDR<br />

r2, =labelname ; loads the address of labelname into r2<br />

<strong>ARM</strong> DUI 0204BSC © 2002、 2003 <strong>ARM</strong> Limited 版 权 所 有 。 保 留 所 有 权 利 。 5-49

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!