|
|||||||||||
| 技術交流 | 電路欣賞 | 工控天地 | 數(shù)字廣電 | 通信技術 | 電源技術 | 測控之家 | EMC技術 | ARM技術 | EDA技術 | PCB技術 | 嵌入式系統(tǒng) 驅(qū)動編程 | 集成電路 | 器件替換 | 模擬技術 | 新手園地 | 單 片 機 | DSP技術 | MCU技術 | IC 設計 | IC 產(chǎn)業(yè) | CAN-bus/DeviceNe |
請教一個ARM的語句問題。 |
| 作者:xjc 欄目:ARM技術 |
請教一個ARM的語句問題。 在杜春雷的《ARM體系結(jié)構與編程》書中的219頁中有這樣的一段程序。 ........ ;延時 ldr r4 , =0xff 01 subs r4 , r4 , #0x01 bne %b01 我的疑問是:bne %b01這段匯編是怎么一個機構? %b在這里是什么意思呢 ? |
| 2樓: | >>參與討論 |
| 作者: pigjiang 于 2007/1/8 9:36:00 發(fā)布:
這個 在李光駒的書上有 bne %b01 說得是"不等的話,跳轉(zhuǎn)到以前的最近的一個叫01的標號處" 如果表示往后的第一個標號好像是用&f01吧,忘了. |
|
| 3樓: | >>參與討論 |
| 作者: xjc 于 2007/1/8 10:08:00 發(fā)布:
請問哪里有講這個語法的? 謝謝回答了。 請問哪里有講這個語法的? 杜春雷的《ARM體系結(jié)構與編程》好象沒有啊 。 |
|
| 4樓: | >>參與討論 |
| 作者: pigjiang 于 2007/1/8 10:18:00 發(fā)布:
李光駒有本寫4510的書 網(wǎng)上有下載的. |
|
| 5樓: | >>參與討論 |
| 作者: pigjiang 于 2007/1/8 10:20:00 發(fā)布:
不一定要保定哪本書嘛,到google上一搜就有了. |
|
| 6樓: | >>參與討論 |
| 作者: John_light 于 2007/1/8 15:47:00 發(fā)布:
摘抄如下,不要問我從哪里來 Local LABELS A local label is a NUMBER in the range 0-99, optionally followed by a NAME. The same NUMBER can be used for more than one local label in an ELF section. Local LABELS are typically used for loops and conditional code within a routine, or for small subroutines that are ONLY used locally. They are particularly useful in macros. You can use the same NUMBER for more than one local label even within the same scope. By default, the assembler links a local label reference to: . the most recent local label of the same NUMBER, if there is one within the scope . the next following local label of the same NUMBER, if there is not a preceding one within the scope. Use the optional parameters to modify this search pattern if required. Syntax The syntax of a local label is: n{routNAME} The syntax of a reference to a local label is: %{F|B}{A|T}n{routNAME} where: n is the NUMBER of the local label. routNAME is the NAME of the current scope. % introduces the reference. F instructs the assembler to search forwards ONLY. B instructs the assembler to search backwards ONLY. A instructs the assembler to search all macro levels. T instructs the assembler to look at this macro level ONLY. If neither F or B is specified, the assembler searches backwards first, then forwards. If neither A or T is specified, the assembler searches all macros from the current level to the top level, but does not search lower level macros. 從你給出的代碼: ldr r4 , =0xff 01 subs r4 , r4 , #0x01 bne %b01 %b01的意思恐怕是向backwark搜索標號01 * - 本貼最后修改時間:2007-1-8 20:09:31 修改者:John_light |
|
| 7樓: | >>參與討論 |
| 作者: John_light 于 2007/1/8 15:50:00 發(fā)布:
暈,排了老半天還是很難看 |
|
| 8樓: | >>參與討論 |
| 作者: XJC 于 2007/1/8 17:17:00 發(fā)布:
謝謝各位了。! |
|
|
|
| 免費注冊為維庫電子開發(fā)網(wǎng)會員,參與電子工程師社區(qū)討論,點此進入 |
Copyright © 1998-2006 m.58mhw.cn 浙ICP證030469號 |