Virtual Memory
Virtual memory is a common part of most operating systems on desktop computers or laptops. It has become so common because it provides a
big benefit for users at a very low cost. It’s a kind of memory which
resides in secondary memory storage device.
Most computers today have something like 32 or 64 megabytes of RAM available for the CPU to use. Unfortunately, that amount
of RAM is not enough to run all of the programs that most users expect to run
at once.
Working of virtual memory:
If you load the operating system, an e-mail program, a Web browser and
word processor into RAM simultaneously, 32 megabytes is not enough to hold it
all. If there were no such thing as virtual memory, then once you filled up the
available RAM your computer would have to say, "Sorry, you cannot load any
more applications. Please close another application to load a new one."
With virtual memory, what the computer can do is look at RAM for areas that
have not been used recently and copy them onto the hard disk.
This frees up space in RAM to load the new
application. Because this copying happens automatically, you don't even
know it is happening, and it makes your computer feel like is has unlimited RAM
space even though it only has 32 megabytes installed. Because hard disk space
is so much cheaper than RAM chips, it also has a nice economic benefit.
Basic terminologies:
Virtual Memory:
The memory available in the secondary storage devices are known as virtual memory.
Physical Memory:
The memory available in the main memory(RAM) devices are known as physical memory.
Physical Address:
The address of memory locations in main memory(RAM) is called as Physical Address.
Virtual Address:
The address of memory locations in secondary storage devices
such as magnetic tapes, magnetic devices are known as Virtual Address.
Page Table:
It
holds the address of memory locations in which the datas of main memory
are stored s that when CPU needs those files it can refer the memory
mapping table or Page Table.
Trashing:
When it is not the case,
the operating system has to constantly swap information back and forth between
RAM and the hard disk. This is called thrashing, and it can make
your computer feel incredibly slow.
Page File:
The area of the hard disk
that stores the RAM image is called a page
file. It holds pages of RAM on the hard disk, and the
operating system moves data back and forth between the page file and RAM. On a
Windows machine, page files have a .SWP extension.
Reference
Wikipedia
No comments:
Post a Comment