JDK-8019313 : Server VM crash when running with -XX:+PrintInlining
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: hs25
  • Priority: P3
  • Status: Closed
  • Resolution: Not an Issue
  • OS: generic
  • CPU: generic
  • Submitted: 2013-06-27
  • Updated: 2013-09-20
  • Resolved: 2013-07-03
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
Other
hs25Resolved
Related Reports
Relates :  
Description
Hi,

I'd like to propose a fix for a JIT crash when running the VM with -XX:+PrintInlining:

Bug: 
In Compile::dump_inlining(), the late inlining list is traversed and the corresponding callGenerator is searched in the _print_linlining_list. The VM then crashes with a "ShouldNotReachHere()" in Compile::print_inlining_insert() because the callGenerator is not found in the _print_inlining_list.

Reason:
- In Compile::print_inlining_skip(), the CallGenerator is not annotated at the actual _print_inlining_list array entry (type "PrintInliningBuffer") but at a copy of the entry which gets discarded.
- Thus, Compile::print_inlining_insert() would not find the annotated CallGenerator ptr any more and run into the ShouldNotReachHere() case.
- Fix: Get the print_inlining_buffer entry by reference instead of by value in order to avoid copying the entry

Here's a webrev containing the fix:
http://cr.openjdk.java.net/~goetz/webrevs/fix_inline_trace/

Best regards,
Andreas

Comments
From Andreas: I fixed this in an older version of OpenJDK which used this declaration of GrowableArray::at() E at(int i) const { ... which returns a copy and didn't realize that the declaration changed in the current OpenJDK version: E& at(int i) const { ... :-( which does not return a copy. So, you're right, in the current OpenJDK version, this issue is already fixed (using a more general solution :) and my patch is not necessary any more...
03-07-2013

Roland, please, review and sponsor this fix. Thanks!
27-06-2013