out of memory exception encountered
hello, can anyone tell me why i am getting an out of memory error while creating an object even though i have enough of ram space?
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Sanju SinghPosted Feb 28, 2015, 1:25 AM
Sanju SinghPosted Feb 6, 2015, 10:16 AM
Pranay RanaPosted Feb 6, 2015, 1:36 AM
For example
public void rec()
{
rec();
}
if you have code like above system will throw memory exceptiion.
Joginder BangerPosted Feb 6, 2015, 1:03 AM
There is no any difference until you compile to same target architecture. I suppose you are compiling for
32bit architecture in both cases.Worth mention that
OutOfMemoryExceptioncan be raised also if you get2GBof memory allocated by a single collection in CLR (sayList) on both architectures32and64bit.To be able to benefit for possible memory potential goodness on
64bit architecture, you have to compile your code targeting64bit architecture. After that, naturally, your binary will run only on64bit, but will benefit from possibility having more space available in RAM.