Re: Questions about JVM to Scala.js IR compiler (GSOC project)

Sébastien Doeraene <[email protected]> Mon, 22 Feb 2016 20:18:28 +0100
Newsgroups gmane.comp.lang.scala
Message-ID <CAJwkOg42McLHoOf=98QSO7sq3o_BsL9rdvRtUWv7uiAppGws+A@mail.gmail.com>
Hello Andrea,

Nice to read that you are interested in this project!

1) In general, working knowledge of Scala is required for projects with the
Scala team. Beyond that, each project states its own prerequesites on the
page http://scala-lang.org/gsoc/2016.html

2) What you describe is the "alternate" version of the project. The
originally proposed project would compile Java source code into Scala.js
IR. We believe that compiling JVM bytecode would be harder than Java source
code (due to the necessity of recovering loops, for example). But as we
wrote, for a student already familiar with the JVM bytecode, it *might* be
easier. Otherwise, yes, you are correct.

3) There isn't much documentation about the IR (a few doc-comments for the
weirdest nodes), but here are a few pointers to the relevant source files:

   - The types (similar to JVM types):
   https://github.com/scala-js/scala-js/blob/master/ir/src/main/scala/org/scalajs/core/ir/Types.scala
   - The trees (the definition of the IR itself):
   https://github.com/scala-js/scala-js/blob/master/ir/src/main/scala/org/scalajs/core/ir/Trees.scala
   - The IR checker, a mechanized verifier checking that some IR is
   well-typed and otherwise well-formed:
   https://github.com/scala-js/scala-js/blob/master/tools/shared/src/main/scala/org/scalajs/core/tools/linker/checker/IRChecker.scala

It is relatively simple, although it mingles JVM-like expressions and
JS-like expressions.

Cheers,
Sébastien


On Mon, Feb 22, 2016 at 7:43 PM, Andrea Francesco Iuorio <
[email protected]> wrote:

> Hi, I'm currently a MSc student in Computer Science. I would like to try
> to submit a proposal for this year's GSOC under Scala, more precisely for
> the JVM -> Scala IR Compiler (for my BSc. thesis I had to develop a JVM
> compiler for a toy language, so I kinda know the JVM bytecode), however I
> have some questions:
>
> 1) Do you require, as an organization, any prerequisite for apply ?
> 2) If I understand correctly, the purpose of the project is writing a
> compiler in Scala that compile JVM bytecode (or, maybe better, a .class
> file ?) into Scala.js IR. Correct or there is something that I've missed ?
> 3) There is some kind of documentation about the IR that I can read for
> getting an idea about its complexity ?
>
> --
> You received this message because you are subscribed to the Google Groups
> "scala-language" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups "scala-language" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
For more options, visit https://groups.google.com/d/optout.