Library › Computer Science 9618 › Hardware and Virtual Machines
AS Level · Computer Science 9618

Hardware and Virtual Machines

Revise Hardware and Virtual Machines for Computer Science 9618 (AS Level) — revision notes and instant AI marking.

📖 Revision notes · preview
  Cambridge International AS & A Level Computer Science (9618)

Hardware and Virtual Machines

The big idea: Processors get faster by keeping instructions simple and overlapping them, or by working on many things at once. Underneath, the same logic gates that add numbers also store bits, and Boolean algebra and Karnaugh maps keep those circuits as small as possible.

Summary — What This Chapter Covers
  • RISC: few, simple, fixed-length instructions, mostly one clock cycle each, many registers, pipelining. CISC: many complex, variable-length instructions, multi-cycle, more work done in hardware.
  • Pipelining overlaps the fetch, decode, execute stages of successive instructions. Interrupts and branches complicate it.
  • Flynn's four architectures: SISD, SIMD, MISD, MIMD. Massively parallel computers link very many processors to work on one problem.
  • A virtual machine is software that emulates a computer; it lets one machine run several operating systems in isolation.
  • Half adder: S = A XOR B, C = A AND B. A full adder adds a carry in as well.
  • Flip-flops (SR, JK) store one bit and are the building blocks of registers and memory.
  • De Morgan's laws and Boolean algebra simplify expressions; Karnaugh maps simplify them visually by grouping 1s.
1. Processors, Parallel Processing and Virtual Machines
15.1

RISC, CISC, pipelining, Flynn, VMs

A CISC (Complex Instruction Set Computer) processor has a large set of instructions, some of which do several low-level operations at once (for example load from memory, add and store in one instruction). A RISC (Reduced Instruction Set Computer) processor has a small set of simple instructions that each do one thing, and builds complex operations from several of them.

RISCCISC
fewer, simpler instructionsmany, more complex instructions
fixed-length instructions, simple formatsvariable-length instructions, many formats
most instructions take one clock cycleinstructions take several clock cycles
few addressing modes; only load and store access memorymany addressing modes; many instructions access memory
many general-purpose registersfewer registers
well suited to pipeliningharder to pipeline
hard-wired control unit; more work for the compiler, longer programsmicroprogrammed control unit; shorter programs, simpler compiler

Pipelining splits instruction execution into stages and works on a different instruction in each stage at the same time, like a production line. A five-stage pipeline uses instruction fetch (IF), instruction decode (ID), operand fetch (OF), instruction execute (IE) and write back (WB). Registers matter because each stage must hold its intermediate results, and RISC's many registers let operands stay in the processor rather than in slower memory.

Stage12345678910
IFI1I2I3I4I5I6
IDI1I2I3I4I5I6
OFI1I2I3I4I5I6
IEI1I2I3I4I5I6
WBI1I2I3I4I5I6
Cycles for n instructions in a k-stage pipeline k + (n − 1) cycles, compared with k × n without pipelining. 6 instructions, 5 stages: 5 + 5 = 10 cycles instead of 30.

Interrupts.

Flynn's four architectures
ArchitectureMeaningExample
SISDSingle Instruction, Single Data: one processor, one instruction on one data item at a timeearly single-core computers
SIMD Single Instruction, Multiple Data: many processing elements carry out the same instruction on different data at once
MISD
MIMD

massively parallel computer

Virtual machines

virtual machine (VM)

🔓 Read the full Hardware and Virtual Machines note → You're seeing the preview · sign in to read it all
Also in the full note
  • Adders, flip-flops, De Morgan, K-maps
What's inside
📖 Revision notes 🎯 Learn mode ✦ AI flashcards ✓ Instant AI marking 🧊 3D explorers 🧪 Experiments & simulations 📈 Progress tracking
📄 Practise Hardware and Virtual Machines with Computer Science 9618 past papers Every paper with its mark scheme — answer online, marked instantly. Open →

Read the full Hardware and Virtual Machines notes free

That's the preview — create a free account to read the rest, plus flashcards and practice questions with instant AI marking. No credit card.

Unlock the full notes free →

More Computer Science topics