Questions on O/S Memory Managment

anthrax

Senior member
Feb 8, 2000
695
3
81
I want to ask a few questions about memory managment is modern O/S. Is the following correct?

For a given process.

Non-Paged Memory = the memory used by the process that will always be in RAM?
Paged Memory = the memory that is in RAM that can be moved into the page file?
Working Set = memory used recently by recently?
Virtual Size = The amount of (RAM+page file) memory allocated to a process?

Based on the above. Is the following correct?

The total physical + page file (RAM + page file) > Total Virtual size of all processesin a system. ?

What happens if "user process" request more memory when the "total virtual size" = "pagefile size + RAM"?

If a "device driver " request more memory when the "total virtual size" = "pagefile size + RAM" ? what would happen?
 

anthrax

Senior member
Feb 8, 2000
695
3
81
Originally posted by: Peter
OK, who switched Highly Technical onto The Homework Channel again? ;)

Its only you who is implying it. It not even term time at the moemnt and these aren't homework question.

Anyways, I am trying to figure out the optimal page file size of a 64bit O/S with 4GB of RAM, and hence, the default automatic managed wont' allocated more than 4GB..

On a modern O/S , shouldn't the usage in MB of "page file + physical memory" equal to total virtual size of memory allocated to all process on a system?

Would using the sizing the page file based on the "total virtual size" of all processes minus physical memory be a good way of sizing it ?

 

gsellis

Diamond Member
Dec 4, 2003
6,061
0
0
The answer is posted about once a week in the OS section. Let Windows manage it.

And no. Virtual size has nothing to do with the page file size if you are tuning it by sight from the performance page in task manager. Applications can request more memory than they actually use. Often, poorly written apps request way more memory than they will use. Until they try to write to that memory, it remains as virtual memory that is not allocated. It is the page fault of trying to write to that memory location that causes the memory manager to create that page of memory.

Just keep page file initial size to whatever the default is. In XP 32, it was 1.5x of physical. If you repeatedly cause the file to go larger (even in 64-bit), get more memory. If you do that in 32bit and have 4GB, go to 64bit and get more memory (and probably more processors). Using the pagefile is not a bad thing if there are lots of processes "standing by" that are not frequently used. If there are lots of active apps and they must be pulled from the pagefile frequently, you need to determine what is using the memory and how to load balance it or replace that application.