diff options
author | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-06-20 07:30:41 +0000 |
---|---|---|
committer | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-06-20 07:30:41 +0000 |
commit | c5c1e8b8d49d65d5844b4c4a7cd905c2ba55eeb8 (patch) | |
tree | ea5fc75c988f156f5ad0f52109762613a6cd197e /benchmark/bm_so_binary_trees.rb | |
parent | 0ec4589259f229dcc0d736247878178578c7e3bc (diff) | |
download | ruby-c5c1e8b8d49d65d5844b4c4a7cd905c2ba55eeb8.tar.gz |
* benchmark/bm_so_binary_trees.rb: disable `puts' method
and change iteration parameter to increase execution time.
* benchmark/gc/binarytree.rb: added.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41480 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'benchmark/bm_so_binary_trees.rb')
-rw-r--r-- | benchmark/bm_so_binary_trees.rb | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/benchmark/bm_so_binary_trees.rb b/benchmark/bm_so_binary_trees.rb index 6a26465578..b1693e4109 100644 --- a/benchmark/bm_so_binary_trees.rb +++ b/benchmark/bm_so_binary_trees.rb @@ -4,7 +4,9 @@ # contributed by Jesse Millikan # disable output -def STDOUT.write_ *args +alias puts_orig puts +def puts str + # disable puts end def item_check(tree) @@ -25,7 +27,7 @@ def bottom_up_tree(item, depth) end end -max_depth = 12 # 16 # ARGV[0].to_i +max_depth = 16 # ARGV[0].to_i min_depth = 4 max_depth = min_depth + 2 if min_depth + 2 > max_depth @@ -55,3 +57,6 @@ min_depth.step(max_depth + 1, 2) do |depth| end puts "long lived tree of depth #{max_depth}\t check: #{item_check(long_lived_tree)}" + +undef puts +alias puts puts_orig |