![]() |
#2
zklhp2012-09-09 13:13
|

assume cs:codesg
codesg segment
dw 0123h,0456h,0789h,0abch,0defh,0fedh,0cbah,0987h
dw 0,0,0,0,0,0,0,0
start: mov ax,cs
mov ss,ax
mov sp,32 ;为什么栈顶便宜地址为32,不是应该为20h吗?
mov bx,0
mov cx,8
s: push cs:[bx]
add bx,2
loop s
mov bx,0
mov cx,8
s0: pop cs:[bx]
add bx,2
loop s0
mov ax,4c00h
int 21h
codesg ends
end start
代码如上,是王爽《汇编语言》第六章6.2节的代码,编写的时候不是应该为16进制吗?16进制的32应该为(20h)吧,书上源代码应该是错误的吧?