mirror of
https://github.com/kemko/liquid.git
synced 2026-01-07 10:45:42 +03:00
20 lines
414 B
Ruby
20 lines
414 B
Ruby
at_exit do
|
|
p 'Objects distribution:'
|
|
require 'pp'
|
|
pp ObjectSpace.count_objects
|
|
end
|
|
|
|
require 'allocation_tracer' rescue fail("install allocation_tracer extension/gem")
|
|
require File.dirname(__FILE__) + '/theme_runner'
|
|
|
|
Liquid::Template.error_mode = ARGV.first.to_sym if ARGV.first
|
|
profiler = ThemeRunner.new
|
|
|
|
require 'allocation_tracer/trace'
|
|
|
|
puts "Profiling memory usage..."
|
|
|
|
200.times do
|
|
profiler.run
|
|
end
|