RAM, ROM and virtual memory Cambridge IGCSE Computer Science (9–1) revision

Not started

Learn it

In plain words

Primary storage is memory that the CPU can reach directly. There are two kinds, and they are opposites: one forgets everything when the power goes off but can be changed freely, and the other keeps its contents for good but cannot be changed.

When the first kind fills up, the computer has a trick: it borrows space from the hard disk and pretends that is memory too.

6 things to know

  1. Primary storage is directly accessed by the CPU.
  2. RAM (random access memory) is volatile: it loses its contents when the power is switched off. It can be read from and written to. It holds the programs and data that are in use at the moment.
  3. ROM (read only memory) is non-volatile: it keeps its contents with no power. It can only be read. It holds the start-up instructions for the computer.
  4. A computer needs both: ROM to start it up, and RAM to hold what it is working on.
  5. Virtual memory is part of secondary storage that is used as if it were RAM, when RAM is full.
  6. Pages of data that are not needed at that moment are moved from RAM to virtual memory, and moved back when they are needed. This allows more programs to be open than RAM alone could hold.

Worked example

A user has many programs open and the computer becomes slow. Explain what is happening.

  1. RAM is full, so the computer is using virtual memory.
  2. Pages of data that are not in use are moved from RAM to secondary storage to make room.
  3. When they are needed again they are moved back. Secondary storage is much slower than RAM, so all this swapping slows the computer down.

Tips and tricks

  • Volatile means "loses its data without power". It does not mean dangerous or unstable.
  • Virtual memory is not in RAM. It is space on the hard disk or solid-state drive that is used as if it were RAM.
5 questions, about 2 minutes.

It lands in your notebook with its questions as flashcards.

RAM, ROM and virtual memory: 5 questions and answers

These are the quiz’s questions. Do the quiz first, then come back here for the ones that got you.

  1. What does volatile mean?
    • can be read but not written
    • loses its contents when the power is switched off (the answer)
    • very fast
    • stored on a disk

    RAM is volatile. ROM is not.

  2. What is held in RAM?
    • the start-up instructions
    • the programs and data that are in use (the answer)
    • every file the user has saved
    • nothing

    When the power goes, it is all lost.

  3. What is held in ROM?
    • the instructions needed to start the computer (the answer)
    • the documents that are open
    • the user's photographs
    • the web browser's history

    They must be there the moment the computer is switched on.

  4. What is virtual memory?
    • extra RAM chips
    • part of secondary storage used as if it were RAM (the answer)
    • memory in the cloud
    • another name for cache

    It is used when RAM is full.

  5. Why does heavy use of virtual memory make a computer slower?
    • It deletes programs.
    • Secondary storage is slower to access than RAM. (the answer)
    • It uses more electricity.
    • It makes the screen dimmer.

    Moving pages in and out takes time.

Still stuck on this one?Ask in the Papermunch Discord, or help someone else who is. Discord is for ages 13 and up.Join the server

Things you can type

Or go straight to

Or browse a shelf