This PR adds GC::Profiler support.
It is only enabled when GC::Profile is enabled.
Using the following simple script, I confirmed this change is available on both ruby 1.9.3-p392 and 2.0.0-p0.
require 'sigdump/setup'
GC::Profiler.enable
a = Thread.new {
100.times {
a = Array.new(10000){ 'aa' }
sleep 0.1
}
}
b = Thread.new {
100.times {
a = Array.new(10000){ 'aa' }
sleep 0.1
}
}
5.times do
Process.kill :CONT, Process.pid
sleep 0.5
end
a.join
b.join
This PR adds GC::Profiler support. It is only enabled when GC::Profile is enabled. Using the following simple script, I confirmed this change is available on both ruby 1.9.3-p392 and 2.0.0-p0.