[#68478] Looking for MRI projects for Ruby Google Summer of Code 2015 — Tony Arcieri <bascule@...>

Hi ruby-core,

10 messages 2015/03/10

[ruby-core:68464] Re: GSoC 2015: JIT Compiler

From: "Martin J. Dürst" <duerst@...>
Date: 2015-03-09 09:43:05 UTC
List: ruby-core #68464
Hello Jakub,

On 2015/03/09 02:29, Jakub Trzebiatowski wrote:

> Quoting Ideas List:
>
> "MRI executes Ruby via an interpreted stack-machine bytecode language k=
nown as YARV (Yet Another Ruby VM) bytecode. The execution of this byteco=
de could be improved by a mixed-mode execution strategy which looks for f=
requently executed code and JITs the corresponding YARV bytecode to archi=
tecture-dependent machine language.=E2=80=9D

Are you referring to this:
https://github.com/rubygsoc/rubygsoc/wiki/Ideas-List ?
I'm not sure you'll get feedback from the responsible people on this=20
list; maybe making a pull request is an easier way to get their attention=
.

> That=E2=80=99s a great idea, but in my opinion it=E2=80=99s totally imp=
osible for a single student to write a modern JIT compiler in four months=
.

I'm not an expert, but I'd tend to agree.


> On the other hand, I think that it=E2=80=99s possible to integrate Ruby=
 with state-of-the-art LuaJIT VM, which features lighting fast bytecode i=
nterpreter and JIT compiler. I believe that all Ruby language features co=
uld be compiled to LuaJIT bytecode, although that needs further investiga=
tion. That would probably take me all remaining 8 days.

What do you mean by "all remaining 8 days?". As for feasibility, I think=20
the most difficult part would be to handle Ruby's blocks. I don't think=20
Lua has blocks, so this may be hard.


> That leads to my question: would you at least consider accepting such a=
 student proposal, or should I not waste my time and search for another p=
roject?

I am not involved in this, so I can't give you a definitive answer, but=20
I think it would be good to try out whether/how Ruby can be sped up by=20
JIT compilation. Maybe the goal of the project should just be to=20
implement some JIT compilation; whether this is done from YARV to e.g.=20
LLVM, or from Ruby directly to something like LuaJIT, or from YARV to=20
LuaJIT, could be an implementation decision by the student (together=20
with the mentor).


Regards,   Martin.

In This Thread