User:Bastl/Selector
(Redirected from Selector)
Jump to navigation
Jump to search
Selectors are called the segment registers - CS, DS, ES, FS, GS - in protected mode, which are index registers holding an index pointer into a table (GDT, LDT), in other words holding indexes to a Descriptor.
They look like this:
Name | Bit | Description |
RPL | 0, 1 | Requested Privilege Level. The CPU checks these bits before any selector is changed. Also system calls can be executed in userspace (ring 3, see this) without misfeasance using the ARPL (Adjust Requested Privilege Level) instruction. |
---|---|---|
TI | 2 | Table index; 0 = GDT, 1 = LDT |
Index | 3..15 | Index to a Descriptor of the table. |