Branch: refs/heads/master Home: https://github.com/MacRuby/MacRuby Commit: 6caf474aeed57958f35eee3b1dc4fa4967046170 https://github.com/MacRuby/MacRuby/commit/6caf474aeed57958f35eee3b1dc4fa4967... Author: Watson <watson1978@gmail.com> Date: 2011-10-24 (Mon, 24 Oct 2011) Changed paths: M string.c Log Message: ----------- Performance improvement in String#split(sep, limit). reserved an array size which is result when passed a limit. * before user system total real 1.710000 0.040000 1.750000 ( 1.477479) * after user system total real 1.270000 0.050000 1.320000 ( 1.076221) ---- require 'benchmark' Benchmark.bm do |x| str = "abcdefg0123456789\n" * 2000 x.report do 1000.times do str.split("\n", 1000) end end end