Mailinglist Archive: opensuse-ruby (32 mails)

< Previous Next >
Re: [opensuse-ruby] rails 3 performance
On 20.03.2012 16:21, James Tan wrote:
On 03/20/2012 04:12 PM, Stephan Kulow wrote:
As expected, a GC.disable before the test "improves" performance
GC.disable:
0.258863653 0.552205324

normal with GC
0.579500092 1.455681835

Have you tried tweaking the GC settings?

We are using a patched 1.8.7 Ruby binary with the following tweaks to
improve GC:

#!/bin/sh
# defaults
# export RUBY_HEAP_MIN_SLOTS=10000
# export RUBY_HEAP_SLOTS_INCREMENT=10000
# export RUBY_HEAP_SLOTS_GROWTH_FACTOR=1.8
# export RUBY_GC_MALLOC_LIMIT=8000000
# export RUBY_HEAP_FREE_MIN=4096

# twitter
export RUBY_HEAP_MIN_SLOTS=500000
export RUBY_HEAP_SLOTS_INCREMENT=250000
export RUBY_HEAP_SLOTS_GROWTH_FACTOR=1
export RUBY_GC_MALLOC_LIMIT=50000000

exec "/usr/bin/ruby.org" "$@"


Not sure if this helps 1.9.

BTW: 1.9.3 has this patch already in, but for some reason I don't yet
understand, setting these variables don't really make a difference in
how often the GC kicks in. I'm feeling paranoid :)

Greetings, Stephan


--
To unsubscribe, e-mail: opensuse-ruby+unsubscribe@xxxxxxxxxxxx
To contact the owner, e-mail: opensuse-ruby+owner@xxxxxxxxxxxx

< Previous Next >
List Navigation
Follow Ups