Understanding Virtual Memory

Written by Barry Dysert (last updated November 23, 2020)

Virtual memory is the name given to the contiguous address range used by a computer program. For a program to run, its instructions must reside in physical memory. However, when there are several programs running simultaneously or when there's not enough physical memory to encompass the amount of memory needed by a program, the computer uses virtual memory to fulfill the program's needs.

For example, if two programs are running at the same time, each program treats memory as if it's one large contiguous block beginning at address zero and extending as far as necessary. Since each program can't access the memory at physical address zero simultaneously, the computer creates blocks (address ranges) of virtual memory that make it seem to each program that it has all of the computer's memory to itself.

Virtual memory is also used when programs need more memory than physically exists in the computer. The computer uses a process called paging to allow programs to access more memory than physically exists. Through paging, the computer keeps track of what blocks of physical memory are currently available, writes the contents of those blocks to disk, and then reads in from disk the previously written data that the currently executing program needs. By using the disk as a temporary storage medium, many different programs can be running at the same time and accessing large portions of memory without ever having to be concerned with whether the data is physically in memory at the time or needs to be paged in from disk.

 This tip (12623) applies to Windows 7, 8, and 10.

Author Bio

Barry Dysert

Barry has been a computer professional for over 35 years, working in different positions such as technical team leader, project manager, and software developer. He is currently a software engineer with an emphasis on developing custom applications under Microsoft Windows. When not working with Windows or writing Tips, Barry is an amateur writer. His first non-fiction book is titled "A Chronological Commentary of Revelation." ...

MORE FROM BARRY

Creating a System Image

A system image is a snapshot of your system disk as of a certain point in time. Should the need arise, you can restore ...

Discover More

Understanding Jump Lists

Jump lists are great productivity enhancers to Windows 7. By using jump lists, you can easily access frequently used ...

Discover More

Using the Event Viewer to Examine Remote Event Logs

Assuming you have proper access to remote computers, you can examine their event logs from your system without much ...

Discover More
More WindowsTips

Drag to Install Fonts

Installing fonts within Windows 10 is now quicker and easier. By using the new drag-and-drop install method, your fonts ...

Discover More

Over a Hundred Free Windows E-Books

The Internet always provides a huge amount of information, some of it actually of value. Here's a link to a resource that ...

Discover More

Ending a Frozen Program

Sometimes a program can get "stuck," meaning it is no longer responsive and appears to be doing nothing at all. You can ...

Discover More
Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] (all 7 characters, in the sequence shown) in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is 7 + 0?

There are currently no comments for this tip. (Be the first to leave your comment—just use the simple form above!)


Newest Tips