Intel 64 and IA-32 Architectures Software Developers Manual Volume 2B, Instruction Set Reference, N-Z
Vol. 2B 4-313
INSTRUCTION SET REFERENCE, N-Z
SLDT—Store Local Descriptor Table Register
Description
Stores the segment selector from the local descriptor table register (LDTR) in the
destination operand. The destination operand can be a general-purpose register or a
memory location. The segment selector stored with this instruction points to the
segment descriptor (located in the GDT) for the current LDT. This instruction can only
be executed in protected mode.
Outside IA-32e mode, when the destination operand is a 32-bit register, the 16-bit
segment selector is copied into the low-order 16 bits of the register. The high-order
16 bits of the register are cleared for the Pentium 4, Intel Xeon, and P6 family proces-
sors. They are undefined for Pentium, Intel486, and Intel386 processors. When the
destination operand is a memory location, the segment selector is written to memory
as a 16-bit quantity, regardless of the operand size.
In compatibility mode, when the destination operand is a 32-bit register, the 16-bit
segment selector is copied into the low-order 16 bits of the register. The high-order
16 bits of the register are cleared. When the destination operand is a memory loca-
tion, the segment selector is written to memory as a 16-bit quantity, regardless of
the operand size.
In 64-bit mode, using a REX prefix in the form of REX.R permits access to additional
registers (R8-R15). The behavior of SLDT with a 64-bit register is to zero-extend the
16-bit selector and store it in the register. If the destination is memory and operand
size is 64, SLDT will write the 16-bit selector to memory as a 16-bit quantity, regard-
less of the operand size
Operation
DEST ← LDTR(SegmentSelector);
Flags Affected
None.
Protected Mode Exceptions
#GP(0) If the destination is located in a non-writable segment.
Opcode Instruction
64-Bit
Mode
Compat/
Leg Mode Description
0F 00 /0 SLDT r/m16 Valid Valid Stores segment selector from LDTR
in r/m16.
REX.W + 0F
00 /0
SLDT r64/m16 Valid Valid Stores segment selector from LDTR
in r64/m16.