73.asm

来自「汇编语言复习资料」· 汇编 代码 · 共 51 行

ASM
51
字号
;7_3.asm

(1)
absdif  p1,p2,distance
宏展开:
1       push ax
2       mov  ax,p1
2       sub  ax,p2
1       cmp  ax,0
1       jge  ??0000
1       neg  ax
1??0000:mov  distance,ax
1       pop  ax

(2)
absdif  [bx],[si],x[di],cx
宏展开:
1       push ax
2       mov  ax,[bx]
2       sub  ax,[si]
1       cmp  ax,0
1       jge  ??0000
1       neg  ax
1??0000:mov  x[di],ax
1       pop  ax

(3)
absdif  [bx][si],x[bx][si],240h
宏展开:
1       push ax
2       mov  ax,[bx][si]
2       sub  ax,x[bx][si]
1       cmp  ax,0
1       jge  ??0000
1       neg  ax
1??0000:mov  240h,ax
1       pop  ax

(4)
absdif  ax,ax,ax
宏展开:
1       push ax
2       mov  ax,ax
2       sub  ax,ax
1       cmp  ax,0
1       jge  ??0000
1       neg  ax
1??0000:mov  ax,ax
1       pop  ax
    该调用是无效的,因为宏展开后得到的语句不是有效的.

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?