1. Data Storage
IGCSE Computer Science (0478)
  • Chapter 6: Automated & Emerging Technologies
  • Data Representation
    • Introduction
    • Why computers use binary (how binary represents data)
    • Number system
      • Introduction
      • Number Conversions
      • Addition of Binary Numbers
      • Logical binary shifts (positive 8-bit integers)
      • Two’s Complement (Signed: Positive and Negative Numbers)
      • Use of the Hexadecimal System
    • Text, Sound and Image
      • Text, Sound and Images
      • File Types
    • Data storage and File compression
      • Measurement of the Size of Computer Memories
      • Lossless and Lossy File Compression
  • Hardware
    • Computer Architecture
      • The CPU & Microprocessors
      • Von Neumann Architecture
      • Fetch-Decode-Execute Cycle (FDE)
      • Characteristics of the CPU
      • CPU Instruction Sets
      • Embedded Systems
    • Input/output devices
      • Input devices
      • Output devices
      • Sensors
    • Data Storage
      • What is Primary Storage?
      • What is Secondary Storage?
      • What is Virtual Memory?
      • What is cloud storage?
    • Network hardware
      • What is a Network Interface Card(NIC)?
      • MAC Addresses & IP Addresses
      • What is a Router?
  1. Data Storage

What is Primary Storage?

Primary storage is memory that is directly accessible by the CPU.
It holds data and instructions that are currently in use by the computer.
Primary Storage = Memory inside the computer that the CPU can read
from and write to directly, without going through secondary storage.

2. Types of Primary Storage#


3. RAM — Random Access Memory#

What is RAM?#

Temporary storage that holds the operating system, running programs,
and data currently in use
.
Volatile — all data is lost when power is switched off.
Contents can be read from and written to by the CPU freely.
Called "random access" because any memory location can be accessed
directly
in the same amount of time.

Key Properties of RAM#

PropertyDetail
Volatile?✅ Yes — contents lost on power off
Read/Write?Both — CPU can read and write freely
SpeedFast
CapacityTypically 4 GB – 64 GB in modern computers
Used forRunning programs, open files, OS

Why does RAM size matter?#

The more RAM a computer has:
The more programs it can run simultaneously.
The faster the system feels (less need to use slower virtual memory).
The more data can be processed without accessing secondary storage.
More RAM = better multitasking and performance.

Types of RAM (for context)#

TypeFull NameDetail
DRAMDynamic RAMNeeds to be refreshed constantly; used for main RAM; cheap
SRAMStatic RAMFaster, no refreshing needed; used for cache; expensive
CIE exams mainly expect you to know RAM vs ROM and RAM vs Cache —
DRAM/SRAM detail is background knowledge.

4. ROM — Read Only Memory#

What is ROM?#

Permanent storage that holds fixed instructions programmed at manufacture.
Non-volatile — contents are retained when power is off.
The CPU can read from ROM but cannot write to it (under normal operation).
Stores the bootstrap program / firmware that runs when the computer starts.

What is stored in ROM?#

ContentDescription
Bootstrap loaderThe startup program that initialises hardware and loads the OS
BIOS / UEFIBasic Input/Output System — checks hardware is working on startup
FirmwareFixed software controlling embedded devices
POST (Power-On Self Test): A check run automatically from ROM every time
the computer starts, verifying that hardware components are functioning correctly.

Key Properties of ROM#

PropertyDetail
Volatile?❌ No — contents retained without power
Read/Write?Read only (by CPU)
SpeedSlower than RAM
CapacityVery small (megabytes)
Used forBIOS, firmware, bootstrap program

5. RAM vs ROM — Direct Comparison#

FeatureRAMROM
Volatile?✅ Yes❌ No
Contents lost on power off?✅ Yes❌ No
Read/Write?Read and WriteRead only
What it storesOS, programs, open filesBIOS, firmware, bootstrap
Size (typical)Gigabytes (GBs)Megabytes (MBs)
SpeedFastSlower
Changed by user?✅ Yes❌ No

