能力值:
( LV2,RANK:10 )
|
-
-
2 楼
应该是通过寄存器si传递参数的吧
实现加法的吗!先判断,然后加,有什么问题吗?
|
能力值:
( LV10,RANK:170 )
|
-
-
3 楼
好像是代码可重入之类的,我也不太明白,再发一段代码吧
|
能力值:
( LV10,RANK:170 )
|
-
-
4 楼
mov ds,0100h ;ds=0100h
mov si,0010h ;si=0010h
mov ax,0001h ;ax,=0001h
call Add
cmp 0100h:word ptr [0010h],0 ;Call Add subroutine
push ds ;Interrupted
push si
push ax
mov ds,0200h ;ds=0200h
mov si,0200h ;si=0020h
mov ax,0003h ;ax=0003h
call Add
cmp 0200h:word ptr [0020h],0 ;0200:0020h=0004h
jne
add ax,0200h:word ptr [0020h] ;ax=0007h
ret ;Return
pop ax ;ax=0001h
pop si ;si=0010h
pop ds ;ds=0100h
iret ;Return to Add subroutine
jne
add ax,0100h:word ptr [0100h] ;ax= 0001h
;0100h:0010h= 0002h
;----------------------------------------
;ax = 0003h
ret
|
|
|