On Sun, Oct 21, 2012 at 7:39 AM, Staffan Tylen <staffan.ty...@gmail.com>wrote:
>
>> One thing you've overlooked in your conclusions is the effect of keeping
>> large numbers of "live" objects in memory has on the garbage collector.
>> The processing of an individual item might be faster, but as the size of
>> the active memory heap grows, each garbage collection cycle takes longer
>> because there are more live objects that need to be traced. Add in the
>> paging effects from having a larger working set, and I'm not particularly
>> surprised that step benchmarks as faster. If you don't really need to have
>> all of the data in memory at one time, you are better off not retrieving
>> everything at one time.
>>
>>
> Rick, thanks. This leads to the question - does explicit 'drop' statements
> reduce the work for the garbage collection? I would believe so...
It depends on what you are dropping. If the variable holds the only
reference to an object, then yes it does. If there are other references
keeping the object alive, then it is just extra overhead. And, in general,
if the variable in question is just a local variable that will be going out
of scope any way, then drop is just a waste of time. You really have to
have a good understanding of how the garbage collector works to get any
advantage from using drop. Let me put it this way...I have a better
understanding of how the ooRexx garbage collector works than anybody else
on the planet, and I NEVER use drop in my programs.
Rick
>
>
> Staffan
>
>
>
> ------------------------------------------------------------------------------
> Everyone hates slow websites. So do we.
> Make your web apps faster with AppDynamics
> Download AppDynamics Lite for free today:
> http://p.sf.net/sfu/appdyn_sfd2d_oct
> _______________________________________________
> Oorexx-users mailing list
> Oorexx-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/oorexx-users
>
>
------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
_______________________________________________
Oorexx-users mailing list
Oorexx-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-users