(This is the older material - click here - for current specification content)

6. Virtual Memory

Primary memory has a limit i.e. how many RAM chips you have in the computer. But there is a trick that the memory manager can use to fool the operating system into thinking that there is more primary memory than is actually physically present. This trick is called virtual memory.

As has been mentioned, all executing software needs to run in primary memory and is temporarily stored in segments.

When the computer is running short of physical primary memory e.g. too many applications open, the memory manager has a choice. It can either shut down applications (very inconvenient) or it can try and scrounge some more memory from somewhere else. This is where virtual memory comes in.virtual memory

The memory manager will begin to use parts of secondary memory such as the hard disk or a Flash USB drive as primary memory.

Pages that have not been used for a while will be stored on the hard disk as virtual memory. This means that the pages are still available but will take some time to restore into primary memory.

The benefit of doing this is to allow more applications to run than would be physically possible if you were only using RAM.

While virtual memory will allow more applications to be open, it should be appreciated that a physical hard disk is being used and so applications will run far slower than if they were stored completely in RAM.

In an examination question it is essential to remember the following:

Virtual memory is making use of secondary memory (backing store) as if it were main memory. Virtual memory acts as an extended form of primary memory.

Have a look at the movie clip below to see this in action

Operation of virtual memory

 

Challenge see if you can find out one extra fact on this topic that we haven't already told you

Click on this link: Virtual Memory

 

 

 

Copyright © www.teach-ict.com