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.

命 令 参 考<br />

7.7.20 ROUT<br />

ROUT 命 令 标 记 局 部 标 号 的 作 用 范 围 ( 请 参 阅 第 3-16 页 的 局 部 标 号 )。<br />

语 法<br />

{name} ROUT<br />

其 中 :<br />

name 是 要 分 配 给 作 用 范 围 的 名 称 。<br />

用 法<br />

使 用 ROUT 命 令 来 限 制 局 部 标 号 的 作 用 范 围 。 这 样 就 更 容 易 避 免 意 外 引 用 错 误 的<br />

标 号 。 如 果 其 中 没 有 ROUT 命 令 , 则 局 部 标 号 的 作 用 范 围 是 整 个 区 域 ( 请 参 阅 第<br />

7-54 页 的 AREA)。<br />

使 用 name 选 项 来 确 保 每 个 引 用 是 针 对 正 确 的 局 部 标 号 的 。 如 果 标 号 的 名 称 或 对<br />

标 号 的 引 用 与 前 面 的 ROUT 命 令 不 匹 配 , 则 汇 编 程 序 产 生 一 个 错 误 信 息 , 并 且 汇<br />

编 失 败 。<br />

示 例<br />

; code<br />

routineA ROUT ; ROUT is not necessarily a routine<br />

; code<br />

3routineA ; code ; this label is checked<br />

; code<br />

BEQ %4routineA ; this reference is checked<br />

; code<br />

BGE %3 ; refers to 3 above, but not checked<br />

; code<br />

4routineA ; code ; this label is checked<br />

; code<br />

otherstuff ROUT<br />

; start of next scope<br />

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

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

Saved successfully!

Ooh no, something went wrong!