Has --dump-debug-dir behaviour changed in JDK9?

Chris Newland cnewland at chrisnewland.com
Tue Jun 9 21:25:26 UTC 2015


Hi,

Has Nashorn's behaviour for dumping bytecode changed in JDK9?

Given this JavaScript:
https://gist.github.com/chriswhocodes/bfe139592adb846967d8

Executed using
$JAVA_HOME/bin/jjs -co --dump-debug-dir=. run.js

Under 8u60b18 the bytecode is produced as expected:

https://gist.github.com/chriswhocodes/e3a85c3613b084e45356

This visualises correctly in JITWatch[1] and the bytecode maps back to the
source as expected.

But under 9b67 only a small amount of bytecode is output that doesn't
represent the source program:

https://gist.github.com/chriswhocodes/c6c6e33e7994c98d4975

The correct program output is produced under both executions so I don't
think the difference is down to dead code elimination.

Possible regression?

Thanks,

Chris
@chriswhocodes

[1] https://github.com/AdoptOpenJDK/jitwatch




More information about the nashorn-dev mailing list