The Virtual Memory Manager Computer Science Essay

Published: Last Edited:

This essay has been submitted by a student. This is not an example of the work written by our professional essay writers.


Everyone wants a high-end PC with high speed, which allows you to start up several programs simultaneously, without even waiting for a single second. Up to some level, adding Random Access Memory (RAM) make the PC work faster. RAM is highly significant due to the component of Operating System that is known as VMM (Virtual Memory Manager). While we run the software applications on our computer systems, these programs take a lot of storage space based upon their size in terms of LOC (Lines of Code). Some program may take 1MB of storage space, while the others may consume as much as 40 MB of space in order to be executed. Beside all these programs, the OS itself consumes a lot of memory (Hay and Nance, 2008).

Physical Memory vs. Virtual Memory:

Physical storage space and virtual storage space are two forms of storage space that are used to store information in a PC. Physical storage space represents chips for example RAM (Random Access Memory) and storage space devices for example hard drives that are used to store information. Virtual storage space is a storage space that is usually created by OS when the PC does not have sufficient physical storage space to run an application program. Virtual storage space is created by combining the hard drive disk space with RAM. Virtual storage space allows running large applications quicker when the RAM is not sufficient.

Physical Memory:

As already mentioned, physical storage space represents the RAM and the hard drives in the PC that are used to store information. In a PC, the OS, software application programs and currently used information are stored in the RAM, so that they can be accessed speedily by the processor. RAM can be accessed quicker than the other storage space devices CD-ROM and hard drive. But the information in the RAM subsists only while the PC is running. When the electrical power is turned off, all the information in the RAM is lost. The OS and other information are loaded again from the hard drive to the RAM when the PC is switched on. Hard drive is a non-volatile storage space (a storage space that keeps information even when it is not connected to the power) that is used to store the precious information in a PC. It is made up of circular drives known as platters that stores magnetic information. Information is read and written to and from the platters by using read/ write heads.

Virtual Memory:

Virtual storage space is used when the PC lacks the RAM area for running a software program. Virtual storage space combines the hard drive space with the RAM space (Soltesz et al, 2007). When the PC does not have sufficient RAM space in order to run an application, the virtual storage space transfers information from the RAM to a paging data file, which frees up the area in the RAM. A part of the hard drive is used to keep the page data file. This transferring procedure is performed really quickly so that the user apparently does not feel any difference. Virtual storage space can hold a comprehensive block of information while the portion that is presently running resides on the RAM. Hence the virtual storage space allows the OS to execute various software applications at the same time consequently improving the level of multi-programming. While improving the size of software applications that can be executed, virtual storage space delivers cost benefits due to the fact that hard drive storage space is less expensive as compared to the RAM.

Difference between Physical Memory and Virtual Memory:

Physical storage space is the storage on the RAM chips in the personal computer. This storage can be included or eliminated, and performs very fast. The issue is that it is finite: once you run out of memory, you run out.

Virtual storage space is the hard drive being utilized in the same way as physical storage space. Virtual storage space can be as huge as the residual available free hard disk space on the computer, but it is slow to access and not as beneficial as the physical storage space.

Advantages of Virtual Memory:

Virtual storage space can be saved in RAM, but it can be easily swapped out to hard drive when another program requires the physical RAM. This is one of the important functions. Once it is on hard drive, other procedures can use the computer’s RAM to faster their processing. When required, the storage space swapped to hard drive can be reloaded and some other program can be shifted there in its place.

Many of modern PC systems have more RAM than they actually require. Therefore, the process of swapping is reduced to a great extent (it can harm performance). But it is excellent to have the swap choice when required.

Virtual storage space allows you to simultaneously run 10 x 1 GB programs in a 2 GB PC.

Virtual Memory Address Translation:

To convert the virtual address into a physical address, the Central Processing Unit (CPU) considers the page number as an index into the page table. In case the page is resident, the physical frame address in the page table is normally concatenated in front of the offset in order to create the physical address.


Figure : Virtual Memory Address Translation

Translation of 32-bit and 64-bit Virtual Address to Physical Address:

There are various virtual storage space parameters that are set by the system designer.

Maximum Physical Address Space

The amount of physical memory that the PC can support identified the number of bits required to address the actual memory. The size of a physical address is usually log base 2 of this value.

Maximum Virtual Address Space

The size of an application program’s address is identified by the maximum size of its virtual address space. The number of bits in the virtual address is usually the log base 2 of this value.

Size of a Page

This is the size of a physical memory frame and virtual memory page. It is always represented in a power of 2.


Hence, the PC needs to have more memory which will be created by the Virtual Memory Manager. The VMM checks the RAM and discovers the segments that are not presently in use. It places these RAM segments in the swapping file on the hard disk drive (Werstein et al, 2007). In case you have opened the Word document and do not use it for about half an hour, the VMM will move all the storage space of Word document out of the hard drive. This process is known as swapping out. When you again click on the Word document, the VMM will swap in all the bytes of the document from the hard drive. This process of swap in and swap out may cause the delays because hard drive is slow as compared to the RAM.