Generally in the 32-bit environment, an application window has available up to 2Gb (in a few cases 3Gb). In all cases the actual amount of memory available to an application window is limited to the excess of the available physical memory over the memory required by the operating system and running services.
Evidently, any specific .Net object, including an array, is limited to 2Gb in both 32-bit and 64-bit .Net programs. .Net provides inherent memory manangement which incorporates this limit.
So in the 64-bit environment, assuming that the appropriate physical memory has been installed, many 2Gb objects can be created and manipulated, but in the 32-bit environment it is unlikely that even one 2Gb object can be created and manipulated effectively.
Using custom memory manangement, one can exceed this Microsoft-imposed design limitation:
- Arrays can be implemented as blocks, each of which does not exceed this limit, and an appropriate function to calculate the appropriate block number to set or get array values can be developed. This approach would still result in fully-managed code.
Arrays could be implemented using un-mananged code involving custom memory management and memory pointers.
For additional comments on this issue see:
http://msdn.microsoft.com/en-us/library/ms241064(VS.80).aspx
http://msdn.microsoft.com/en-us/library/ms241064.aspx
http://stackoverflow.com/questions/5736 ... 2147483647
http://www.informit.com/guides/content. ... seqNum=592