Boxed types and constat propagation

Rémi Forax forax at univ-mlv.fr
Sun Apr 22 15:56:48 PDT 2012


On 04/23/2012 12:34 AM, Charles Oliver Nutter wrote:
> On Sun, Apr 22, 2012 at 2:12 AM, Rémi Forax<forax at univ-mlv.fr>  wrote:
>> You are the first as far as I know to use only a tree of method handles
>> to implement expressions. The rest of us generates bytecodes
>> and have a compiler that does constant propagation.
> JRuby doesn't do any constant propagation in our existing compiler,
> but we will be able to do some in the newer compiler. Ruby's constants
> are lazily discovered at runtime, so we can't propagate their
> values...but Hotspot should be able to in many cases.

Obviously, doing constant propagation on something that can be
monkey patched is harder.

Do you have a kind of closed world assumption ?
i.e. the compiler knows that there is no eval and will never load new 
code ?

>
> - Charlie

Rémi



More information about the mlvm-dev mailing list