80x86 Instruction Set.ppt

  1. 1、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。。
  2. 2、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  3. 3、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
80x86 Instruction Set.ppt

80x86 Instruction Set Dr. Qiang Lin Overview Most of assembler instructions presented are supported by all of the following Intel processors: 80186, 80286, 80386, 80486, Pentium (80586) Five major instruction categories: Transfer and Set Arithmetic Logic Jump Miscellaneous 80x86 Transfer Set Instructions 1 Transfer Instructions Examples 1 Example 1: MOV AX,0006h ; Move immediate data to AX register MOV BX,AX ; Move AX register data to BX register This small program moves the value of 0006H to the AX register, then it moves the content of AX (0006h) to the BX register Example 2: MOV AX,2000h ; Move immediate data to AX register MOV DS,AX ; Load DS segment register MOV SI, 100h ; Load immediate data to SI index register MOV DI, 120h ; Load immediate data to DI index register MOV CX, 10h ; Load immediate data to CX register MOV AH, [SI], ; Move memory data pointed by [SI] to AH register MOV [DI], AH ; Move AH register to memory located at [DI] Set Instructions That Test Flags Set Instructions for Unsigned Comparisons Set Instructions for Signed Comparisons Set Instructions Example Bool := ((A = B) and (D = E)) or (F G) MOV AX, A CMP AX, B SETLE BL MOV AX, D CMP AX, E SETE BH AND BL, BH MOV AX, F CMP AX, G SETNE BH OR BL, BH MOV Bool, BH 80x86 Transfer Instructions 2 Transfer Instructions Examples 2 Example 1: PUSH DS ; Push current DS content to stack MOV AX,0 ; Move immediate data to AX register PUSH AX ; Push 0 to stack MOV AL, 0A1H CBW CWD Example 2: IN AL, 60h ; Read keyboard port MOV DX,378h ; Point at LPT1: data port IN AL, DX ; Read data from printer port INC AX ; Bump ASCII code by one OUT DX, AL ; Write data in AL to printer port 80x86 String (Transfer) Instructions 3 80x86 Arithmetic Instructions 1 Arithmetic Instructions Examples 1 Example 1: J = K + M MOV AX, K ADD AX,M MOV J, AX Example 2: J = K + M + N + P MOV AX, K ADD AX,M ADD AX,N ADD AX,P MOV J, AX Arithmetic Instructions Examples 2 Example 1: J = K - J MOV A

文档评论(0)

shengyp + 关注
实名认证
内容提供者

该用户很懒,什么也没介绍

1亿VIP精品文档

相关文档