64 bit memory usage

Heather Brown heather at dejaviewphoto.com
Thu Dec 9 08:18:25 EST 2010


On 01/-10/-28163 02:59 PM, Dennis Lee Bieber wrote:
> On Wed, 8 Dec 2010 14:44:30 +0000, Rob Randall<rob.randall2 at gmail.com>
> declaimed the following in gmane.comp.python.general:
>
>> I am trying to understand how much memory is available to a 64 bit python
>> process running under Windows XP 64 bit.
>>
>> When I run tests just creating a series of large dictionaries containing
>> string keys and float values I do not seem to be able to grow the process
>> beyond the amount of RAM present.
>>
>> For example, on a box with 2GB RAM and 3 GB pagefile the process stalls at
>> around 2GB.
>>
>> On another machine with 16GB RAM and 24GB pagefile the process stalls at
>> 16GB.
>>
>
> 	Probably need to ask M$, but I can understand this behavior as a
> hypothetical...
>
> 	The page file can be larger than physical memory because it contains
> memory "images" for multiple processes. However, all those "images" have
> to map into the physically addressable memory -- so a process is likely
> limited to physical memory, but you can have multiple processes adding
> up to physical + pagefile in total.

It's plausible that MS did that, but it's not reasonable.  An 
application's entire data space is never in physical memory, except for 
trivial applications.  When new pages are needed, old ones are swapped 
out, in an LRU manner.  If the application is the only thing "running," 
it'll eventually be mapped into most of physical memory, but even then, 
the swapper keeps some back.

The limit in 32bit world was 4gb, not whatever RAM happened to be in the 
machine.  That limit came from the address space (or linear space, as MS 
calls it), not from the amount of RAM.  It's only in recent years that 
those numbers have tended to be close.

DaveA



More information about the Python-list mailing list