亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? nasmdoc3.htm

?? nasm手冊 大家可以看看 對要寫匯編程序的幫助很大
?? HTM
?? 第 1 頁 / 共 3 頁
字號:
<h3><a name="section-3.6">3.6 <code><nobr>SEG</nobr></code> and <code><nobr>WRT</nobr></code></a></h3><p>When writing large 16-bit programs, which must be split into multiplesegments, it is often necessary to be able to refer to the segment part ofthe address of a symbol. NASM supports the <code><nobr>SEG</nobr></code>operator to perform this function.<p>The <code><nobr>SEG</nobr></code> operator returns the<em>preferred</em> segment base of a symbol, defined as the segment baserelative to which the offset of the symbol makes sense. So the code<p><pre>        mov     ax,seg symbol         mov     es,ax         mov     bx,symbol</pre><p>will load <code><nobr>ES:BX</nobr></code> with a valid pointer to thesymbol <code><nobr>symbol</nobr></code>.<p>Things can be more complex than this: since 16-bit segments and groupsmay overlap, you might occasionally want to refer to some symbol using adifferent segment base from the preferred one. NASM lets you do this, bythe use of the <code><nobr>WRT</nobr></code> (With Reference To) keyword.So you can do things like<p><pre>        mov     ax,weird_seg        ; weird_seg is a segment base         mov     es,ax         mov     bx,symbol wrt weird_seg</pre><p>to load <code><nobr>ES:BX</nobr></code> with a different, butfunctionally equivalent, pointer to the symbol<code><nobr>symbol</nobr></code>.<p>NASM supports far (inter-segment) calls and jumps by means of the syntax<code><nobr>call segment:offset</nobr></code>, where<code><nobr>segment</nobr></code> and <code><nobr>offset</nobr></code> bothrepresent immediate values. So to call a far procedure, you could codeeither of<p><pre>        call    (seg procedure):procedure         call    weird_seg:(procedure wrt weird_seg)</pre><p>(The parentheses are included for clarity, to show the intended parsingof the above instructions. They are not necessary in practice.)<p>NASM supports the syntax <code><nobr>call far procedure</nobr></code> asa synonym for the first of the above usages. <code><nobr>JMP</nobr></code>works identically to <code><nobr>CALL</nobr></code> in these examples.<p>To declare a far pointer to a data item in a data segment, you must code<p><pre>        dw      symbol, seg symbol</pre><p>NASM supports no convenient synonym for this, though you can alwaysinvent one using the macro processor.<h3><a name="section-3.7">3.7 <code><nobr>STRICT</nobr></code>: Inhibiting Optimization</a></h3><p>When assembling with the optimizer set to level 2 or higher (see<a href="nasmdoc2.html#section-2.1.16">section 2.1.16</a>), NASM will usesize specifiers (<code><nobr>BYTE</nobr></code>,<code><nobr>WORD</nobr></code>, <code><nobr>DWORD</nobr></code>,<code><nobr>QWORD</nobr></code>, or <code><nobr>TWORD</nobr></code>), butwill give them the smallest possible size. The keyword<code><nobr>STRICT</nobr></code> can be used to inhibit optimization andforce a particular operand to be emitted in the specified size. Forexample, with the optimizer on, and in <code><nobr>BITS 16</nobr></code>mode,<p><pre>        push dword 33</pre><p>is encoded in three bytes <code><nobr>66 6A 21</nobr></code>, whereas<p><pre>        push strict dword 33</pre><p>is encoded in six bytes, with a full dword immediate operand<code><nobr>66 68 21 00 00 00</nobr></code>.<p>With the optimizer off, the same code (six bytes) is generated whetherthe <code><nobr>STRICT</nobr></code> keyword was used or not.<h3><a name="section-3.8">3.8 Critical Expressions</a></h3><p>A limitation of NASM is that it is a two-pass assembler; unlike TASM andothers, it will always do exactly two assembly passes. Therefore it isunable to cope with source files that are complex enough to require threeor more passes.<p>The first pass is used to determine the size of all the assembled codeand data, so that the second pass, when generating all the code, knows allthe symbol addresses the code refers to. So one thing NASM can't handle iscode whose size depends on the value of a symbol declared after the code inquestion. For example,<p><pre>        times (label-$) db 0 label:  db      'Where am I?'</pre><p>The argument to <code><nobr>TIMES</nobr></code> in this case couldequally legally evaluate to anything at all; NASM will reject this examplebecause it cannot tell the size of the <code><nobr>TIMES</nobr></code> linewhen it first sees it. It will just as firmly reject the slightlyparadoxical code<p><pre>        times (label-$+1) db 0 label:  db      'NOW where am I?'</pre><p>in which <em>any</em> value for the <code><nobr>TIMES</nobr></code>argument is by definition wrong!<p>NASM rejects these examples by means of a concept called a <em>criticalexpression</em>, which is defined to be an expression whose value isrequired to be computable in the first pass, and which must thereforedepend only on symbols defined before it. The argument to the<code><nobr>TIMES</nobr></code> prefix is a critical expression; for thesame reason, the arguments to the <code><nobr>RESB</nobr></code> family ofpseudo-instructions are also critical expressions.<p>Critical expressions can crop up in other contexts as well: consider thefollowing code.<p><pre>                mov     ax,symbol1 symbol1         equ     symbol2 symbol2:</pre><p>On the first pass, NASM cannot determine the value of<code><nobr>symbol1</nobr></code>, because<code><nobr>symbol1</nobr></code> is defined to be equal to<code><nobr>symbol2</nobr></code> which NASM hasn't seen yet. On the secondpass, therefore, when it encounters the line<code><nobr>mov ax,symbol1</nobr></code>, it is unable to generate the codefor it because it still doesn't know the value of<code><nobr>symbol1</nobr></code>. On the next line, it would see the<code><nobr>EQU</nobr></code> again and be able to determine the value of<code><nobr>symbol1</nobr></code>, but by then it would be too late.<p>NASM avoids this problem by defining the right-hand side of an<code><nobr>EQU</nobr></code> statement to be a critical expression, so thedefinition of <code><nobr>symbol1</nobr></code> would be rejected in thefirst pass.<p>There is a related issue involving forward references: consider thiscode fragment.<p><pre>        mov     eax,[ebx+offset] offset  equ     10</pre><p>NASM, on pass one, must calculate the size of the instruction<code><nobr>mov eax,[ebx+offset]</nobr></code> without knowing the value of<code><nobr>offset</nobr></code>. It has no way of knowing that<code><nobr>offset</nobr></code> is small enough to fit into a one-byteoffset field and that it could therefore get away with generating a shorterform of the effective-address encoding; for all it knows, in pass one,<code><nobr>offset</nobr></code> could be a symbol in the code segment, andit might need the full four-byte form. So it is forced to compute the sizeof the instruction to accommodate a four-byte address part. In pass two,having made this decision, it is now forced to honour it and keep theinstruction large, so the code generated in this case is not as small as itcould have been. This problem can be solved by defining<code><nobr>offset</nobr></code> before using it, or by forcing byte sizein the effective address by coding<code><nobr>[byte ebx+offset]</nobr></code>.<p>Note that use of the <code><nobr>-On</nobr></code> switch (with n&gt;=2)makes some of the above no longer true (see<a href="nasmdoc2.html#section-2.1.16">section 2.1.16</a>).<h3><a name="section-3.9">3.9 Local Labels</a></h3><p>NASM gives special treatment to symbols beginning with a period. A labelbeginning with a single period is treated as a <em>local</em> label, whichmeans that it is associated with the previous non-local label. So, forexample:<p><pre>label1  ; some code .loop         ; some more code         jne     .loop         ret label2  ; some code .loop         ; some more code         jne     .loop         ret</pre><p>In the above code fragment, each <code><nobr>JNE</nobr></code>instruction jumps to the line immediately before it, because the twodefinitions of <code><nobr>.loop</nobr></code> are kept separate by virtueof each being associated with the previous non-local label.<p>This form of local label handling is borrowed from the old Amigaassembler DevPac; however, NASM goes one step further, in allowing accessto local labels from other parts of the code. This is achieved by means of<em>defining</em> a local label in terms of the previous non-local label:the first definition of <code><nobr>.loop</nobr></code> above is reallydefining a symbol called <code><nobr>label1.loop</nobr></code>, and thesecond defines a symbol called <code><nobr>label2.loop</nobr></code>. So,if you really needed to, you could write<p><pre>label3  ; some more code         ; and some more         jmp label1.loop</pre><p>Sometimes it is useful - in a macro, for instance - to be able to definea label which can be referenced from anywhere but which doesn't interferewith the normal local-label mechanism. Such a label can't be non-localbecause it would interfere with subsequent definitions of, and referencesto, local labels; and it can't be local because the macro that defined itwouldn't know the label's full name. NASM therefore introduces a third typeof label, which is probably only useful in macro definitions: if a labelbegins with the special prefix <code><nobr>..@</nobr></code>, then it doesnothing to the local label mechanism. So you could code<p><pre>label1:                         ; a non-local label .local:                         ; this is really label1.local ..@foo:                         ; this is a special symbol label2:                         ; another non-local label .local:                         ; this is really label2.local         jmp     ..@foo          ; this will jump three lines up</pre><p>NASM has the capacity to define other special symbols beginning with adouble period: for example, <code><nobr>..start</nobr></code> is used tospecify the entry point in the <code><nobr>obj</nobr></code> output format(see <a href="nasmdoc6.html#section-6.2.6">section 6.2.6</a>).<p align=center><a href="nasmdoc4.html">Next Chapter</a> |<a href="nasmdoc2.html">Previous Chapter</a> |<a href="nasmdoc0.html">Contents</a> |<a href="nasmdoci.html">Index</a></body></html>

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产日产欧产精品推荐色 | 色88888久久久久久影院按摩| 亚洲一区免费观看| 国产喂奶挤奶一区二区三区| 欧美日韩在线播放一区| 高清在线不卡av| 精品一区二区在线观看| 亚洲第一主播视频| 18涩涩午夜精品.www| 久久综合成人精品亚洲另类欧美| 欧美区视频在线观看| 97久久精品人人做人人爽| 国产精品正在播放| 免费成人结看片| 不卡视频在线观看| 国内欧美视频一区二区| 日日摸夜夜添夜夜添精品视频| 亚洲婷婷综合色高清在线| 国产欧美日韩综合精品一区二区| 日韩午夜激情电影| 91精品福利在线一区二区三区| 在线观看免费亚洲| 99re这里只有精品首页| 国产.欧美.日韩| 国产精品一区二区x88av| 看电视剧不卡顿的网站| 麻豆国产精品官网| 免费看精品久久片| 日日摸夜夜添夜夜添国产精品| 亚洲成人免费视频| 五月激情丁香一区二区三区| 午夜精品福利一区二区三区蜜桃| 亚洲国产人成综合网站| 亚洲第一精品在线| 亚洲国产精品久久人人爱蜜臀| 有坂深雪av一区二区精品| 亚洲人成网站精品片在线观看| 亚洲三级在线观看| 亚洲色图欧美偷拍| 亚洲与欧洲av电影| 亚洲成人黄色小说| 六月婷婷色综合| 国产精品99久久久久久宅男| 国产精选一区二区三区| 成人亚洲一区二区一| av成人免费在线观看| 97超碰欧美中文字幕| 91精彩视频在线观看| 欧美丝袜丝交足nylons图片| 91麻豆精品91久久久久同性| 欧美变态tickle挠乳网站| 久久天堂av综合合色蜜桃网| 精品国产乱码久久久久久免费| 国产三级精品在线| 亚洲欧美区自拍先锋| 亚洲成人午夜电影| 另类人妖一区二区av| 国产成人av网站| 91国偷自产一区二区三区观看| 欧美日韩在线播放三区四区| 精品成人私密视频| 欧美激情在线一区二区三区| 亚洲美女在线一区| 日韩黄色一级片| 国产精品一区二区久激情瑜伽| 91同城在线观看| 91精品国产综合久久福利软件| 精品99999| 亚洲欧洲制服丝袜| 蜜臀91精品一区二区三区 | 亚洲综合网站在线观看| 免费成人深夜小野草| 波多野结衣亚洲一区| 91超碰这里只有精品国产| 久久嫩草精品久久久精品一| 亚洲欧美另类久久久精品| 秋霞午夜av一区二区三区| 粉嫩aⅴ一区二区三区四区| 91麻豆蜜桃一区二区三区| 日韩一区二区电影在线| 亚洲欧美在线视频| 美国一区二区三区在线播放| 99久久精品国产观看| 亚洲三级理论片| 美女脱光内衣内裤视频久久影院| 不卡视频在线观看| 欧美v亚洲v综合ⅴ国产v| 亚洲激情av在线| 国产精品一二三四五| 欧美日韩精品系列| 国产精品人成在线观看免费 | 成人一级片在线观看| 欧美丰满高潮xxxx喷水动漫| 国产精品亲子伦对白| 日韩高清在线观看| 一本色道亚洲精品aⅴ| 久久精品视频在线免费观看 | www.日韩在线| 精品国产乱码久久久久久夜甘婷婷 | 欧美影片第一页| 中文一区在线播放| 久久精品国产在热久久| 欧美日本不卡视频| 亚洲精品免费电影| 成人黄色在线网站| 久久久精品人体av艺术| 美女视频一区二区| 欧美日韩激情一区二区| 亚洲精品中文字幕在线观看| 国产成人精品免费视频网站| 精品少妇一区二区三区免费观看| 亚洲成人av资源| 91黄视频在线观看| 中文字幕中文字幕一区二区| 激情久久五月天| 日韩欧美高清dvd碟片| 日韩电影在线免费看| 欧美亚洲国产一区在线观看网站| 中文字幕日本不卡| voyeur盗摄精品| 中文一区一区三区高中清不卡| 国产真实精品久久二三区| 日韩亚洲欧美在线| 蜜桃一区二区三区四区| 日韩欧美在线影院| 蜜桃一区二区三区在线观看| 欧美一区中文字幕| 日韩精彩视频在线观看| 91精品在线一区二区| 日本美女一区二区三区视频| 欧美三级韩国三级日本一级| 一区二区成人在线| 欧美日韩一区小说| 天堂va蜜桃一区二区三区| 在线视频亚洲一区| 亚洲已满18点击进入久久| 在线精品国精品国产尤物884a| 亚洲激情中文1区| 欧美亚洲日本国产| 日韩精品福利网| 欧美成人精品高清在线播放| 韩国理伦片一区二区三区在线播放 | 亚洲伊人色欲综合网| 91久久精品一区二区三区| 亚洲成人午夜电影| 欧美电影免费观看高清完整版在线| 久久精品国产亚洲5555| 日韩精品一区二区三区视频播放| 国产综合久久久久久久久久久久 | 亚洲国产精品二十页| av影院午夜一区| 一级日本不卡的影视| 91.com在线观看| 国产主播一区二区三区| 国产一区二区在线视频| 国产午夜亚洲精品理论片色戒| 成人av网站在线观看免费| 亚洲精品视频一区二区| 91.麻豆视频| 国产一区二区福利视频| 中文字幕亚洲欧美在线不卡| 欧美三日本三级三级在线播放| 日本v片在线高清不卡在线观看| 精品国产成人在线影院| 菠萝蜜视频在线观看一区| 香蕉成人啪国产精品视频综合网 | 欧美中文一区二区三区| 日本女人一区二区三区| 中国色在线观看另类| 欧美色图激情小说| 国产一区二区三区免费| 亚洲三级免费电影| 精品久久一二三区| 91论坛在线播放| 久久丁香综合五月国产三级网站| 国产精品久久久久影院色老大| 欧美色图一区二区三区| 国产一区二区三区蝌蚪| 亚洲综合丝袜美腿| 久久免费美女视频| 欧美美女视频在线观看| 国产成人免费在线观看| 天堂蜜桃一区二区三区| 国产精品超碰97尤物18| 欧美电影免费观看高清完整版在| 99久久777色| 精品一区二区影视| 午夜在线电影亚洲一区| 中文字幕一区在线| 日韩精品一区二区三区在线观看| 91成人看片片| 国产·精品毛片| 精品亚洲aⅴ乱码一区二区三区| 亚洲欧美一区二区不卡| 久久久久国产精品免费免费搜索| 欧美三级资源在线| av在线播放一区二区三区| 国产美女久久久久| 日韩黄色小视频| 一二三四区精品视频|