Methods
B
M
N
P
W
Included Modules
Attributes
[R] loopback
[R] total
Class Public methods
new()
     # File activesupport/lib/active_support/testing/performance.rb, line 253
253:           def initialize
254:             @total = 0
255:           end
Instance Public methods
benchmark()
     # File activesupport/lib/active_support/testing/performance.rb, line 261
261:           def benchmark            
262:             with_gc_stats do
263:               before = measure
264:               yield
265:               @total += (measure - before)
266:             end
267:           end
measure_mode()
    # File activesupport/lib/active_support/testing/performance/ruby.rb, line 77
77:           def measure_mode
78:             self.class::Mode
79:           end
name()
     # File activesupport/lib/active_support/testing/performance.rb, line 257
257:           def name
258:             @name ||= self.class.name.demodulize.underscore
259:           end
profile()
    # File activesupport/lib/active_support/testing/performance/jruby.rb, line 66
66:           def profile
67:             yield
68:           end
profile()

overridden by each implementation

     # File activesupport/lib/active_support/testing/performance.rb, line 270
270:           def profile; end
profile()
    # File activesupport/lib/active_support/testing/performance/ruby.rb, line 81
81:           def profile
82:             RubyProf.resume
83:             yield
84:           ensure
85:             RubyProf.pause
86:           end
profile()
    # File activesupport/lib/active_support/testing/performance/rubinius.rb, line 69
69:           def profile
70:             yield
71:           end
Instance Protected methods
with_gc_stats()
    # File activesupport/lib/active_support/testing/performance/ruby/yarv.rb, line 9
 9:               def with_gc_stats
10:                 GC::Profiler.enable
11:                 GC.start
12:                 yield
13:               ensure
14:                 GC::Profiler.disable
15:               end
with_gc_stats()
    # File activesupport/lib/active_support/testing/performance/rubinius.rb, line 74
74:             def with_gc_stats
75:               @loopback = Rubinius::Agent.loopback
76:               GC.run(true)
77:               yield
78:             end
with_gc_stats()
    # File activesupport/lib/active_support/testing/performance/jruby.rb, line 71
71:             def with_gc_stats
72:               ManagementFactory.memory_mx_bean.gc
73:               yield
74:             end
with_gc_stats()

overridden by each implementation

    # File activesupport/lib/active_support/testing/performance/ruby.rb, line 90
90:             def with_gc_stats
91:               yield
92:             end
with_gc_stats()
    # File activesupport/lib/active_support/testing/performance/ruby/mri.rb, line 9
 9:               def with_gc_stats
10:                 GC.enable_stats
11:                 GC.start
12:                 yield
13:               ensure
14:                 GC.disable_stats
15:               end
with_gc_stats()

overridden by each implementation

     # File activesupport/lib/active_support/testing/performance.rb, line 274
274:             def with_gc_stats; end