Logical Memory Map: 00000H -> FFFFFH (1 MB, 20 bits)
16 MB of physical memory, 1 GB of virtual memory
Important Note: 80386 includes Intel 80386, 80486, Pentium, Pentium Pro/II/III/4/D/M, Core, Core 2, Celeron; and AMD K5, K6, K6-2, Athlon, Turion, Opteron, Duron, Sempron processors
4 GB of physical memory (32-bit),
64 TB of virtual memory
(16,384 segments @ 4 GB per segment)Descriptors: 32-bit base address and 20-bit limit
This allows the entire DOS environment to be placed in one protected mode segment multitasking of DOS environments by merely switching from one segment to another with a task switch.
Each task segment can be running a different application, simultaneously, through time-slicing.
Base: Start of segment (32-bit address) in physical memory
Limit: Length of segment (20 bits) in bytes or 4 kB pages
Granularity bit (G):
Descriptor Privilege Level (DPL)
Segment bit (S): specifies whether the descriptor defines a system segment or gate descriptor (S = 0) or data or code segment (S = 1)
Type : 3 bits
Segment present bit(P):
If P = 0, the segment is mapped into the physical
address space, and if P = 1, no physical memory
exists and base and limit are not used for the
descriptor. This is used on some
operating systems to swap segments from physical memory to disk
memory.
Accessed bit (A):
Set to 1 whenever the descriptor and the segment it
describes are accessed. It is used to
test descriptors for activity in some operating systems.
Default size(D):
Indicates the default size of a code segment. If D = 0,
the code segment default width is 16 bits, and if D = 1,
the default size is 32 bits. This is
used to determine between 80286 and 80386 descriptors.
Available field (AVL):
This field is available for the operating system or the
user.
| Name | Function |
|---|---|
| P=Present | P=1 Segment Present |
| DPL (2-bits) | Descriptor Privilege Level |
| S=Segment | S=1 Code or data segment S=0 System or gate descriptor |
| E=Executable | E=0 Data descriptor E=1 Code descriptor |
| C=Code Segment | C=0 Privilege ignored for code segment C=1 Privilege observed for code segment |
| ED=Direction | ED=0 Data segment expands upward ED=1 Data segment expands downward |
| W=Write | W=0 Data segment may not be written W=1 Data segment may be written |
| R=Read | R=0 Code segment may not be read R=1 Code segment may be read |
| A=Accessed | A=0 Segment has not been accessed A=1 Segment has been accessed |
Each page in the 80386 paging scheme is 4K bytes in length.
| Name | Function |
| D=Dirty bit | 1=Page modified (page table only) |
| A=Accessed bit | 1 when '386 accesses the page directory and subsequent table |
| R/W=Read/Write bit | 0=Read-only, 1=Read/write |
| U/S=User/ Supervisor bit | 1=the '386 can still write to the page directory entry even if it is marked Read-only by the R/W bit |
| P=Present bit | 1=page directory entry is present |
| Function | IRQ
# |
Instruction(s) Which Can Cause Exception |
| Divide Error | 0 | DIV, IDIV |
| Debug Exception | 1 | any instruction |
| NMI Interrupt | 2 | INT 2 or NMI |
| One Byte Interrupt | 3 | INT |
| Interrupt on Overflow | 4 | INTO |
| Array Bounds Check | 5 | BOUND |
| Invalid OP-Code | 6 | An illegal instruction that is not defined in the instruction set is executed. |
| Device Not Available | 7 | ESC, WAIT |
| Double Fault | 8 | A type A, B, C, or D interrupt at the same time that an interrupt other than a type E is detected. |
| Coprocessor Segment Overrun | 9 | Operand address wraps around from FFFFH to 0000H in virtual 8086 mode or real mode or from FFFFFFFFH to 00000000H in protected mode. |
| Invalid TSS | A | The selector, code segment or stack segment is outside the table limit, stack is not writable, or if the RPL is not equal to the TSS DPL. |
| Segment Not Present | B | The P bit of the descriptor is not set. |
| Stack Fault | C | The SS descriptor addresses a segment that is not present or if any stack operation causes a limit violation |
| General Protection Fault | D | Exceeding segment limit; writing to a read-only code or data segment; loading a selector with a system descriptor; reading an execute only code segment; switching to a busy task; violating DPL for a data segment; PG = 1 and PE = 0 |
| Page Fault | E | If PG=1 and the privilege level is incorrect or the page table or directory contains a zero. |
| Coprocessor Error | 10 | 80387 ERROR pin set. |
| Intel Reserved | 11-20 | Reserved by Intel for future projects. |
| Two Byte Interrupt | 00-FF |