+ -
当前位置:首页 → 问答吧 → 请教关于mov ss,ax的问题

请教关于mov ss,ax的问题

时间:2010-11-19

来源:互联网

assume cs:codeseg
codeseg segment
dw 0123h,0456h,0789h
dw 0,0,0
  start:mov ax,cs
mov ss,ax
mov sp,0dh
  ……
这段代码生成的exe在debug中加载后用r,d (cs):0 b,u显示:
23 01 56 34 89 07 00 00-00 00 00 00
为什么在debug中运行到mov ss,ax后 d(cs):0 b的数据就改变了呢。
相关图片保存在http://hi.csdn.net/space-695323-do-album-picid-683886-goto-down.html

作者: ghdwff   发布时间: 2010-11-19

段内偏移地址要增加,SP=SP+2

作者: kartik   发布时间: 2010-11-19

引用 1 楼 kartik 的回复:
段内偏移地址要增加,SP=SP+2
同上

作者: znxllyuan   发布时间: 2010-11-19