diff options
Diffstat (limited to 'activesupport/lib/active_support/testing/performance/ruby')
-rw-r--r-- | activesupport/lib/active_support/testing/performance/ruby/mri.rb | 4 | ||||
-rw-r--r-- | activesupport/lib/active_support/testing/performance/ruby/yarv.rb | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/activesupport/lib/active_support/testing/performance/ruby/mri.rb b/activesupport/lib/active_support/testing/performance/ruby/mri.rb index d12482b58f..5fa0269b6a 100644 --- a/activesupport/lib/active_support/testing/performance/ruby/mri.rb +++ b/activesupport/lib/active_support/testing/performance/ruby/mri.rb @@ -19,7 +19,7 @@ module ActiveSupport # Ruby 1.8 + ruby-prof wrapper if RubyProf.respond_to?(:measure_memory) def measure - RubyProf.measure_memory / 1024.0 + RubyProf.measure_memory end end end @@ -48,7 +48,7 @@ module ActiveSupport # Ruby 1.8 + ruby-prof wrapper if RubyProf.respond_to?(:measure_gc_time) def measure - RubyProf.measure_gc_time / 1000 + RubyProf.measure_gc_time / 1000.0 / 1000.0 end end end diff --git a/activesupport/lib/active_support/testing/performance/ruby/yarv.rb b/activesupport/lib/active_support/testing/performance/ruby/yarv.rb index 1e6fa2f289..d226e75d0d 100644 --- a/activesupport/lib/active_support/testing/performance/ruby/yarv.rb +++ b/activesupport/lib/active_support/testing/performance/ruby/yarv.rb @@ -20,7 +20,7 @@ module ActiveSupport # Ruby 1.9 + GCdata patch if GC.respond_to?(:malloc_allocated_size) def measure - GC.malloc_allocated_size / 1024.0 + GC.malloc_allocated_size end end end |