6. Cache Memory#

What is Cache?#

A very small, very fast type of memory located on or close to the CPU.
Acts as a buffer between the fast CPU and the slower RAM.
Stores frequently used instructions and data so the CPU can access them
almost instantly without waiting for RAM.
Made from SRAM (faster and more expensive than DRAM used in RAM).

Cache Levels#

LevelLocationSizeSpeed
L1Inside CPU coreSmallest (KB)Fastest
L2Inside CPU (shared)Medium (MB)Fast
L3Outside CPU cores (on chip)Largest (MB)Slightly slower
The CPU checks L1 → L2 → L3 → RAM in order when looking for data.

How Cache Works#

Cache Hit — the requested data is found in cache → fast retrieval.
Cache Miss — data not in cache → must fetch from RAM → slower.

Why is Cache Important?#

The CPU operates much faster than RAM.
Without cache, the CPU would spend most of its time waiting for data from RAM.
Cache dramatically reduces this bottleneck.

7. Virtual Memory#

What is Virtual Memory?#

When RAM is full, the OS uses a portion of secondary storage (hard drive/SSD)
as an extension of RAM.
This area of secondary storage is called the page file or swap space.
The OS moves unused pages of RAM out to the page file to free up space for
currently needed programs.

Virtual Memory — Pros and Cons#

✅ Advantages❌ Disadvantages
Allows more programs to run than RAM alone permitsMuch slower than real RAM
Prevents system from crashing when RAM is fullHeavy use causes thrashing (slow performance)
Cost-effective — uses existing storageSecondary storage is slower than RAM
Thrashing: When the system spends more time swapping data between RAM and
the page file than actually processing — causes very slow, sluggish performance.

8. How Primary Storage Types Work Together#


9. Summary Table — All Primary Storage Types#

TypeVolatile?Read/WriteSpeedSizePurpose
RAM✅ YesBothFastGBsHolds running programs and data
ROM❌ NoRead onlyModerateMBsStores BIOS / firmware
Cache✅ YesBothVery fastKBs–MBsSpeeds up CPU data access
Virtual Memory✅ YesBothVery slowGBsExtends RAM using secondary storage

10. Key Vocabulary#

TermDefinition
Primary StorageMemory directly accessible by the CPU
RAMVolatile read/write memory holding current programs and data
ROMNon-volatile read-only memory storing firmware/BIOS
VolatileMemory that loses its contents when power is removed
Non-volatileMemory that retains contents without power
CacheVery fast small memory storing frequently accessed data near the CPU
Cache HitWhen the CPU finds needed data in cache
Cache MissWhen data is not in cache and must be fetched from RAM
Virtual MemoryUsing secondary storage as an extension of RAM when RAM is full
Page FileThe area of secondary storage used by virtual memory
ThrashingSevere slowdown caused by excessive virtual memory usage
BIOSBasic Input/Output System — firmware stored in ROM
POSTPower-On Self Test — hardware check run from ROM at startup
BootstrapProgram in ROM that loads the operating system on startup

11. Exam Tips ✅#

Volatile vs non-volatile — the single most tested concept:
RAM = volatile, ROM = non-volatile. Never mix these up.
A common exam question: "Why is ROM used to store the BIOS?"
→ Because ROM is non-volatile, so the startup program is not lost
when the computer is switched off.
Cache questions often ask why it improves performance —
answer: it is faster than RAM and stores frequently used data
closer to the CPU, reducing wait time.
Virtual memory questions often ask about disadvantages —
always mention that it is much slower than RAM because
secondary storage access is slow.
Know the order of access speed: Cache > RAM > Virtual Memory.
A common trap: virtual memory is not the same as RAM —
it uses secondary storage and is significantly slower.

Cambridge (CIE) IGCSE Computer Science — 0478 / 0984
Modified at 2026-04-03 09:57:21
Previous
Sensors
Next
What is Secondary Storage?
Built with