diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2017-01-08 03:46:17 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2017-01-08 03:46:17 +0000 |
commit | caca9a473fd484aec81798fcb6a07bca25977b1d (patch) | |
tree | 1e0081e051c12cc84a81b40100b743a5d8f9b542 /benchmark | |
parent | 1bf10e33fd3a3cdaa26fbeef119316553d125ddd (diff) | |
download | ruby-caca9a473fd484aec81798fcb6a07bca25977b1d.tar.gz |
driver.rb: extract loop times [ci skip]
* benchmark/driver.rb (BenchmarkDriver.load): extract loop times
from the loaded results to adjust the results.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57286 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'benchmark')
-rw-r--r-- | benchmark/driver.rb | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/benchmark/driver.rb b/benchmark/driver.rb index a4f09b105f..db97cbf15b 100644 --- a/benchmark/driver.rb +++ b/benchmark/driver.rb @@ -41,10 +41,15 @@ class BenchmarkDriver else h = eval(input.read) end + results = h[:results] || h["results"] obj = allocate obj.instance_variable_set("@execs", h[:executables] || h["executables"]) - obj.instance_variable_set("@results", h[:results] || h["results"]) + obj.instance_variable_set("@results", results) obj.instance_variable_set("@opt", opt) + [1, 2].each do |i| + loop = results.assoc((n = "loop_whileloop#{i}").intern) || results.assoc(n) + obj.instance_variable_set("@loop_wl#{i}", loop ? loop[1].map {|t,*|t} : nil) + end obj end |