Graal: Please improve jshell startup performance by AOT compilation by 500x

Created on 24 Jul 2018  路  6Comments  路  Source: oracle/graal

https://twitter.com/deepities/status/1021711693586554881

jshell startup time measurement

Please compile jshell ahead of time to get the startup from ~5sec to somewhere around ~10ms.

feature performance

Most helpful comment

Challenge accepted.

All 6 comments

Challenge accepted.

But is this even realistic to achieve?

screenshot_2018-07-26_00-46-43

Simple AOT compiled HelloWorld I executed on the same oldish laptop I executed jshell on. Obviously this is a minimal example and jshell is probably quite complex. I wonder what jshell is doing, because ~5sec. seems awfully long. Maybe will do some digging later.

I take that back, this is possible! :heart:

My assumption is that jshell is running quite some initialization code and also loads javac. The main technical challenge for us will be to load and interpret the dynamically generated bytecodes. This is a functionality that we miss at this point in time in native image mode, but it is under active development.

I came here trying to find out how I can bake JShell into a Native Image. As of 2020-10-28 the docs on Dynamic Proxy in Native Image state:

Native Image does not provide machinery for generating and interpreting bytecodes at run time. Therefore all dynamic proxy classes need to be generated at native image build time.

The way I understand things, this is a requirement for JShell, since it needs to generate and interpret bytecode at run time. So, no significant progress here, right?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

helloguo picture helloguo  路  3Comments

koduki picture koduki  路  3Comments

borkdude picture borkdude  路  3Comments

sdeleuze picture sdeleuze  路  3Comments

himanshumps picture himanshumps  路  3Comments