# Lecture 38 - Review for Final Exam

## Practical Details

1. Assignment 9
2. Optional Assignment
3. addresses.pdf, virtual.pdf, microcode.pdf

# Topics

## Combinational Logic

#### Big Ideas

1. Digital versus analogue
• error control
2. AND, OR, NOT, etc.
3. More complex components

#### Skills

1. Manipulate truth tables
2. Simplify Boolean expressions
3. Manipulate disjunctive normal forms
4. Create circuits from truth tables or Boolean expressions

## Sequential Logic

#### Big Ideas

1. Latch, flip-flop
• component that retains state
2. Three-state outputs
3. Clock
4. Finite state machines

#### Skills

1. Create simple sequential circuits
• counters
• memories
2. Build simple state machines

## Data Representation & Manipulation

#### Big Ideas

1. Numbers
• two's complement
• floating point
2. ALUs
• multiplication

#### Skills

1. Manipulate numbers in different representations
2. Construct one-bit ALU
• compound it into wider ALU

## Single-cycle Processors

#### Big Ideas

1. Categories of instructions
• keep it simple
2. Datapaths
• multiplexed, using multiplexers
3. Control

#### Skills

1. Map instructions onto data paths
2. Map instructions onto control logic
3. Calculate things like the fastest possible clock

## Multi-cycle Processors

#### Big Ideas

1. Phases of instruction execution
• multiple phases per instruction
• variable number of phases per instruction
• multiple datapath configurations per instruction
• one clock per phase
2. Reuse of hardware
3. Sequence of control states
• for each instruction
• microcode

#### Skills

1. Separate a single cycle design into phases
• datapaths
2. Design sequential control logic
• finite state machine

## Pipelining

#### Big Ideas

1. Overlap phases of instruction execution
2. Preserving state/control using registers
3. Hazards
• structural
• control
• data

#### Skills

1. Introducing registers to preserve state
2. Identifying and resolving hazards, using
• hardware replication
• stall
• branch prediction
• forwarding
3. High-level view of adding hardware to enable branch prediction and forwarding

## Memory Hierarchies

#### Big Ideas

1. Levels of access
• bigger & slower as they get further from the processor
• hits, misses
2. Dividing the address
• blocks of memory
3. Cache
• line = block
• direct-mapped, associative, set associative
• line replacement
4. Virtual memory
• swapping, protection
• page = block
• translation-lookaside buffer (TLB)
• page replacement
• role of software

#### Skills

1. Map an address onto a cache line or a physical address
2. Iteratively access slower and bigger memories
3. Create a cache with given parameters

## Input/Output

#### Big Ideas

1. How a bus works
• bus arbitration
• master/slave
• bus transaction
• handshake
2. Characteristics of disk drives
3. Multi-level buses

#### Skills

1. Calculate the speed and bandwidth of buses and peripherals