๐งฉ Overview of Computer Architecture



Computer architecture refers to the design, structure, and functional behavior of a computer system. It defines how different components of a computerโsuch as the CPU, memory, and input/output devicesโinteract with each other to execute programs.
At its core, computer architecture answers three main questions:
- What does the system do? (Functionality)
- How is it organized? (Structure)
- How does it operate? (Behavior)
The architecture of a computer is usually divided into:
- Instruction Set Architecture (ISA) โ Interface between hardware and software
- Microarchitecture โ Internal implementation of the processor
- System Design โ Integration of hardware components
๐ง Historical Background
1. Early Computing Machines


The development of computer architecture began with early mechanical devices:
- Abacus โ First counting tool
- Analytical Engine (Charles Babbage) โ Concept of programmable machines
- ENIAC โ First electronic general-purpose computer
2. Von Neumann Architecture



The Von Neumann architecture is the foundation of modern computers. It introduced the stored-program concept, where instructions and data are stored in the same memory.
Key components:
- Central Processing Unit (CPU)
- Memory
- Input/Output devices
- Bus system
โ๏ธ Core Components of Computer Architecture
1. Central Processing Unit (CPU)



The CPU is the brain of the computer, responsible for executing instructions.
Components of CPU:
a. Arithmetic Logic Unit (ALU)
- Performs arithmetic operations: addition, subtraction
- Performs logical operations: AND, OR, NOT
- Executes comparisons
b. Control Unit (CU)
- Directs operations of the processor
- Fetches instructions from memory
- Decodes and executes them
c. Registers
- Small, fast storage locations inside CPU
- Examples:
- Program Counter (PC)
- Instruction Register (IR)
- Accumulator
2. Memory Unit

Memory stores data and instructions.
Types of Memory:
a. Primary Memory
- RAM (Random Access Memory) โ Volatile
- ROM (Read Only Memory) โ Non-volatile
b. Secondary Memory
- Hard Disk, SSD, Optical Disks
- Permanent storage
c. Cache Memory
- High-speed memory
- Located close to CPU
- Improves performance
3. Input and Output Units


Input Devices:
- Keyboard
- Mouse
- Scanner
Output Devices:
- Monitor
- Printer
- Speakers
These units enable communication between user and computer.
4. Bus System


The bus is a communication system that transfers data between components.
Types of Buses:
- Data Bus โ Transfers data
- Address Bus โ Carries memory addresses
- Control Bus โ Sends control signals
๐ Instruction Cycle (Fetch-Decode-Execute)

The CPU processes instructions in a cycle:
- Fetch โ Retrieve instruction from memory
- Decode โ Interpret instruction
- Execute โ Perform operation
This cycle repeats continuously.
๐งฎ Instruction Set Architecture (ISA)
ISA defines:
- Instruction formats
- Addressing modes
- Data types
- Registers
Examples:
- RISC (Reduced Instruction Set Computer)
- CISC (Complex Instruction Set Computer)
โก RISC vs CISC Architecture




| Feature | RISC | CISC |
|---|---|---|
| Instructions | Simple | Complex |
| Execution | Fast | Slower |
| Examples | ARM | x86 |
๐ง Memory Hierarchy
Memory is organized based on speed and cost:
- Registers (fastest)
- Cache
- RAM
- Secondary Storage (slowest)
Key principle:
Faster memory is more expensive and smaller.
โ๏ธ Microarchitecture
Microarchitecture refers to:
- Internal design of CPU
- Pipelining
- Superscalar execution
- Branch prediction
๐ Pipelining



Pipelining improves performance by overlapping instruction execution.
Stages:
- Fetch
- Decode
- Execute
- Memory
- Write-back
๐งฉ Parallelism in Architecture
Types:
- Instruction-Level Parallelism (ILP)
- Data-Level Parallelism (DLP)
- Thread-Level Parallelism (TLP)
Examples:
- Multi-core processors
- GPUs
๐ฅ๏ธ Types of Computer Architectures
1. Von Neumann Architecture
- Single memory for data and instructions
- Simpler design
- Bottleneck issue
2. Harvard Architecture



- Separate memory for data and instructions
- Faster access
- Used in embedded systems
๐งฎ Addressing Modes
Defines how operands are accessed:
- Immediate
- Direct
- Indirect
- Indexed
- Register
โก Performance Metrics
1. Clock Speed
- Measured in GHz
- Determines how many cycles per second
2. Throughput
- Number of tasks per unit time
3. Latency
- Time taken to execute a task
๐ Control Signals and Timing
- Control unit generates signals
- Synchronization through clock pulses
- Ensures proper sequencing
๐ง Registers in Detail
Types:
- General-purpose registers
- Special-purpose registers:
- Program Counter
- Stack Pointer
- Status Register
๐ฆ Cache Memory Levels
- L1 Cache โ fastest, smallest
- L2 Cache โ larger, slower
- L3 Cache โ shared among cores
๐งฉ Multiprocessing and Multicore Systems



- Multiple processors or cores
- Improves performance and multitasking
๐ Interrupts in Computer Architecture
- Signals from devices to CPU
- Types:
- Hardware interrupts
- Software interrupts
๐งฎ Input/Output Organization
Methods:
- Programmed I/O
- Interrupt-driven I/O
- Direct Memory Access (DMA)
๐ Bus Arbitration
- Determines which device controls the bus
- Methods:
- Centralized
- Distributed
๐ง Evolution of Computer Architecture
Generations:
- Vacuum Tubes
- Transistors
- Integrated Circuits
- Microprocessors
- AI-based architectures
โ๏ธ Modern Trends in Computer Architecture

- Quantum Computing
- Neuromorphic Computing
- Edge Computing
- Cloud Computing
๐งพ Advantages of Computer Architecture Design
- Efficient processing
- Scalability
- Flexibility
- Optimization of resources
โ ๏ธ Limitations
- Complexity
- Cost
- Power consumption
- Heat generation
๐ง Conclusion
Basic computer architecture forms the foundation of all computing systems. From simple machines to modern AI-powered systems, understanding architecture helps in:
- Designing efficient systems
- Improving performance
- Building advanced technologies
It connects hardware and software, enabling computers to solve complex problems efficiently.
