Brent-

	I would love to see a version of these patches against 1.8.6 or  
1.8.7. I can test them on a few hundred servers to see what kind of  
resource consumption these changes have in larger deployments.

	Awesome work on this. I'm very interetsed in testing this for you.  
You can contact me off list if you like or if you want servers to use  
to test this on.

Thanks

Ezra Zygmuntowicz
ez / engineyard.com


On Nov 30, 2008, at 11:34 AM, Brent Roman wrote:

>
> Roger,
>
> I already responded in detail to this bug:
>
> http://rubyforge.org/tracker/?func=detail&atid=1698&aid=7896&group_id=426
>
> I just bang on Ruby 1.6.8 for our robotics application.
>
> You seem to already be doing a lot of excellent Ruby testing with  
> current
> versions.
> If I spent a couple days developing these two patches for Ruby 1.8.7,
> would you be willing to run
> regression tests against them and to report the results here?
>
> I think the small stack clearing patch should improve the GC behavior,
> but, by itself, it will likely slow down some apps due to its having
> to clear large areas of stack.  I'd expect to see that
> slow down mitigated by the larger patch that would refactor rb_eval()
> and thereby keep the stack smaller.
>
> The combined patches will likely be large, so I'll just post links  
> to them
> here.
>
> Would anyone else be willing to test them? ...
> Particularly those who have large apps, and/or apps that use multiple
> threads or
> continuations that seem to leak memory?
>
> - brent
>
> P.S.  I use gcc 3.4.5 for generating code for our embedded ARM  
> targets.
> The older compiler generates fewer stack temporaries than the newer  
> ones.
> Don't rush to update :-)
>
> P.P.S.  The way GC is currently invoked causes it to occur when that  
> stack
> is already near its maximum depth.  This patch tries to make GC  
> normally
> occur is part of CHECK_INTS, when the stack tends to be shallower.
> At that point, clearing the stack can be much more effective.
>
>
>
> Roger Pack wrote:
>>
>>
>> Wow thanks for doing that. I'd say please create a redmine bug for it
>> [or attach it to an existing].  A patch to 1.8.7 would be sweet :)
>> A patch for 1.9 would be great too :)
>>
>> I'd imagine that your system is "better" than just blindly doing a
>> garbage_collect()
>> {
>> clear_stack();
>> ....do normal gc
>> }
>> void clear_stack()
>> {
>>  a = char[10000];
>>  memclear(a);
>> }
>> ?
>>
>> Thanks!
>> -=R
>> Note that I use gcc 3.4.5 I assume that won't be a problem though.
>>
>>
>>
>
> -- 
> View this message in context: http://www.nabble.com/-ruby-core%3A19846---Bug--744--memory-leak-in-callcc--tp20447794p20761320.html
> Sent from the ruby-core mailing list archive at Nabble.com.
>
>