Skip to content

Instantly share code, notes, and snippets.

@gamache
Last active December 25, 2015 10:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gamache/6962760 to your computer and use it in GitHub Desktop.
Save gamache/6962760 to your computer and use it in GitHub Desktop.
Running method-cache-test on MRI Ruby 2.1.0dev.
$ ruby --version
ruby 2.1.0dev (2013-10-13 trunk 43273) [x86_64-darwin13.0.0]
$ ruby method-cache-test.rb
user system total real
defined methods, not busting cache:
0.310000 0.010000 0.320000 ( 0.311989)
method_missing dispatch, not busting cache:
0.400000 0.000000 0.400000 ( 0.401800)
defined methods, busting cache with trivial Object#extend:
1.970000 0.010000 1.980000 ( 1.983993)
defined methods, busting cache with Class.new:
1.860000 0.010000 1.870000 ( 1.870652)
method_missing dispatch, busting cache with trivial Object#extend:
2.180000 0.000000 2.180000 ( 2.187509)
method_missing dispatch, busting cache with Class.new:
2.010000 0.010000 2.020000 ( 2.009935)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment