GCSE · Computer Science · Eduqas · Spec C500QS

Virtual memory

Open too many programs and a computer can slow to a crawl. Virtual memory keeps it going when RAM is full, and charges you in speed.

Computer Science · Memory

Make the swap decisions

You are deciding what the computer does each time the CPU needs data. Call each arrow before it is shown. The programs here are made-up examples.

Step 1. The CPU is about to need some data. Your job is to call each arrow before it appears.

Step 1 of 7Called right: 0 of 2

Pick a situation, then press Next. Stop at each diamond and call it.

Side by side

RAM (main memory)vsVirtual memory

Four differences that explain why swapping exists and why it costs speed.

Focus

Where it is

RAM (main memory)

Main memory

Virtual memory

An area of secondary storage (for example an HDD or SSD)

The insight

Same job, different place: the computer uses that storage area as if it were extra RAM.

When it is used

RAM (main memory)

Holds the programs and data currently in use

Virtual memory

Used when RAM is full

Can the CPU work on data held here directly?

RAM (main memory)

Yes

Virtual memory

No: it has to be swapped back in to RAM first

Read and write speed

RAM (main memory)

Much faster

Virtual memory

Much slower

Check your gut

What does virtual memory actually do?

A friend's computer is running lots of programs and RAM is full. They ask what virtual memory is doing for them.

Which idea is closest to what you think right now?
How sure are you?

Why it crawls

?

Reason it through

Why does a computer that relies heavily on virtual memory run more slowly?

Link 1 of 4

First link · your turn

Swapped-out data sits on secondary storage. How fast can the computer read and write it compared with RAM?

2
Locked — reveal the link above first
3
Locked — reveal the link above first
4
Locked — reveal the link above first

Predict, then check

One technician, one upgrade, one outcome.

A computer is slow because it keeps swapping data to virtual memory. A technician fits more RAM. What is the most likely result?

Write it yourself

Describe it, then explain it

Describe how virtual memory is used when RAM is full, and explain why a computer with more RAM may run faster. [5 marks]

0 words · your answer stays on this page and is not sent anywhere.

Exam line: Cover both halves: what happens to data when RAM is full, and why more RAM may help.

WHAT YOU'VE LEARNED

A quick recap of today's lesson.

When RAM runs out, a computer borrows some secondary storage. It pays for that in speed.

What you need to know

  • Virtual memory is an area of secondary storage, like an HDD or SSD, used as if it were extra RAM.
  • The computer uses it when RAM is full, meaning there isn't room for everything currently in use.
  • Have a goSam says: 'My laptop still has loads of empty RAM, so it must be using virtual memory right now.' What would you tell Sam?

    Probably not: virtual memory is used when RAM is full.

    It comes into play when there isn't enough RAM for everything in use, so spare RAM means there is no need for it.

  • Swapping out means moving data and instructions not needed right now from RAM into virtual memory, freeing space.
  • Needed again? The data is swapped back in to RAM, because the CPU works directly only with data held in main memory.
  • Have a goRAM is full and you open one more program. Which move has to happen first: RAM to virtual memory, or virtual memory to RAM?

    RAM to virtual memory: something not needed now is swapped out.

    Space has to be freed in RAM before the data that is needed now can be held there. Swapping back in is for data coming back.

  • The payoff: the computer can run more programs, or larger programs, at once than its RAM alone could hold.
  • The cost: virtual memory is much slower than RAM, because secondary storage has much slower read and write speeds.
  • Have a goTwo computers run the same programs. One has enough RAM for everything. On the other, RAM is full and it uses virtual memory. Which is likely to be slower, and why?

    The one using virtual memory.

    Its swapped data sits in secondary storage, which has much slower read and write speeds than RAM.

  • Relying heavily on virtual memory makes the computer slower, because swapping data takes time.
  • If data is swapped in and out very often, the computer spends more time swapping than processing. That is disk thrashing.
  • Adding more RAM means virtual memory is needed less often, so less swapping happens and performance can improve.

The big picture

Virtual memory is an area of secondary storage that the computer uses as if it were extra RAM. It is used when RAM is full: data not needed right now is swapped out, and swapped back in when it is needed again, because the CPU works directly only with main memory. It lets more or larger programs run at once, but it is much slower than RAM, and heavy use can lead to disk thrashing. More RAM means less swapping.

Key points

1Virtual memory is secondary storage used as if it were extra RAM. It is not extra RAM chips.
2Swap out: data not needed now moves from RAM to virtual memory. Swap in: data needed again moves back to RAM.
3The CPU works directly only with data in main memory, so needed data must be in RAM.
4Virtual memory lets more or larger programs run at once, but it is much slower than RAM.
5More RAM means less swapping, and performance can improve.

Worked example

Problem

Made-up example: RAM is full, holding programs P, Q and R. You are using P. Q and R are open but not needed right now. You open program S. What does the computer do? Then what happens when you click back to R?

⚠ Watch out

Thinking virtual memory is extra RAM that makes the computer faster. It is an area of secondary storage, used when RAM is full, and it is much slower than RAM.

🧠

Memory hook

Picture a small desk (RAM) and a filing cabinet across the room (virtual memory). You can only work on papers on the desk. Desk full? File away what you're not using, and fetch papers back when needed. The cabinet isn't a bigger desk.

✓

Check yourself

Say it out loud in order: what happens, step by step, when the CPU needs data that is sitting in virtual memory and RAM is full?

Flashcards

(11)
What is virtual memory?
An area of secondary storage that the computer uses as if it were extra main memory (RAM).
Which kinds of storage can virtual memory be an area of?
Secondary storage, for example a hard disk drive (HDD) or a solid state drive (SSD).
When is virtual memory used?
When RAM is full: there isn't enough RAM to hold all the programs and data currently in use.
Which data gets swapped out, and what does that achieve?
Data and instructions not currently needed move from RAM into virtual memory, freeing space for the data that is needed now.
When does data come back from virtual memory?
When it is needed again: it is swapped back in to RAM.
Why can't the CPU work on data while it is in virtual memory?
The CPU works directly only with data and instructions held in main memory.
What does virtual memory let a computer do?
Run more programs, or larger programs, at the same time than its RAM alone could hold.
Why is virtual memory much slower than RAM?
Secondary storage has much slower read and write (access) speeds than RAM.
What is disk thrashing?
Data swapped in and out so often that the computer spends more time swapping than processing.
How does adding more RAM help?
Virtual memory is needed less often, so less swapping takes place and performance can improve.
True or false: virtual memory is extra RAM that speeds a computer up.
False. It is secondary storage used as if it were RAM, and it is much slower than RAM.

Tap any card to flip it, or use Study as deck to go through them one at a time. In the full lesson these run as a spaced-repetition deck — you rate each card Hard, Good or Easy and the tricky ones keep coming back until they stick.

Learning with Lightbulb is opening soon

You can use this lesson now. Join the waitlist and we'll let you know when the full Lightbulb experience is ready.

Keep me posted

More Eduqas GCSE Computer Science topics

See the full Eduqas Computer Science curriculum →

How this lesson was checked. This Eduqas GCSE Computer Science (specification C500QS)lesson was published through Lightbulb Learning's human-designed editorial process — the educational standards, accuracy rules and publication checks it must pass were authored and approved by Philip Halpin. It passed subject-specific assessment, automated educational checks and technical publication verification before going live (publication checks completed 15 November 2026). Published pages are monitored, human spot-checking is ongoing across the lesson library, and anything found wrong is corrected or withdrawn. How our lessons are made and checked. Spotted a mistake? Email hello@lightbulblearning.co and we'll review it.