Created
May 3, 2012 22:16
-
-
Save ratnikov/2589907 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1.9.3 | |
Rehearsal ---------------------------------------------- | |
for n=100 0.450000 0.020000 0.470000 ( 0.457106) | |
for n=500 1.880000 0.020000 1.900000 ( 1.915119) | |
for n=1000 3.770000 0.060000 3.830000 ( 3.823367) | |
for n=5000 18.850000 0.310000 19.160000 ( 19.172096) | |
------------------------------------ total: 25.360000sec | |
user system total real | |
for n=100 0.370000 0.010000 0.380000 ( 0.384559) | |
for n=500 1.880000 0.030000 1.910000 ( 1.911310) | |
for n=1000 3.830000 0.070000 3.900000 ( 3.899589) | |
for n=5000 18.860000 0.300000 19.160000 ( 19.317337) | |
JRuby 1.6.7: | |
Rehearsal ---------------------------------------------- | |
for n=100 4.218000 0.000000 4.218000 ( 4.218000) | |
for n=500 5.934000 0.000000 5.934000 ( 5.934000) | |
for n=1000 9.347000 0.000000 9.347000 ( 9.347000) | |
for n=5000 40.806000 0.000000 40.806000 ( 40.806000) | |
------------------------------------ total: 60.305000sec | |
user system total real | |
for n=100 0.740000 0.000000 0.740000 ( 0.740000) | |
for n=500 3.487000 0.000000 3.487000 ( 3.487000) | |
for n=1000 6.573000 0.000000 6.573000 ( 6.573000) | |
for n=5000 33.031000 0.000000 33.031000 ( 33.031000) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1.9.3: | |
Rehearsal ---------------------------------------------- | |
for n=1 0.010000 0.000000 0.010000 ( 0.010658) | |
for n=100 0.120000 0.010000 0.130000 ( 0.125223) | |
for n=500 0.580000 0.000000 0.580000 ( 0.585249) | |
for n=1000 1.170000 0.010000 1.180000 ( 1.179782) | |
for n=5000 5.750000 0.040000 5.790000 ( 5.802824) | |
------------------------------------- total: 7.690000sec | |
user system total real | |
for n=1 0.000000 0.000000 0.000000 ( 0.001812) | |
for n=100 0.090000 0.000000 0.090000 ( 0.090467) | |
for n=500 0.640000 0.010000 0.650000 ( 0.656301) | |
for n=1000 1.170000 0.010000 1.180000 ( 1.187816) | |
for n=5000 6.190000 0.060000 6.250000 ( 6.255122) | |
JRuby: | |
Rehearsal ---------------------------------------------- | |
for n=1 0.088000 0.000000 0.088000 ( 0.088000) | |
for n=100 1.971000 0.000000 1.971000 ( 1.971000) | |
for n=500 3.044000 0.000000 3.044000 ( 3.044000) | |
for n=1000 4.934000 0.000000 4.934000 ( 4.934000) | |
for n=5000 19.213000 0.000000 19.213000 ( 19.213000) | |
------------------------------------ total: 29.250000sec | |
user system total real | |
for n=1 0.004000 0.000000 0.004000 ( 0.004000) | |
for n=100 0.328000 0.000000 0.328000 ( 0.328000) | |
for n=500 1.643000 0.000000 1.643000 ( 1.643000) | |
for n=1000 3.461000 0.000000 3.461000 ( 3.461000) | |
for n=5000 17.585000 0.000000 17.585000 ( 17.585000) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1.9.3: | |
Rehearsal ---------------------------------------------- | |
for n=1 0.050000 0.010000 0.060000 ( 0.056099) | |
for n=100 0.190000 0.000000 0.190000 ( 0.196467) | |
for n=500 0.970000 0.000000 0.970000 ( 0.969986) | |
for n=1000 1.930000 0.010000 1.940000 ( 1.944187) | |
for n=5000 9.650000 0.050000 9.700000 ( 9.701100) | |
------------------------------------ total: 12.860000sec | |
user system total real | |
for n=1 0.000000 0.000000 0.000000 ( 0.001878) | |
for n=100 0.190000 0.000000 0.190000 ( 0.193805) | |
for n=500 0.970000 0.010000 0.980000 ( 0.980276) | |
for n=1000 1.900000 0.010000 1.910000 ( 1.909735) | |
for n=5000 9.630000 0.050000 9.680000 ( 9.686748) | |
JRuby: | |
Rehearsal ---------------------------------------------- | |
for n=1 0.227000 0.000000 0.227000 ( 0.227000) | |
for n=100 3.020000 0.000000 3.020000 ( 3.020000) | |
for n=500 4.552000 0.000000 4.552000 ( 4.552000) | |
for n=1000 5.961000 0.000000 5.961000 ( 5.961000) | |
for n=5000 24.933000 0.000000 24.933000 ( 24.933000) | |
------------------------------------ total: 38.693000sec | |
user system total real | |
for n=1 0.005000 0.000000 0.005000 ( 0.005000) | |
for n=100 0.414000 0.000000 0.414000 ( 0.414000) | |
for n=500 2.134000 0.000000 2.134000 ( 2.133000) | |
for n=1000 3.983000 0.000000 3.983000 ( 3.983000) | |
for n=5000 22.986000 0.000000 22.986000 ( 22.986000) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1.9.3: | |
Rehearsal ---------------------------------------------- | |
for n=1 0.050000 0.010000 0.060000 ( 0.056099) | |
for n=100 0.190000 0.000000 0.190000 ( 0.196467) | |
for n=500 0.970000 0.000000 0.970000 ( 0.969986) | |
for n=1000 1.930000 0.010000 1.940000 ( 1.944187) | |
for n=5000 9.650000 0.050000 9.700000 ( 9.701100) | |
------------------------------------ total: 12.860000sec | |
user system total real | |
for n=1 0.000000 0.000000 0.000000 ( 0.001878) | |
for n=100 0.190000 0.000000 0.190000 ( 0.193805) | |
for n=500 0.970000 0.010000 0.980000 ( 0.980276) | |
for n=1000 1.900000 0.010000 1.910000 ( 1.909735) | |
for n=5000 9.630000 0.050000 9.680000 ( 9.686748) | |
JRuby: | |
Rehearsal ---------------------------------------------- | |
for n=1 0.227000 0.000000 0.227000 ( 0.227000) | |
for n=100 3.020000 0.000000 3.020000 ( 3.020000) | |
for n=500 4.552000 0.000000 4.552000 ( 4.552000) | |
for n=1000 5.961000 0.000000 5.961000 ( 5.961000) | |
for n=5000 24.933000 0.000000 24.933000 ( 24.933000) | |
------------------------------------ total: 38.693000sec | |
user system total real | |
for n=1 0.005000 0.000000 0.005000 ( 0.005000) | |
for n=100 0.414000 0.000000 0.414000 ( 0.414000) | |
for n=500 2.134000 0.000000 2.134000 ( 2.133000) | |
for n=1000 3.983000 0.000000 3.983000 ( 3.983000) | |
for n=5000 22.986000 0.000000 22.986000 ( 22.986000) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ENV["RAILS_ENV"] = 'production' | |
require File.expand_path('../config/environment', __FILE__) | |
require 'benchmark' Rails.logger.level = Logger::FATAL | |
env = proc do | |
{"rack.version"=>[1, 1], "rack.input"=>'', "rack.errors"=> '', | |
"REQUEST_METHOD"=>"GET", "SERVER_NAME"=>"example.org", "SERVER_PORT"=>"80", "QUERY_STRING"=>"", "PATH_INFO"=>"/", "rack.url_scheme"=>"http", "HTTPS"=>"off", "SCRIPT_NAME"=>"", "CONTENT_LENGTH"=>"0", "REMOTE_ADDR"=>"127.0.0.1", "HTTP_HOST"=>"example.org", "HTTP_COOKIE"=>""} | |
end | |
values = [ 1, 100, 500, 1000, 5000 ] #, 10000 ] | |
Benchmark.bmbm do |x| | |
values.each { |n| x.report("for n=#{n}") { n.times { Rails.application.call env.call} } } | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment