TinyRB: A Young, Tiny Ruby VM for Us to Play With
Marc-André Cournoyer has proven that almost anything is possible by developing a small, functional, and surprisingly "unslow" Ruby VM called TinyRB. Some basic testing shows that it's faster than 1.8 on a Fibonacci benchmark, though slightly slower than JRuby, Rubinius, and YARV (Ruby 1.9).
Coming in at just 1541 lines of code so far, TinyRB is not going to be replacing your usual Ruby interpreter anytime soon. While it supports most of the keywords and some base classes including Class, Object, Fixnum, Symbol, and String, there's no support for Array, Module, Float, and a whole ton of essential stuff.
TinyRB, in its current state, is a playground for you to mess around in. In his last keynote at RubyConf 2008, Dave Thomas suggested we "fork Ruby" in many different ways, and TinyRB enables you to do that on a small scale. So newbies.. move on - but if the thought of experimenting and playing with a Ruby VM is something that gets you putting in a major Red Bull and pizza order.. dive in.
In other fringe implementation news, Brian Ford talks about how some new tweaks have increased Rubinius' performance four-fold two-fold.
February 13, 2009 at 12:58 pm
yay! thx for the post Peter.
I just want to add that I plan to add support for some of those shiny essentials, specially the ones named here, maybe not Regexp, too much trouble... We'll see
February 13, 2009 at 12:59 pm
Err, you might want to check out Brian's retraction of the 4x claims:
http://blog.brightredglow.com/2009/2/12/this-is-not-cold-fusion
Drats...
February 13, 2009 at 1:03 pm
First off, thanks pjm ;-)
Secondly.. THAT'S IT!! No more posts about speed increases! Every damn time I've posted something benchmark related in the last year, it's always been retracted or changed. My conclusion.. either no-one knows how to benchmark properly or statistics is a nightmare subject. I'll be steering clear ;-)
February 13, 2009 at 1:35 pm
@macournoyer
I was having trouble getting webrick to run Rails 2.3. It would run, but it would take 40 seconds per request! Even for simple "Hello world" templates.
So I installed Thin and now start my server like:
./script/server thin
BAM! Instant rendering.
Great job!
February 13, 2009 at 5:49 pm
@Peter: maybe you can benchmark how fast people retract based on which VM they're running? :P
February 13, 2009 at 9:17 pm
@Peter, I'm think both statements are true :)
February 23, 2009 at 7:17 am
I think this could be great for limited memory devices like cell phones etc
February 26, 2009 at 4:49 am
Действительно, на самом деле все очень просто :)