CSC167 ยท 2080 ยท 5 marks
What are various functional units of 80386 microprocessor? Explain function of each unit.
What are various functional units of 80386 microprocessor? Explain function of each unit. [5]
Quick answer
The 80386 is a 32-bit microprocessor. To achieve high performance through parallelism, it is divided into several independent functional units that can operate simultaneously.
Functional Units of 80386 Microprocessor
Introduction
Functional Units of 80386
The 80386 microprocessor is internally divided into six functional units:
1. Bus Interface Unit (BIU)
- Manages all data and address transfers on the external buses (data bus, address bus, control bus).
- Handles communication between the processor and external memory or I/O devices.
- Generates the 32-bit physical address for memory access.
- Controls bus cycles and arbitration.
2. Code Prefetch Unit (CPU / Prefetch Unit)
- Fetches instruction bytes from memory in advance (before they are needed).
- Stores prefetched bytes in a 16-byte prefetch queue.
- Keeps the instruction pipeline filled so the processor does not have to wait for instruction fetch.
- Works in parallel with instruction decoding and execution.
3. Instruction Decode Unit
- Takes instruction bytes from the prefetch queue and decodes them into internal micro-operations.
- Maintains a queue of 3 decoded instructions ready for execution.
- Decoding in advance reduces delays during execution.
4. Execution Unit (EU)
- Carries out the actual arithmetic and logical operations on data.
- Contains the 32-bit ALU (Arithmetic Logic Unit) for integer operations.
- Accesses the general-purpose registers (EAX, EBX, ECX, EDX, ESI, EDI, ESP, EBP).
- Executes decoded instructions passed from the Instruction Decode Unit.
5. Segmentation Unit
- Handles memory segmentation by converting logical addresses (segment:offset) into linear addresses.
- Uses segment registers (CS, DS, SS, ES, FS, GS) and descriptor tables.
- Provides memory protection by checking segment limits and access rights.
6. Paging Unit
- Converts linear addresses (produced by the Segmentation Unit) into physical addresses.
- Implements demand paging using page tables and a Translation Lookaside Buffer (TLB) for fast address translation.
- Supports a 4 KB page size.
- Only active when paging is enabled (PG bit set in CR0).
Summary Table
| Unit | Primary Function |
|---|---|
| Bus Interface Unit | External bus communication and address generation |
| Code Prefetch Unit | Advance fetching of instructions into queue |
| Instruction Decode Unit | Decoding instructions into micro-operations |
| Execution Unit | ALU operations and register access |
| Segmentation Unit | Logical to linear address translation |
| Paging Unit | Linear to physical address translation |
Conclusion
These six units work in parallel (pipelined), so while one instruction is being executed, the next is being decoded and the one after that is being prefetched. This parallel operation significantly increases the throughput and performance of the 80386 processor.
Short on time? The 1, 5 and 10 mark versions of this answer, flashcards and practice sets come with a program pass.