Skip to content

Instantly share code, notes, and snippets.

View 1.9.3-p385-perf
build_package_combined_patch() {
local package_name="$1"
{
curl https://github.com/funny-falcon/ruby/compare/p385...p385_ary_queue.diff | patch -p1
curl https://github.com/funny-falcon/ruby/compare/p385...p385_st_opt.diff | patch -p1
curl https://github.com/funny-falcon/ruby/compare/p385...p385_backport_speedup_require.diff | patch -p1
curl https://github.com/funny-falcon/ruby/compare/p385...p385_backport_gc.diff | patch -p1
autoconf
./configure --prefix="$PREFIX_PATH" $CONFIGURE_OPTS
View gist:4365977
def foo(x); 99; end
a = foo (44) / 11
foo = 99999999
b = foo (44) / 11
puts "a: #{a} b: #{b}" #output of "a: 99 b: 9"
# s(:defn, :foo, s(:args, :x), s(:lit, 99)),
# s(:lasgn, :a, s(:call, nil, :foo, s(:call, s(:lit, 44), :/, s(:lit, 11)))),
# s(:lasgn, :foo, s(:lit, 99999999)),
# s(:lasgn, :b, s(:call, s(:call, nil, :foo, s(:lit, 44)), :/, s(:lit, 11))))
@burke
burke / 0-readme.md
Created Jan 27, 2012 — forked from funny-falcon/cumulative_performance.patch
ruby-1.9.3-p327 cumulative performance patch for rbenv
View 0-readme.md

ruby-1.9.3-p327 cumulative performance patch for rbenv

This installs a patched ruby 1.9.3-p327 with various performance improvements and a backported COW-friendly GC, all courtesy of funny-falcon.

Requirements

You will also need a C Compiler. If you're on Linux, you probably already have one or know how to install one. On OS X, you should install XCode, and brew install autoconf using homebrew.

@burke
burke / 0-readme.md
Created Jan 18, 2012 — forked from titanous/0-readme.md
Ruby 1.9.3-p0 with ruby-debug19
View 0-readme.md

Ruby 1.9.3-p0 with ruby-debug19

Ruby 1.9.3-p0 requires a minor patch to make ruby-debug19 work. If you have ruby-build and rbenv installed, these scripts will install ruby-1.9.3-p0.

curl https://raw.github.com/gist/1633720/install-ruby-1.9.3-p0.sh | sh
View gist:1038026
############# THIS IS WITHIN THE LIBRARY #############
class Foo
def initialize(a, b, c, opts={})
#do some stuff
end
end
######################################################
@burke
burke / Yehudalize.rb
Created Apr 21, 2011 — forked from stefanpenner/Yehudalize.rb
An extension that stef should always include
View Yehudalize.rb
module Yehudalize
def method_missing(method_sym, *arguments, &block)
if method_sym.to_s =~ /^(omg_)?(.*)_to_me$/
send($2.to_sym, *arguments, &block)
else
super
end
end
end
You can’t perform that action at this time.