comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Solve memory problems
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Solve memory problems [message #64719 is a reply to message #64623] Tue, 13 January 2009 06:34 Go to previous messageGo to previous message
corinnefrey is currently offline  corinnefrey
Messages: 18
Registered: November 2006
Junior Member
hi carsten,

indeed, this is the case in my actual problem. i am using a programme,
which uses several subprogrammes and subsub-programmes. between each
level there is an exchange of variables. if i defined all variables
and return-variables at the beginning, i would run out of memory just
by defining the variables. but probably i could make a compilation of
the "most wanted" variables to have them at a constant place from the
beginning. could be worth checking out!

thanks,
corinne


> All the memory you use in a function or procedure is given back when that
> function returns, except for any variables that are handed back via
> arguments or function return values.
>
> This is pure conjecture, but maybe you use some memory in your function, then
> allocate more memory for the return value, then return, freeing the earlier
> memory, but leaving you with the return value allocated somewhere "in the
> middle" of the heap memory, thereby fragmenting it more and more with each
> call of the function. Then, it should make a difference if you allocate
> your return array at the beginning of your function.
>
> Maybe you could use memtest.pro to investigate the fragmentation problem?
>
> chl
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: question about array interpolation
Next Topic: Re: pdf extractor

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Thu Oct 09 14:25:53 PDT 2025

Total time taken to generate the page: 0.08088 seconds