|
楼主 |
发表于 2010-9-17 12:27:32
|
显示全部楼层
RCL Rotate bits left with CF
operands bytes 8088 186 286 386 486 Pentium
reg, 1 2 2 2 2 9 3 1 PU
mem, 1 2+d(0,2) 23+EA 15 7 10 4 3 PU
reg, cl 2 8+4n 5+n 5+n 9 8-30 7-24 NP
mem, cl 2+d(0,2) 28+EA+4n 17+n 8+n 10 9-31 9-26 NP
reg, imm 3 - 5+n 5+n 9 8-30 8-25 NP
mem, imm 3+d(0,2) - 17+n 8+n 10 9-31 10-27 NP
Example: rcl eax, 16
RCR Rotate bits right with CF
operands bytes 8088 186 286 386 486 Pentium
reg, 1 2 2 2 2 9 3 1 PU
mem, 1 2+d(0,2) 23+EA 15 7 10 4 3 PU
reg, cl 2 8+4n 5+n 5+n 9 8-30 7-24 NP
mem, cl 2+d(0,2) 28+EA+4n 17+n 8+n 10 9-31 9-26 NP
reg, imm 3 - 5+n 5+n 9 8-30 8-25 NP
mem, imm 3+d(0,2) - 17+n 8+n 10 9-31 10-27 NP
Example: rcr eax, 16
ROL Rotate bits left
operands bytes 8088 186 286 386 486 Pentium
reg, 1 2 2 2 2 3 3 1 PU
mem, 1 2+d(0,2) 23+EA 15 7 7 4 3 PU
reg, cl 2 8+4n 5+n 5+n 3 3 4 NP
mem, cl 2+d(0,2) 28+EA+4n 17+n 8+n 7 4 4 NP
reg, imm 3 - 5+n 5+n 3 2 1 PU
mem, imm 3+d(0,2) - 17+n 8+n 7 4 3 PU*
* = not pairable if there is a displacement and immediate
Example: rol eax, 16
ROR Rotate bits right
operands bytes 8088 186 286 386 486 Pentium
reg, 1 2 2 2 2 3 3 1 PU
mem, 1 2+d(0,2) 23+EA 15 7 7 4 3 PU
reg, cl 2 8+4n 5+n 5+n 3 3 4 NP
mem, cl 2+d(0,2) 28+EA+4n 17+n 8+n 7 4 4 NP
reg, imm 3 - 5+n 5+n 3 2 1 PU
mem, imm 3+d(0,2) - 17+n 8+n 7 4 3 PU*
* = not pairable if there is a displacement and immediate
Example: ror eax, 16
RDMSR Read from model specific register (Pentium+)
bytes Pentium
2 20-24 NP
Example: rdmsr
REP Repeat string operation
See: MOVS (rep movs) move block
See: STOS (rep stos) fill block
REPE Repeat while equal (or zero) string operation
See: CMPS (repe cmps) find non-matching memory items
See: CMPS (repe scas) find non-acc matching byte in memory
REPNE Repeat while not equal (or not zero) string operation
See: CMPS (repne cmps) find first matching memory items
See: SCAS (repne scas) find first matching memory item to acc
RET/RETN/RETF Return from procedure
variations/
operands bytes 8088 186 286 386 486 Pentium
retn 1 20 16 11+m 10+m 5 2 NP
retn imm16 1+d(2) 24 18 11+m 10+m 5 3 NP
retf 1 34 22 15+m 18+m 13 4 NP
retf imm16 1+d(2) 33 25 15+m 18+m 14 4 NP
RET is coded by the assembler as near or far based on the
procedure declaration and program model, as:
RETN (return near)
RETF (return far)
Example: ret
Protected Mode
variations/
operands bytes 286 386 486 Pentium
retf 1 25+m/55 32+m/62 18/33 4-13/23 NP
retf imm16 1+d(2) 25+m/55 32+m/68 17/33 4-13/23 NP
cycles for: same privilege level/lower privilege level
RSM Resume from system management mode (Pentium+)
bytes Pentium
2 83 NP
Example: rsm
SAL/SHL/SAR/SHR Shift bits
operands bytes 8088 186 286 386 486 Pentium
reg, 1 2 2 2 2 3 3 1 PU
mem, 1 2+d(0,2) 23+EA 15 7 7 4 3 PU
reg, cl 2 8+4n 5+n 5+n 3 3 4 NP
mem, cl 2+d(0,2) 28+EA+4n 17+n 8+n 7 4 4 NP
reg, imm 3 - 5+n 5+n 3 2 1 PU
mem, imm 3+d(0,2) - 17+n 8+n 7 4 3 PU*
* = not pairable if there is a displacement and immediate
sal = shift arithmetic left sar = shift arithmetic right
shl = shift left (same as sal) shr = shift right
Example: shl eax, 1
SAHF Store AH into flags
bytes 8088 186 286 386 486 Pentium
1 4 3 2 3 2 2 NP
Example: sahf
SBB Integer subtraction with borrow
operands bytes 8088 186 286 386 486 Pentium
reg, reg 2 3 3 2 2 1 1 PU
mem, reg 2+d(0,2) 24+EA 10 7 7 3 3 PU
reg, mem 2+d(0,2) 13+EA 10 7 6 2 2 PU
reg, imm 2+i(1,2) 4 4 3 2 1 1 PU
mem, imm 2+d(0,2) 23+EA 16 7 7 3 3 PU*
+i(1,2)
acc, imm 1+i(1,2) 4 4 3 2 1 1 PU
* = not pairable if there is a displacement and immediate
Example: sbb eax, ebx
SCAS/SCASB/SCASW/SCASD Scan string data
variations bytes 8088 186 286 386 486 Pentium
scasb 1 19 15 7 7 6 4 NP
scasw 1 19 15 7 7 6 4 NP
scasd 1 - - - 7 6 4 NP
repX scasb 2 9+15n 5+15n 5+8n 5+8n 7+5n* 8+4n NP
repX scasw 2 9+19n 5+15n 5+8n 5+8n 7+5n* 8+4n NP
repX scasd 2 - - - 5+8n 7+5n* 8+4n NP
repX = repe or repz or repne or repnz
* = 5 if n=0
(n = count of bytes, words or dwords)
Example: repne scasb
SET Set byte to 1 on condition else set to 0 (386+)
operand bytes 386 486 Pentium
r8 3 4 4/3 1/2 NP
mem8 3+d(0-2) 5 3/4 1/2 NP
Cycles are for: true/false
setCC = one of:
seta setae setb setbe setc sete
setg setge setl setle setna setnae
setnb setnbe setnc setne setng setnge
setnl setnle setno setnp setns setnz
seto setp setpe setpo sets setz
Example: setne al
SGDT Store global descriptor table register (286+)
operand bytes 286 386 486 Pentium
mem48 5 11 9 10 4 NP
Example: sgdt descriptor[ebx]
SIDT Store interrupt descriptor table register (286+)
operand bytes 286 386 486 Pentium
mem48 5 12 9 10 4 NP
Example: sidt descriptor[ebx]
SHLD Double precision shift left (386+)
operands bytes 386 486 Pentium
reg, reg, imm 4 3 2 4 NP
mem, reg, imm 4+d(0-2) 7 3 4 NP
reg, reg, cl 4 3 3 4 NP
mem, reg, cl 4+d(0-2) 7 4 5 NP
Example: shld eax, ebx, 16
SHRD Double precision shift right (386+)
operands bytes 386 486 Pentium
reg, reg, imm 4 3 2 4 NP
mem, reg, imm 4+d(0-2) 7 3 4 NP
reg, reg, cl 4 3 3 4 NP
mem, reg, cl 4+d(0-2) 7 4 5 NP
Example: shrd eax, ebx, 16
SLDT Store local descriptor table register (286+)
operands bytes 286 386 486 Pentium
r16 3 2 2 2 2 NP
mem16 3+d(0-2) 3 2 3 2 NP
Example: sldt ax
SMSW Store machine status word (286+)
operands bytes 286 386 486 Pentium
r16 3 2 2 2 4 NP
mem16 3+d(0-2) 3 3 3 4 NP
Example: smsw ax
STC Set the carry flag
bytes 8088 186 286 386 486 Pentium
1 2 2 2 2 2 2 NP
Example: stc
STD Set direction flag (set to reverse string direction)
bytes 8088 186 286 386 486 Pentium
1 2 2 2 2 2 2 NP
Example: std
STI Set interrupt flag (enable)
bytes 8088 186 286 386 486 Pentium
1 2 2 2 3 5 7 NP
Example: sti
STOS/STOSB/STOSW/STOSD Store string data
variations bytes 8088 186 286 386 486 Pentium
stosb 1 11 10 3 4 5 3 NP
stosw 1 15 10 3 4 5 3 NP
stosd 1 - - - 4 5 3 NP
rep stosb 2 9+10n 6+9n 4+3n 5+5n 7+4n* 3+n NP
rep stosw 2 9+14n 6+9n 4+3n 5+5n 7+4n* 3+n NP
rep stosd 2 - - - 5+5n 7+4n* 3+n NP
* = 5 if n=0, 13 if n=1
(n = count of bytes, words or dwords)
Example: rep stosd
STR Store task register (286+)
operand bytes 286 386 486 Pentium
r16 3 2 2 2 2 NP
mem16 3+d(0-2) 3 2 3 2 NP
Example: str bx
SUB Integer subtraction
operands bytes 8088 186 286 386 486 Pentium
reg, reg 2 3 3 2 2 1 1 UV
mem, reg 2+d(0,2) 24+EA 10 7 7 3 3 UV
reg, mem 2+d(0,2) 13+EA 10 7 6 2 2 UV
reg, imm 2+i(1,2) 4 4 3 2 1 1 UV
mem, imm 2+d(0,2) 23+EA 16 7 7 3 3 UV*
+i(1,2)
acc, imm 1+i(1,2) 4 4 3 2 1 1 UV
* = not pairable if there is a displacement and immediate
Example: sub eax, ebx
TEST Logical compare
operands bytes 8088 186 286 386 486 Pentium
reg, reg 2 3 3 2 2 1 1 UV
mem, reg 2+d(0,2) 13+EA 10 6 5 2 2 UV
reg, mem 2+d(0,2) 13+EA 10 6 5 2 2 UV
reg, imm 2+i(1,2) 5 4 3 2 1 1 UV
mem, imm 2+d(0,2) 11+EA 10 6 5 2 2 UV*
+i(1,2)
acc, imm 1+i(1,2) 4 4 3 2 1 1 UV
* = not pairable if there is a displacement and immediate
Example: sub eax, ebx
VERR Verify a segment for reading (286+)
operand bytes 286 386 486 Pentium
r16 3 14 10 11 7 NP
mem16 3+d(0,2) 16 11 11 7 NP
Example: verr ax
VERW Verify a segment for writing (286+)
operand bytes 286 386 486 Pentium
r16 3 14 15 11 7 NP
mem16 3+d(0,2) 16 16 11 7 NP
Example: verr ax
WAIT Wait for co-processor
bytes 8088 186 286 386 486 Pentium
1 4 6 3 6 1-3 1 NP
Example: wait
WBINVD Write-back and invalidate data cache (486+)
bytes 486 Pentium
2 5 2000+ NP
Example: wbinvd
WRMSR Write to model specific register (PENTIUM+)
bytes Pentium
2 30-45 NP
Example: wrmsr
XADD Exchange and add (486+)
operands bytes 486 Pentium
reg, reg 3 3 3 NP
mem, reg 3+d(0-2) 4 4 NP
Example: xadd eax, ebx
XCHG Exchange register/memory with register
operands bytes 8088 186 286 386 486 Pentium
reg, reg 2 4 4 3 3 3 3 NP
reg, mem 2+d(0-2) 25+EA 17 5 5 5 3 NP
mem, reg 2+d(0-2) 25+EA 17 5 5 5 3 NP
acc, reg 1 3 3 3 3 3 2 NP
reg, acc 1 3 3 3 3 3 2 NP
in above: acc = AX or EAX only
Example: xchg ax, dx
XLAT/XLATB Table look-up translation
bytes 8088 186 286 386 486 Pentium
1 11 11 5 5 4 4 NP
Example: xlat
XOR Logical exclusive or
operands bytes 8088 186 286 386 486 Pentium
reg, reg 2 3 3 2 2 1 1 UV
mem, reg 2+d(0,2) 24+EA 10 7 7 3 3 UV
reg, mem 2+d(0,2) 13+EA 10 7 6 2 2 UV
reg, imm 2+i(1,2) 4 4 3 2 1 1 UV
mem, imm 2+d(0,2) 23+EA 16 7 7 3 3 UV*
+i(1,2)
acc, imm 1+i(1,2) 4 4 3 2 1 1 UV
* = not pairable if there is a displacement and immediate
Example: xor eax, ebx |
|