Re: Theoretical limit to memory allocation
Re: Theoretical limit to memory allocation
- Subject: Re: Theoretical limit to memory allocation
- From: Chris Kane <email@hidden>
- Date: Tue, 2 Oct 2001 15:16:55 -0700
On Tuesday, October 2, 2001, at 09:01 AM, Erik M. Buck wrote:
Is the following statement true ?
On Mac OS-X, the theoretical limit to the amount of memory that can be
allocated by one application is approximately 2 Gigabytes.
I just want to check my facts.
The theoretical limit would be 4GB minus a few bytes on PowerPC, on
Darwin/Intel I think it might be 3GB minus a few.
However, the practical limit is lower, and depends on whether you mean
in many allocations, or in one big allocation (I think the former). In
one big allocation, the limit is about 1GB, since the VM space is so
fragmented with stuff scattered about.
In the many allocations case, the theoretical limit has to be reduced by
the quantity of call stacks, the sizes of libraries, other binaries in
memory, and the executable, and, again depending on what you mean, the
amount of memory used by system libraries. But that all tends to be
less than .75 GB.
Chris Kane
Cocoa Frameworks, Apple