Is graal VM going to be part of a future JDK release?

Vitaly Davidovich vitalyd at gmail.com
Fri Mar 13 16:32:52 UTC 2015


Thomas,

AFAIK, graal has some intrinsics that use vector instructions (I think
array copy/equals?), but does it also auto-vectorize, say, arithmetic?

for (int i = 0; i < some_trip_count; ++i)
    a[i] = b[i] * c[i];

Does it unroll and vectorize that?

Thanks


On Fri, Mar 13, 2015 at 12:07 PM, Thomas Wuerthinger <
thomas.wuerthinger at oracle.com> wrote:

> Vitaly,
>
> We are equally committed to Java performance as we are to Truffle guest
> language performance. While we are currently making the largest difference
> for JavaScript, Ruby, and R, we expect to also make a significant
> difference for Java in the future. The mentioned OTN release of Graal
> already includes auto-vectorisation features. We have several larger areas
> where we try to further push the current limits of Java performance.
>
> - thomas
>
>
> On 13 Mar 2015, at 16:38, Vitaly Davidovich <vitalyd at gmail.com> wrote:
>
> Thanks Thomas.
>
> I've been lurking on this mailing list for a while, so sort of have a big
> picture view of what's happening.  However, as most conversations here tend
> to center around guest languages, I wasn't quite sure what the "value-add",
> so to speak, was for plain old java code.
>
> Regarding (c) in your email, yes, the somewhat naive inlining policy is
> annoying (e.g. assert statements possibly screwing with inlining
> decisions).  However, in C2, there's also a different inlining threshold
> for very hot code (i.e. FreqInlineSize flag), which by default is 325 or
> so.  I believe there's also ongoing work on incremental inlining.  In light
> of that, does graal's late inlining policy still help somewhere? Just
> curious.
>
> Do you guys have any plans to support some things that C2 currently lacks,
> such as autovectorization of arithmetic/logic/etc operations on, say,
> arrays? That would be pretty sweet.  Or is the (near to mid-term, at least)
> focus going to remain on supporting guest languages?
>
> Thanks
>
> On Fri, Mar 13, 2015 at 11:29 AM, Thomas Wuerthinger <
> thomas.wuerthinger at oracle.com> wrote:
>
>> Vitaly,
>>
>> Graal has a very different design from C2 and therefore it has distinct
>> performance characteristics. We invite developers to try our latest OTN
>> release [1] on their applications and give us feedback.
>>
>> The largest three distinguishing factors are:
>> a) Guard optimizations for efficient handling of speculative code - this
>> has its biggest impact on the JavaScript, Ruby [2], and R [3]
>> implementations built on Graal’s multi-language framework Truffle.
>> b) Partial escape analysis to reduce object allocations even if the
>> object escapes on some paths.
>> c) Improved inlining strategy that explores the call tree and performs
>> late inlining as default instead of inlining during bytecode parsing.
>>
>> We expect to publish a new improved version of Graal in another OTN
>> release in the next couple of months.
>>
>> Regards, thomas
>>
>> [1]
>> http://www.oracle.com/technetwork/oracle-labs/program-languages/overview/index-2301583.html
>>
>> [2] https://github.com/jruby/jruby/wiki/Truffle
>> [3] https://bitbucket.org/allr/fastr
>>
>> On 13 Mar 2015, at 16:01, Vitaly Davidovich <vitalyd at gmail.com> wrote:
>>
>> Chris (or anyone else really),
>>
>> Are there any optimizations that graal does better (or at all) than
>> Hotspot's C2? I know it has flow sensitive EA - are there other things?
>>
>> Thanks
>>
>> sent from my phone
>> On Mar 13, 2015 9:53 AM, "Chris Seaton" <chris.seaton at oracle.com> wrote:
>>
>> Hi Bráulio,
>>
>> There’s no specific date yet of when Graal might be integrated into
>> OpenJDK.
>>
>> You can of course install a binary build of GraalVM, which isn’t much
>> different from installing an OpenJDK build
>> http://lafo.ssw.uni-linz.ac.at/builds <
>> http://lafo.ssw.uni-linz.ac.at/builds>. For the specific use case of
>> JRuby, the ruby-build plugin to rbenv can already install JRuby+Truffle,
>> with GraalVM bundled so all you have to do is run ‘run’ and you’ll get
>> Graal.
>>
>> $ rbenv install jruby-9.0.0.0+graal-dev
>> $ rbenv shell jruby-9.0.0.0+graal-dev
>> $ ruby -X+T -e 'puts Truffle.graal?'
>> true
>>
>> I think you can do something similar in RVM but not sure of the specifics
>> at the moment.
>>
>> If you are interested in JRuby+Truffle, join us in #jruby on Freenode IRC.
>>
>> Regards,
>>
>> Chris
>>
>> On 13 Mar 2015, at 00:45, Bráulio Bhavamitra <brauliobo at gmail.com>
>>
>> wrote:
>>
>>
>> Hello all,
>>
>> Sorry for asking this out of my anxiety...
>>
>> Having seen the incredible results when using the Graal VM with JRuby
>> Truffle, I wonder if and when Graal code will be merged into OpenJDK
>> mainline. Is there a roadmap or it is not going to happen soon (next
>>
>> years)?
>>
>>
>> cheers,
>> bráulio
>>
>> --
>> "Lute pela sua ideologia. Seja um com sua ideologia. Viva pela sua
>> ideologia. Morra por sua ideologia" P.R. Sarkar
>>
>> EITA - Educação, Informação e Tecnologias para Autogestão
>> http://cirandas.net/brauliobo
>> http://eita.org.br
>>
>> "Paramapurusha é meu pai e Parama Prakriti é minha mãe. O universo é meu
>> lar e todos nós somos cidadãos deste cosmo. Este universo é a imaginação
>>
>> da
>>
>> Mente Macrocósmica, e todas as entidades estão sendo criadas,
>>
>> preservadas e
>>
>> destruídas nas fases de extroversão e introversão do fluxo imaginativo
>> cósmico. No âmbito pessoal, quando uma pessoa imagina algo em sua mente,
>> naquele momento, essa pessoa é a única proprietária daquilo que ela
>> imagina, e ninguém mais. Quando um ser humano criado mentalmente caminha
>> por um milharal também imaginado, a pessoa imaginada não é a propriedade
>> desse milharal, pois ele pertence ao indivíduo que o está imaginando.
>>
>> Este
>>
>> universo foi criado na imaginação de Brahma, a Entidade Suprema, por isso
>> a propriedade deste universo é de Brahma, e não dos microcosmos que
>>
>> também
>>
>> foram criados pela imaginação de Brahma. Nenhuma propriedade deste mundo,
>> mutável ou imutável, pertence a um indivíduo em particular; tudo é o
>> patrimônio comum de todos."
>> Restante do texto em
>> http://cirandas.net/brauliobo/blog/a-problematica-de-hoje-em-dia
>>
>>
>>
>>
>>
>
>


More information about the graal-dev mailing list