Question

All, Forgive me I'm a newbie for the Windows Driver Development, After read this document from WDK, I have something I didn't understand.

The document says

The range of virtual addresses that is available to a process is called the virtual address space for the process. Each user-mode process has its own private virtual address space. For a 32-bit process, the virtual address space is usually the 2-gigabyte range 0x00000000 through 0x7FFFFFFF. For a 64-bit process, the virtual address space is the 8-terabyte range 0x000'00000000 through 0x7FF'FFFFFFFF. A range of virtual addresses is sometimes called a range of virtual memory.

My questions about it are :

Supposed there is a computer which has 8-gigabyte memory bank.

  1. Is all the virtual address space actully assigned from this 8-gigabyte memory?
  2. If one process need to assigned 2g virtual address space, Can I say that if there are 4 processes running in the system. they totally need 8-gigabyte memory ? If the answer is Yes, Does it means in thes computer the max number of processes can be ran is 4?

I don't know if I misunderstand something. please correct me. thanks a lot.

Was it helpful?

Solution

1) No the virtual addresss space is independent of the physical address space. There is a mapping from virtual to physical addresses that is managed by the OS. So the virtual addresses that are assigned to a process do not depend on the physical memory in the system.

2) No, again the virtual address is separate from physical addresses. Also Windows supports virtual memory, so even if you don't have enough physical memory to keep all the processes active memory can be paged out to disk.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top