# Recap of Virtual Meetup on GraalVM (part 1 & 2)

**URL:** <https://d.strumenta.community/t/recap-of-virtual-meetup-on-graalvm-part-1-2/752>\
**Category:** Events\
**Tags:** virtual-meetup\
**Created:** [July 3, 2020, 1:40pm UTC](https://d.strumenta.community/t/recap-of-virtual-meetup-on-graalvm-part-1-2/752 "2020-07-03T13:40:15Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![ftomassetti](https://d.strumenta.community/user_avatar/d.strumenta.community/ftomassetti/32/8_2.png) [@ftomassetti](https://d.strumenta.community/u/ftomassetti)\
**Post date:** [July 3, 2020, 1:40pm UTC](https://d.strumenta.community/t/recap-of-virtual-meetup-on-graalvm-part-1-2/752/1 "2020-07-03T13:40:15Z")

</div>

Yesterday we had a great meeting on GraalVM, presented by @Niko

It was a great meeting which sparkled a lot of interest. Thank you to everyone who joined!

In the chat we exchanged a lot of useful resources.

Here they are.

On Twitter using GraalVM

> **[blog - devmio - Software Know-How](https://devm.io/blog/)**
>
> \[...\]Read More...

Graal & Truffle to write JVM interpreters

> **[Graal and Truffle for Language Interpretation on the JVM | JRebel](https://www.jrebel.com/blog/graal-and-truffle-for-language-interpretation)**
>
> In this post, we look at the benefits of Graal and Truffle, its general code optimization, performance comparisons, and why it might be worth your time.

List of resources on Graal(VM)

> **[GitHub - neomatrix369/awesome-graal: A curated list of awesome resources for Graal,...](https://github.com/neomatrix369/awesome-graal)**
>
> A curated list of awesome resources for Graal, GraalVM, Truffle and related topics

GraalVM to write MPS-based interpreters

> **[MPS’ Quest of the Holy GraalVM of Interpreters – Wriggling Through Features](https://www.nikostotz.de/blog/mps-quest-of-the-holy-graalvm-of-interpreters/)**

Some information on using Truffle:

> <https://github.com/oracle/graal/blob/764872eb84108c5aecc94625d68edf38c9f549ae/truffle/docs/README.md>

Motivations for Truffle DSL:

[https://www.researchgate.net/publication/333510523\_Truffle\_DSL\_A\_DSL\_for\_Building\_Self-Optimizing\_AST\_Interpreters](https://www.researchgate.net/publication/333510523_Truffle_DSL_A_DSL_for_Building_Self-Optimizing_AST_Interpreters)

Luna, a language using Truffle

> **[Enso Analytics](https://github.com/enso-org)**
>
> Enso Analytics is a self-service data prep and analysis platform designed for data teams. - Enso Analytics

TruffleSqueak

> **[GitHub - hpi-swa/trufflesqueak: A Squeak/Smalltalk VM and Polyglot Programming...](https://github.com/hpi-swa/trufflesqueak)**
>
> A Squeak/Smalltalk VM and Polyglot Programming Environment for the GraalVM.

Another interesting (but old) article on Truffle:

> **[Posts tagged 'truffle'](http://cesquivias.github.io/tags/truffle.html)**
>
> Posts tagged 'truffle'

Recent tutorial by Nicolas Laurent on Truffle:

> **[norswap · Truffle Tutorial: Adding 1 and 1 Together](https://norswap.com/truffle-tutorial/)**

On AST vs. Bytecode: Fabio Niephaus’ paper compares AST-based :

> **[icooolps18-graalsqueak.pdf](https://fniephaus.com/2018/icooolps18-graalsqueak.pdf)**
>
> 480.37 KB

---

<div class="post-metadata">

**Author:** ![knavels](https://d.strumenta.community/letter_avatar_proxy/v4/letter/k/90db22/32.png) [@knavels](https://d.strumenta.community/u/knavels)\
**Post date:** [July 5, 2020, 8:34am UTC](https://d.strumenta.community/t/recap-of-virtual-meetup-on-graalvm-part-1-2/752/2 "2020-07-05T08:34:09Z")

</div>

Thank you for the recap  
I couldn’t join but fortunately found this useful post

---

<div class="post-metadata">

**Author:** ![ftomassetti](https://d.strumenta.community/user_avatar/d.strumenta.community/ftomassetti/32/8_2.png) [@ftomassetti](https://d.strumenta.community/u/ftomassetti)\
**Post date:** [July 10, 2020, 7:07am UTC](https://d.strumenta.community/t/recap-of-virtual-meetup-on-graalvm-part-1-2/752/3 "2020-07-10T07:07:20Z")

</div>

We had a great second meeting on GraalVM.

## Native images

@rafael asked if exception stack traces look different and @fniephaus replied that yes they do. He also said that RedHat people are adding more debug info, so you can see Java stack frame info more or less from within GDB. Here there are some related PRs: [Pull requests · oracle/graal · GitHub](https://github.com/oracle/graal/pulls?q=is%3Apr+is%3Aclosed+author%3Aadinn)

@neomatrix369 shared this link: [awesome-ai-ml-dl/examples/data/databases/graph/grakn/builder.sh at master · neomatrix369/awesome-ai-ml-dl · GitHub](https://github.com/neomatrix369/awesome-ai-ml-dl/blob/master/examples/data/databases/graph/grakn/builder.sh) It is an example to convert Jar into Native Image

Starting point for native image: [https://www.graalvm.org/docs/reference-manual/native-image/](https://www.graalvm.org/docs/reference-manual/native-image/)

And here a description of the limitations: [https://github.com/oracle/graal/blob/master/substratevm/LIMITATIONS.md](https://github.com/oracle/graal/blob/master/substratevm/LIMITATIONS.md)

And specifically on reflection: [https://github.com/oracle/graal/blob/master/substratevm/REFLECTION.md](https://github.com/oracle/graal/blob/master/substratevm/REFLECTION.md)

@neomatrix369 also suggest to look for the .md files in here [graal/substratevm at master · oracle/graal · GitHub](https://github.com/oracle/graal/tree/master/substratevm) . There you should find docs on the individual aspects of java config and how to handle them like JNA/JNI etc..

Article that covers _also_ native image: [https://medium.com/graalvm/graalvm-ten-things-12d9111f307d](https://medium.com/graalvm/graalvm-ten-things-12d9111f307d)

## Polyglot

Article on running Java inside a Jupyter Notebooks using GraalVM (java 11 or higher) [https://towardsdatascience.com/exploring-nlp-concepts-using-apache-opennlp-inside-a-jupyter-notebook-e53489ba2bd8](https://towardsdatascience.com/exploring-nlp-concepts-using-apache-opennlp-inside-a-jupyter-notebook-e53489ba2bd8)?

Espresso is an implementation in Truffle of Java. You can find more about it here: [Code search results · GitHub](https://github.com/oracle/graal/search?q=espresso&type=Code)

Regarding Espresso, @rafael points out this [Espresso Status · Issue #1656 · oracle/graal · GitHub](https://github.com/oracle/graal/issues/1656#issuecomment-527882248)

> We’re currently working on making Espresso 100% TCK compliant (about 1% to go). Soon after that, we plan to open source it.

## Tool support

@fniephaus GraalVM comes with an extension for VSCode with support for the LSP..the integration is built on top of the instrumentation API: [https://github.com/oracle/graal/tree/master/vscode/graalvm#language-server-integration](https://github.com/oracle/graal/tree/master/vscode/graalvm#language-server-integration)

## Truffle

@chrisseaton pointed out that you can also parse binary files and he has also generated an AST without going through any serialised format

## Other stuff

You should subscribe to the GraalVM slack. Get an invitation here: [Redirecting…](https://www.graalvm.org/slack-invitation/)

I shared the link to an RPG interpreter which we co-developed and is open-source: [GitHub - smeup/jariko: a JAva virtual machine Rpg Interpreter written in KOtlin](https://github.com/smeup/jariko)

---

<div class="post-metadata">

**Author:** ![patrick.viry](https://d.strumenta.community/letter_avatar_proxy/v4/letter/p/bc8723/32.png) [@patrick.viry](https://d.strumenta.community/u/patrick.viry)\
**Post date:** [July 16, 2020, 2:35pm UTC](https://d.strumenta.community/t/recap-of-virtual-meetup-on-graalvm-part-1-2/752/4 "2020-07-16T14:35:42Z")

</div>

Thinking again about Truffle, I was wondering how this “specialization via annotations” approach compares to generating Java source code (using whatever method available) then compiling it for the GraalVM or any other VM. The point is, when generating Java source code, you have to resolve all specializations anyway.

The flow is more complex, since you have to generate an intermediate representation as source code rather than work directly on the AST. But this have some advantages as well, such as easier debugging.

Any thoughts ?

---

<div class="post-metadata">

**Author:** ![ftomassetti](https://d.strumenta.community/user_avatar/d.strumenta.community/ftomassetti/32/8_2.png) [@ftomassetti](https://d.strumenta.community/u/ftomassetti)\
**Post date:** [July 17, 2020, 5:40am UTC](https://d.strumenta.community/t/recap-of-virtual-meetup-on-graalvm-part-1-2/752/5 "2020-07-17T05:40:30Z")

</div>

> [@patrick.viry](#):
>
> Thinking again about Truffle, I was wondering how this “specialization via annotations” approach compares to generating Java source code (using whatever method available)

But how would be the information for generation be provided? I think it is useful to have it in a source connected to the code of the interpreter, as they seem strongly related
