Some more Ruby observations (Re: Comparison between Python and "Ruby")

Neel Krishnaswami neelk at brick.cswv.com
Thu Nov 4 20:22:23 EST 1999


Greg Ewing <greg.ewing at compaq.com> wrote:
>Here are some random observations from studying the Ruby
>source code:
>
>* It doesn't use bytecode. The evaluator seems to operate
>  directly on a parse tree. I don't know what implications
>  this has for execution speed.

I was under the impression that Ruby did tail-recursion elimination,
and since continuation-passing forms are just a hair away from
bytecode, I am a bit surprised by this news. I'm not saying this is
impossible (witness the scm Scheme interpreter), mind, just a little
surprised.

Are there any syntax-tree munging phases to do stuff like common
subexpression elimination and loop hoisting? I guess that could yield
enough speedups to make a VM not yet necessary.


Neel




More information about the Python-list mailing list