資源描述:
《尋址方式舉例》由會員上傳分享,免費(fèi)在線閱讀,更多相關(guān)內(nèi)容在行業(yè)資料-天天文庫。
1、直接尋址方式:MOVAX,[2000H]DS=3000H,EA=2000H物理地址:3000H*10H+2000H或者30000H+2000H=32000HAX=3050H低地址高地址存儲器32000H-------------------30H(高字節(jié))50H(低字節(jié))AX50H30HALAH寄存器間接尋址MOVAX,[BX]DS=2000H,BX=1000HEA=BX=2000H物理地址:20000H+1000H=21000HAX=50A0H低地址存儲器AL50HA0HAXAH------------21000HA
2、0H(低字節(jié))50H(高字節(jié))-------高地址寄存器相對尋址MOVAX,[BX+1000H]DS=3000H,BX=1000H,偏移量=1000HEA=1000H+1000H=2000H物理地址:30000H+EA=30000H+1000H+1000H=32000HAX=4010H高地址低地址存儲器32000H-------------------40H(高字節(jié))10H(低字節(jié))AX10H40HALAH寄存器相對尋址MOVAX,COUNT[SI]也可表示成:MOVAX,[COUNT+SI]DS=3000H,SI=2
3、000H,COUNT=3000HEA=2000H+3000H=5000H物理地址:30000H+2000H+3000H=35000HAX=4321H高地址低地址SI=2000H33000HCOUNT35000H43H(高字節(jié))-------21H(低字節(jié))AX12H43HALAH存儲器基址變址尋址MOVAX,[BX][SI]也可表示成:MOVAX,[BX+SI]DS=2100H,BX=0158H,DI=10A5HEA=BX+DI=0158H+10A5H=11FDH物理地址:21000H+EA=11FDH=221FDH高
4、地址低地址SI=10A5H21158HBX221FDH-------12H(高字節(jié))34H(低字節(jié))AX34H12HALAH存儲器AX=1234H相對基址變址尋址方式MOVAX,MASK[BX][SI]也可以寫成MOVAX,MASK[BX+SI]或者M(jìn)OVAX,[MASK+BX+SI]DS=3000H,BX=2000H,SI=1000H,MASK=0250HEA=BX+SI+MASK=2000H+1000H+0250H=3250H物理地址:30000H+EA=33250HAX=5678H33250HMASK=0250H
5、32000HBX32250H-------56H(高字節(jié))AX78H56HALAH存儲器78H(低字節(jié))SI低地址高地址