Sigh.. FFS... Here we go AGAIN.
there is currently a 2GB limit for all CLR objects, no matter what OS
you are running on 32 / 64 bit.
This is just plain WRONG.
By the way, your canned response is just as wrong this time as it was one
month ago when I corrected your mistakes:
http://groups.google.ca/group/micro...st&q=Michel+Posseth+[MCP]+object+size&rnum=7#
You are either a masochist, or have a poor memory.. Hmm I see a pattern
here -
problems with memory limits..
We already did this. This horse is dead..
If you quote an authoritative source, DO NOT CHANGE IT. At all. EVER.
Add a comment if you must, and state this is from you, not the source.
Or start your own blog, doc site, or whatever. But quoting inaccurately
is BAD.
FFS - The TITLE of the article is "BigArray<T>, getting around the 2GB array
size limit"
uhmmm... To get around a 2gb "limit" would require being LARGER than 2gb,
correct?!?
You did not even understand the TITLE of the article?!? WTF?
Arrays are not objects. They are essentially value types layed out
sequentially in memory. Objects are very different. They allow you to have
fields, properties, methods, and internal state data and other good stuff.
They certainly can be LARGER than 2gb.
Public Class Foo()
Dim a(1024*1024*2000) as byte
Dim b(1024*1024*2000) as byte
etc..
How big is this object?
First sentence of the above article: "I've received a number of
queries as to why the 64-bit version of the 2.0 .Net runtime
still has array maximum sizes limited to 2GB"
Note that this is talking about ARRAYS. Not ArrayLISTS, not OBJECTS
Further: "Differing from this are arrays of reference types
(e.g. objects, strings, class Y {}, etc.), for these arrays the actual
array will be that of a bunch of references, initially null. To initialize
the array your code will need to go through one element at a time
and create or assign an appropriate instance of the type to that array
element. The 2GB size limit for arrays applies to this array of
references, not the instances of the objects themselves"
So the size of the Instances of the ITEMS (not just the references) in the
array can be vastly LARGER THAN 2gb.
And then in the comments:
http://blogs.msdn.com/joshwil/archive/2005/08/10/450202.aspx#450213
Last sentence says "It does make one biased twoards using arrays of
primitive data types where you can instead of boxed references (e.g.
ArrayList) to avoid the significantly heavier penalties that go with that
practice on the 64-bit platform."
Which basically says for the problem at hand in this thread, the ArrayLIST,
does not suffer
from the 2gb limit. But you will burn a bunch of space on all those big
pointers.. And all the boxing
overhead, etc.
So, in summary:
1) Your information was wrong one month ago, and is still wrong.
2) Unless you read and COMPREHEND your own links, you will never understand
the issues
3) Arrays are not the same as objects and ArrayLISTs
4) This thread was about arraylists, so your response was completely OFF
TOPIC
5) Quote articles correctly.
6) Include links that support your position, not ones that have MANY things
that contradict you
Good luck with your memory issues and reading comprehension..
Have I been trolled?!?