What is the meaning of page fault ? I can only understand that page fault
is something about memory.
John wen
19-8-2003
This can be a pretty involved subject. But here goes:
First off: Virtual Memory. This is a portion of your hard drive that OSes
(not just Windows) set aside to use to boost available memory beyond the
physical capacity of RAM. Means you can run more and bigger programs.
To accomplish this, the OS may swap from disk to memory when a chunk of
memory is requested. If the segment is not already in RAM, it is brought
in from Disk. This operation is called a PAGE FAULT.
This is important because the access time form RAM is on the order of
nanoseconds (billionths), Whereas disk access time can be in micro-or even
milliseconds.
Therefore, it is important to minimize disk swapping. This is why having
more RAM boosts performance.
A PAGING OS divides memory into evenly-sized chunks called pages. A
SEGMENTED OS has unevenly sized Chunks, called segments.
Why bother with Virtual memory? Disk space is far cheaper per megabyte than
RAM.
Incidently, this same principle applies at even lower levels. Called L1 and
L2 cache.
There are many different algorithims to determine when, exactly to swap a
peice out of memory, and into disk.
I'm not going there, cause that would take up another page of typing.
Also, read Dan's post. It has more computerese, but it is quite accurate.