← IGCSE Computer Science Paper 1

How virtual memory is created

Part of secondary storage that the operating system sets aside to hold pages of data when RAM is full. The OS manages this space and can make it bigger when more is needed.

Understanding How virtual memory is created in IGCSE Computer Science Paper 1

What it does: The OS is in charge of the reserved space, not the user or the hardware alone, so the OS controls the page file. Virtual memory is not new hardware. The operating system reserves space on the secondary storage (e.g. HDD or SSD) and uses it to hold pages of data. The reserved space is on the drive (HDD or SSD), not in ROM. ROM stores the start-up instructions and is not used for this. The mistake is giving the user the job of managing pages. The OS decides what to move and can grow the space when needed.

Common mistakes: Virtual memory is space reserved on the drive (secondary storage), not in RAM. It should be vmem ← drive.reserved. Virtual memory is created on secondary storage such as the HDD. ROM is primary storage and cannot be used for it. It should be vmem_location ← HDD.

Class: _____________________  ·  Name: _____________________  ·  Date: _________

Free printable worksheet with full answer key — or add this module to a class and your students practise it interactively.

This module's key terms are also in a printable crossword (Modules 314–324) and word search (Modules 304–324).

Take this worksheet further — free with Cloodit

Each concept is reinforced from every angle — learned, then applied, then tested.

Learning
Duo
How is virtual memory created?
The OS sets aside part of secondary storageThe OS adds extra RAM chips to the computer
Matches
Virtual memory is a second RAM chip added to the motherboard
↓
Virtual memory is not extra RAM hardware. It is space on secondary storage (such as an HDD or SSD) that the OS sets aside.
Applying
Meanings
Term
Virtual memory
Meaning
Part of secondary storage that the operating system sets aside to hold pages of data when RAM is full. The OS manages this space and can make it bigger when more is needed.
Practice
IF RAM_full THEN
Testing
Gaps
OS moves pages to
Check Answer
Spots
3 OS.reserve(drive, 4)
4 vmem ← RAM.reserved

Cloodit turns curriculum-aligned coding content into journeys students work through one biome at a time.

The 'Butterfly' badge — Branch Hopper, one of Cloodit's 106 collectible badges
Students earn collectable badges

Over 100 of them, across seven natural biomes.

Study Buddy
Students build a real study resource

Turns their work into revision material ready for Flash Cards and Exam study.

Diamond Dash — one of Cloodit's live, competitive Sprint games
Students lock in with Sprints

Live, competitive practice for the start of the lesson or a teacher-led lesson finisher.

A Cloodit certificate of achievement, ready to personalise and print
Custom printable certificates

Honour your top performers, or encourage a student who's trying hard — ready to print in seconds.

Quick Questions

1. How is virtual memory created?
A. The OS sets aside part of secondary storage ✓
B. The OS adds extra RAM chips to the computer
Virtual memory is not new hardware. The operating system reserves space on the secondary storage (e.g. HDD or SSD) and uses it to hold pages of data.
2. Where does virtual memory physically exist?
A. Inside the ROM chip
B. On the secondary storage drive ✓
The reserved space is on the drive (HDD or SSD), not in ROM. ROM stores the start-up instructions and is not used for this.
3. Which part of the computer sets up and manages virtual memory?
A. The monitor
B. The operating system ✓
The operating system (OS) reserves the space and decides which pages are stored there. Output devices like a monitor have no role.
4. What does virtual memory hold?
A. Pages of data moved out of RAM ✓
B. The BIOS start-up program
When RAM is full, the OS moves pages of data to the reserved space on the drive. The start-up program is kept in ROM.
5. What can the OS do if the virtual memory space becomes too small?
A. Make it bigger by reserving more drive space ✓
B. Nothing, the size is fixed forever
The OS can grow the virtual memory when more is needed, as long as there is free space on the drive.

Match the Pairs

Virtual memory → Part of secondary storage that the operating system sets aside to hold pages of data when RAM is full
Page file (swap space) → The reserved area on the drive where the operating system keeps pages of data that do not fit in RAM
The operating system manages virtual memory, deciding which pages go to the drive and which come back to RAM → OS controls the page file
Virtual memory can grow when more is needed, because the OS can make the reserved space on the drive bigger → page file size: 2 GB -> 4 GB
Virtual memory is a second RAM chip added to the motherboard → Virtual memory is not extra RAM hardware. It is space on secondary storage (such as an HDD or SSD) that the OS sets aside.
The user must manually move each page of data to virtual memory → The operating system creates and manages virtual memory automatically. The user does not move pages by hand.

Key Term

Virtual memory
Part of secondary storage that the operating system sets aside to hold pages of data when RAM is full. The OS manages this space and can make it bigger when more is needed.

Fill in the Blanks

1. IF RAM is full THEN OS moves pages to virtual memory ENDIF
Hint: Type the term for the space the OS creates to hold pages when RAM is full
2. Virtual memory uses secondary storage
Hint: Type the kind of storage that part of is set aside to create it
3. IF virtual memory is full THEN OS increases the reserved space ENDIF
Hint: Type the verb for what the OS does to the reserved space when more is needed
4. Managed by the operating system
Hint: Type the software that sets aside and controls the reserved space
5. Data in virtual memory is stored in pages
Hint: Type the name for the blocks of data held in the reserved space

Spot the Error

Question 1
A RAM_full ← TRUE
B IF RAM_full = TRUE THEN
C OS.reserve(drive, 4)
D vmem ← RAM.reserved
E ENDIF
Line D — Virtual memory is space reserved on the drive (secondary storage), not in RAM. It should be vmem ← drive.reserved.
Question 2
A vmem_location ← ROM
B vmem_manager ← OS
C OUTPUT vmem_location
Line A — Virtual memory is created on secondary storage such as the HDD. ROM is primary storage and cannot be used for it. It should be vmem_location ← HDD.
Question 3
A vmem_size ← 4
B vmem_manager ← RAM
C OUTPUT vmem_manager
Line B — The operating system sets up and manages virtual memory. RAM is just memory and does not manage anything. It should be vmem_manager ← OS.
Question 4
A IF pages > vmem_size THEN
B vmem_size ← vmem_size - 2
C ENDIF
Line B — When more virtual memory is needed, the OS makes the reserved space bigger. It should add to the size (+ 2), not subtract.
Question 5
A WHILE vmem_size > pages_needed
B OS.enlarge(vmem_size)
C ENDWHILE
Line A — The OS should keep enlarging virtual memory while it is smaller than the space needed. The condition should use < not >.

Student with a class code? Join your class →