Your computer has a trick. It makes its memory look very big. It uses extra space to help out. This helps your apps run well. It makes things easy for you. Can you see how it works?
Your computer has a clever trick. It makes its memory look very big. It uses extra space to help out. This helps your apps run well. It also keeps them safe from each other. This happens because the computer uses a special part to help. It maps out where things go. This makes work much easier for the computer. It can even run big programs on small machines. This is a very helpful way to work.
Your computer has a clever trick to act big. It uses a way called virtual memory. This makes the computer's memory look much larger than it really is.
Computers have real memory, often called RAM. But programs often need more space than the RAM can hold. Virtual memory solves this. It uses a part of the computer to map virtual addresses to real ones. A virtual address is a fake location used by a program. The hardware that does this work is the memory management unit, or MMU.
This works through a set of steps called paging. The computer divides memory into small blocks called pages. Most pages are 4 kilobytes in size. The system uses page tables to keep track of these blocks. If a program needs a page not in the RAM, a page fault happens. This tells the computer to find that data on the disk.
This trick helps in many ways. It lets programs run in their own safe space. It also lets many programs use the same tools at once. The first computer to use true virtual memory was the Atlas Computer. It was built at the University of Manchester in 1962.
Virtual memory is a clever way that computers work. It creates an illusion for users. It makes the computer seem to have a very large amount of memory. This is helpful because programs often need more space than the real memory can hold. This system uses a technique to map virtual addresses to physical ones. A virtual address is a fake location used by a program. The operating system manages these spaces. It uses both hardware and software to do this job.
How does this trick work step by step? The computer divides the virtual memory into small blocks called pages. Most pages are at least 4 kilobytes in size. The system uses page tables to keep track of these blocks. These tables translate the fake addresses into real physical addresses. The hardware that handles this is the memory management unit, or MMU. If a program asks for a page not in the real memory, a page fault happens. This tells the computer to find that data on the disk storage.
This idea has a long history. In the 1950s and 1960s, computer memory was very expensive. Programmers had to do a hard job called overlaying to manage space. The first computer to use true virtual memory was the Atlas Computer. It was built at the University of Manchester. The Atlas was commissioned in 1962. It used 16,384 words of primary core memory. It also used 98,304 words of secondary drum memory to help.
Many people helped develop these ideas. Robert S. Barton suggested automatic memory allocation in 1958. He worked at Shell Research. Later, the Burroughs Corporation released the B5000 in 1964. This was the first commercial computer with virtual memory. IBM also played a big role in this history. They developed the concept of hypervisors for their systems. By 1969, experts showed that virtual memory worked better than manual systems. This ended the big debate over using it for commercial computers.
Virtual memory connects to many things you use today. Most modern operating systems use it to keep programs safe. It provides memory isolation so one program cannot easily mess with another. It also lets different programs share the same tools or libraries. This makes using a computer much more efficient. Even your smartphone and laptop use these same basic ideas. It allows many apps to run at once without running out of space.
Virtual memory, also known as virtual storage, is a sophisticated memory management technique used in modern computing. It provides an idealized abstraction of the actual storage resources available on a machine. This process creates a powerful illusion for users, making it seem as if the computer has a very large amount of main memory. In reality, the system is combining active RAM with inactive memory stored on secondary storage, such as a disk. This allows a computer to reference more memory than is physically present in the hardware.
The mechanism relies on a precise mapping process between different types of addresses. A computer program uses virtual addresses, which are essentially placeholders. The operating system, working with specialized hardware, maps these into physical addresses in the actual computer memory. This translation is handled by a component in the CPU called the Memory Management Unit, or MMU. The MMU automatically converts the virtual addresses used by a process into the real physical locations. This allows the main storage to appear to a task as a single, contiguous collection of segments.
Most modern implementations use a specific method called paging to organize this space. In paged virtual memory, the virtual address space is divided into small, contiguous blocks known as pages. On contemporary systems, these pages are usually at least 4 kilobytes in size. To keep track of everything, the system uses page tables. Each entry in a page table contains a flag indicating if a page is currently in the real memory. If the hardware looks for a page and finds it is not in the real memory, it triggers a page fault exception. This exception tells the operating system's paging supervisor to retrieve the necessary data from secondary storage.
There are several ways these tables can be organized to manage different tasks. A system might use one single page table for the entire system, or it may provide separate page tables for every individual process. Some systems use segment tables, or even complex trees of region tables, to manage these address spaces. When each process runs in its own dedicated address space, it appears to have sole access to the virtual memory. This provides significant benefits, such as memory isolation, which increases security by preventing one process from interfering with another. It also allows different processes to share memory used by common libraries.
The history of virtual memory is rooted in the high cost of computer memory during the 1950s and 1960s. During this era, programmers had to manually manage data transfers using a technique called overlaying. The first true virtual memory system was implemented at the University of Manchester for the Atlas Computer. The Atlas was commissioned in 1962, though paging prototypes existed by 1959. It mapped virtual addresses onto 16,384 words of primary core memory and 98,304 words of secondary drum memory. This innovation solved the difficult problem of scheduling data transfers and recompiling programs for different memory sizes.
Many researchers contributed to the evolution of these concepts. In 1958, Robert S. Barton suggested that memory should be allocated automatically to replace manual overlays. By 1964, the Burroughs Corporation released the B5000, which was the first commercial computer to feature virtual memory. IBM also made major contributions, developing hypervisors and the Virtual Machine Facility/370. By 1969, the debate over whether virtual memory was effective for commercial use ended. An IBM research team led by David Sayre proved that their virtual memory overlay system worked better than manual systems.
While virtual memory is standard today, it is not used in every type of computing. Embedded systems or special-purpose computers often skip virtual memory to ensure fast and consistent response times. Virtual memory can cause unpredictable delays if a system must wait to read data from secondary memory. Furthermore, the hardware required for address translation, like the MMU, takes up significant space on a chip. This is why some smaller embedded chips do not include the necessary hardware. However, for most general-purpose computers, the ability to run large software on limited physical memory makes virtual memory an essential tool.
🖼️ Images & Media (2)
More to explore
✨ What else?
Related topics you might enjoy
🔬 Go deeper
More advanced topics to explore
🪜 Step back
Simpler topics to build understanding
What is Nepedia?
A free, ad-free encyclopedia for children. Every article is written at five reading levels, so the same page works for a five-year-old and a fifteen-year-old — use the level switcher above to see this one change. No account needed to read.