1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* benchmark/gc/gcbench.rb: Do not use GC::Profiler::disable because

GC::Profiler::disable prohibit to access profiling data. It should
  be spec bug.
  Skip GC::Profiler::report if RUBY_VERSION < '2.0.0'



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41490 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
ko1 2013-06-20 09:31:51 +00:00
parent c76ebddc9f
commit 45f7b78d29
2 changed files with 11 additions and 4 deletions

View file

@ -1,3 +1,11 @@
Thu Jun 20 18:29:26 2013 Koichi Sasada <ko1@atdot.net>
* benchmark/gc/gcbench.rb: Do not use GC::Profiler::disable because
GC::Profiler::disable prohibit to access profiling data. It should
be spec bug.
Skip GC::Profiler::report if RUBY_VERSION < '2.0.0'
Thu Jun 20 17:59:08 2013 Koichi Sasada <ko1@atdot.net>
* benchmark/gc/gcbench.rb: stop GC::Profiler before output results.

View file

@ -12,11 +12,10 @@ GC::Profiler.enable
tms = Benchmark.measure{|x|
load script
}
GC::Profiler.disable
GC::Profiler.report
pp GC.stat
gc_time = GC::Profiler.total_time
GC::Profiler.report if RUBY_VERSION >= '2.0.0' # before 1.9.3, report() may run infinite loop
GC::Profiler.disable
pp GC.stat
puts
puts script