Processor and Memory

Processor Architecture

Main processor functions

Single cycle processor design

Analyzing single cycle design

Pipelined processor design

Processor Performance Analysis

Performance: single cycle vs pipeline

Pipeline design provides 3x performance (ideally) due to combination of overlapped execution and smaller cycle time

What limits pipeline performance?

Data dependencies

Data dependence hazards in pipeline

Control dependence hazards in pipeline

Avoiding control hazards

Performance boosting techniques

Memory Technologies

Memory requirements

Example memory technologies

Technology Typical access time $ per GB
SRAM 1-10 ns $1000
DRAM* ~100 ns $10
Flash SSD ~100 ΞΌs $1
Magnetic disk ~10 ms $0.1

*Used as "main memory"

SRAM

DRAM

Memory bank organization and operation

DRAM read access

DRAM vs SRAM

DRAM SRAM
Slower access (capacitor) Faster access (no capacitor)
Higher density (1T-1C cell) – Stores more bits per units area Lower density (6T cell) – Stores less bits per unit area
Lower cost – Enables bigger memory Higher cost – Not suitable for big memory
Require refresh – Needs power and area – Reduces performance No refresh required

Memory Hierarchy

Memory hierarchy idea

Why is memory hierarchy effective?

Memory hierarchy in modern processors

Cache Terminology

Direct Mapped Caches

Accessing cache

How to know which of these memory locations is currently mapped to the selected cache line?

Practice Proble on Direct Mapped Caches

Given a 4 KB direct-mapped cache with 8-byte blocks and 32-bit addresses. Question: How many tag, index, and offset bits does the address decompose into? Answer: