[Insight-users] limit of memory load in itk programs?

Luis Ibanez luis.ibanez at kitware.com
Wed Jun 18 16:10:49 EDT 2008


Hi Monica,

If you are using a 32bits machine you will not
be able to allocate more than 4 Gb of RAM.

Part of the memory is already taken by your system,
which explains why your allocations are limited
to 3.5~3.7 Gb.

Thanks for running the experiment.
This indeed confirms that what you are observing
is not an ITK issue, but a natural limitation
of your machine.


    Regards,


       Luis


----------------------------
Monica Hernandez wrote:
> Dear Luis,
> 
> my machine is a 32 bits platform.
>>From Gaetan's mail I guess that this has something to do with the memory
> size, right?
> ...I also did the experiment you suggested and I cannot allocate more
> than 3.5 or 3.7 Gbs, so it is not ITK's problem...
> 
> Thank you!
> 
> Luis Ibanez wrote:
> 
>>Hi Monica,
>>
>>
>>a) Is your machine a 64bits platform ?
>>
>>
>>b) Have you verified how far you can get by
>>   "manually" allocating memory ?
>>
>>   with code such as:
>>
>>     main(int argc, char * argv [] )
>>     {
>>     size_t numberOfBytes = atol(argv[1] );
>>     char * buffer = new char[numberOfBytes];
>>
>>     delete [] buffer;
>>     return 0;
>>     }
>>
>>   Please give it a try and let us know
>>   how many gigabytes you can actually allocate
>>   in this machine.
>>
>>
>>
>>c) ITK have some limitations but they are pretty high.
>>
>>   We run nightly tests that use up to 11Gb of RAM in
>>   some of the Image Registration framework tests.
>>
>>   That's well above the 3.5Gb that you are reporting.
>>
>>
>>Let's start with characterizing your machine.
>>
>>We can then try the large memory tests in ITK,
>>to see which ones can be run in your platform.
>>
>>
>> Please let us know what you find from the test in (b).
>>
>>
>>     Thanks
>>
>>
>>        Luis
>>
>>
>>-----------------------
>>Monica Hernandez wrote:
>>
>>>Dear itk users,
>>>
>>>I am currently working with programs with high RAM memory requirements.
>>>I have observed that if I try to run a program with memory load superior
>>>to 3.5 Gbs I get this
>>>message
>>>
>>>terminate called after throwing an instance of 'std::bad_alloc'
>>>  what():  St9bad_alloc
>>>
>>>and my program crashes. I am working in a 8 Gbs RAM and 4 Gbs Swap
>>>Scientific linux machine.
>>>
>>>Does anybody know if there exists any limitation for ITK executables or
>>>maybe  there is a hidden constraint in my linux that makes these
>>>programs abort?
>>>
>>>Thanks a lot!!
>>>_______________________________________________
>>>Insight-users mailing list
>>>Insight-users at itk.org
>>>http://www.itk.org/mailman/listinfo/insight-users
>>>
>>
> 
> 


More information about the Insight-users mailing list