<<<    Index    >>>
B-3
INSTRUCTION FORMATS AND ENCODINGS
B.1.2.Encoding of Operand Size Bit (w)
The current operand-size attribute determines whether the processor is performing 16-or 32-bit
operations. Within the constraints of the current operand-size attribute, the operand-size bit (w)
can be used to indicate operations on 8-bit operands or the full operand size specified with the
operand-size attribute (16 bits or 32 bits). Table B-4 shows the encoding of the w bit depending
on the current operand-size attribute.
B.1.3.Sign Extend (s) Bit
The sign-extend (s) bit occurs primarily in instructions with immediate data fields that are being
extended from 8 bits to 16 or 32 bits. Table B-5 shows the encoding of the s bit.
Table B-3.  Encoding of reg Field When w Field is Present in Instruction
Register Specified by reg Field
during 16-Bit Data Operations
Register Specified by reg Field
during 32-Bit Data Operations
Function of w Field
Function of w Field
regWhen w = 0When w = 1
regWhen w = 0When w = 1
000
AL
AX
000
AL
EAX
001
CL
CX
001
CL
ECX
010
DL
DX
010
DL
EDX
011
BL
BX
011
BL
EBX
100
AH
SP
100
AH
ESP
101
CH
BP
101
CH
EBP
110
DH
SI
110
DH
ESI
111
BH
DI
111
BH
EDI
Table B-4.  Encoding of Operand Size (w) Bit
w Bit
Operand Size When 
Operand-Size Attribute is 16 bits
Operand Size When 
Operand-Size Attribute is 32 bits
0
8 Bits
8 Bits
1
16 Bits
32 Bits
Table B-5.  Encoding of Sign-Extend (s) Bit
s
Effect on 8-Bit
Immediate Data
Effect on 16- or 32-Bit
Immediate Data
0None
None
1Sign-extend to fill 16-bit or 32-bit destination
None
<<<    Index    >>>