为什么出栈操作会出现乱码
如程序data segment
buf db 'abcdefg'
count equ $-buf
data ends
stack segment para stack 'stack'
span db 100 dup (?)
top equ $
stack ends
code segment
assume cs:code,ds:data,ss:stack
start: mov ax,data
mov ds,ax
mov ax,stack
mov ss,ax
mov sp,offset top
mov bx,offset buf
mov cx,count
mov si,0
lop1: push [bx+si];入栈操作
inc si
loop lop1
mov bp,sp
mov cx,count
lop2: mov dl,[bp] ;出栈操作
mov ah,02h
int 21h
inc bp ;BP加2
inc bp
loop lop2
MOV AH,4CH
INT 21H
code ends
end start
执行后是正确的:gfedcba
但是当BP加一时却是乱码:g fgefd
为什么?