Memory allocation problem

language_fan foo at bar.com.invalid
Tue Aug 11 05:58:59 PDT 2009


Mon, 10 Aug 2009 14:15:41 -0400, bearophile thusly wrote:

> Steven Schveighoffer:
>> My point is, don't count on having 2GB of usable space even if you
>> physically have 2GB of RAM, it may not be the case.
> 
> I was looking for using 1.8 GB not 2.
> 
> 
>>Better off to not desire than to complain about edge conditions based on
>>hardware limitations.<
> 
> With C I can use up to about 1.94 GB of RAM, I don't think 1.8 is so on
> the edge :-) I think this is a bug of DMD, it's not a problem of my PC.

You can also try to buy another 2 GB of RAM and see if the problem 
persists. On a machine with 4 GB of physical RAM, a 32-bit OS usually can 
see ~3..3.5 GB free. I even think that if your OS supports page files, it 
doesn't matter if the memory is on chip or disk - if the memory is split 
3/1 for processes and kernel, you should be able to allocate 2 GB easily.



More information about the Digitalmars-d mailing list