JDK-8316862 : assert(false) failed: bad AD file
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 8u381
  • Priority: P4
  • Status: Closed
  • Resolution: Duplicate
  • OS: generic
  • CPU: x86_64
  • Submitted: 2023-09-20
  • Updated: 2024-06-28
  • Resolved: 2024-06-28
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
tbdResolved
Related Reports
Duplicate :  
Description
ADDITIONAL SYSTEM INFORMATION :
# JRE version: OpenJDK Runtime Environment (8.0_392) (build 1.8.0_392-internal-fastdebug_2023_09_20_15_15-b00)
# Java VM: OpenJDK 64-Bit Server VM (25.392-b00-fastdebug mixed mode linux-amd64 compressed oops)
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#

A DESCRIPTION OF THE PROBLEM :
I ran a regression case using JDK 8u392, I found it crashes the JVM under option -XX:LoopOptsCount=5

# A fatal error has been detected by the Java Runtime Environment:
#
#  Internal Error (/data/xzf/jdk8u/hotspot/src/share/vm/opto/matcher.cpp:1592), pid=9052, tid=0x00007f3f2f464700
#  assert(false) failed: bad AD file
#
# JRE version: OpenJDK Runtime Environment (8.0_392) (build 1.8.0_392-internal-fastdebug_2023_09_20_15_15-b00)
# Java VM: OpenJDK 64-Bit Server VM (25.392-b00-fastdebug mixed mode linux-amd64 compressed oops)
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.java.com/bugreport/crash.jsp

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
java  -XX:LoopOptsCount=5   Test6559156

EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
No failure
ACTUAL -
   opcode  = 154, "LoopLimit"
o239    LoopLimit       === _ o271 o231  [[o214 o168  69 ]] 

--N: o239       LoopLimit       === _ o271 o231  [[o214 o168  69 ]] 

   --N: o271    Binary  === _ o180 o211  [[o239 ]] 
   _Binary_rRegI_rRegI  0  _Binary_rRegI_rRegI
   _Binary_rax_RegI_rRegI  0  _Binary_rax_RegI_rRegI

      --N: o180 CastII  === o178 o155  [[o271 ]]  #int:<=max-1:www carry dependency
      RREGI  0  castII
      RAX_REGI  0  castII
      RBX_REGI  0  castII
      RCX_REGI  0  castII
      RDX_REGI  0  castII
      RDI_REGI  0  castII
      NO_RCX_REGI  0  castII
      NO_RAX_RDX_REGI  0  castII
      STACKSLOTI  100  storeSSI

         --N: o155      AddI    === _ o159 o45  [[o154 o159 o168 o175 o180 ]] 
         RREGI  0  RREGI
         RAX_REGI  0  RAX_REGI
         RBX_REGI  0  RBX_REGI
         RCX_REGI  0  RCX_REGI
         RDX_REGI  0  RDX_REGI
         RDI_REGI  0  RDI_REGI
         NO_RCX_REGI  0  NO_RCX_REGI
         NO_RAX_RDX_REGI  0  NO_RAX_RDX_REGI
         STACKSLOTI  100  storeSSI

      --N: o211 CMoveI  === _ o269 o270  [[o271 o175 ]]  #int
      RREGI  0  RREGI
      RAX_REGI  0  RAX_REGI
      RBX_REGI  0  RBX_REGI
      RCX_REGI  0  RCX_REGI
      RDX_REGI  0  RDX_REGI
      RDI_REGI  0  RDI_REGI
      NO_RCX_REGI  0  NO_RCX_REGI
      NO_RAX_RDX_REGI  0  NO_RAX_RDX_REGI
      STACKSLOTI  100  storeSSI

   --N: o231    ConI    === o0  [[o239 ]]  #int:2
   IMMI  10  IMMI
   IMMI2  0  IMMI2
   IMMI8  5  IMMI8
   IMMI16  10  IMMI16
   IMMU31  0  IMMU31
   RREGI  100  loadConI
   RAX_REGI  100  loadConI
   RBX_REGI  100  loadConI
   RCX_REGI  100  loadConI
   RDX_REGI  100  loadConI
   RDI_REGI  100  loadConI
   NO_RCX_REGI  100  loadConI
   NO_RAX_RDX_REGI  100  loadConI
   STACKSLOTI  200  storeSSI

# To suppress the following error report, specify this argument
# after -XX: or in .hotspotrc:  SuppressErrorAt=/matcher.cpp:1592
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  Internal Error (/data/xzf/jdk8u/hotspot/src/share/vm/opto/matcher.cpp:1592), pid=55443, tid=0x00007fb817868700
#  assert(false) failed: bad AD file
#
# JRE version: OpenJDK Runtime Environment (8.0_392) (build 1.8.0_392-internal-fastdebug_2023_09_20_15_15-b00)
# Java VM: OpenJDK 64-Bit Server VM (25.392-b00-fastdebug mixed mode linux-amd64 compressed oops)
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# An error report file with more information is saved as:
# /home/repository/bugs/Test6559156_09_20_16_07_30/hs_err_pid55443.log
No failure
^[[D#
# Compiler replay data is saved as:
# /home/repository/bugs/Test6559156_09_20_16_07_30/replay_pid55443.log
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.java.com/bugreport/crash.jsp
#
Current thread is 140428645402368
Dumping core ...

---------- BEGIN SOURCE ----------

---------- END SOURCE ----------

FREQUENCY : always



Comments
I don't find this issue in jdk11, it must have been fixed in later releases. We may need to identify the right fix and backport that.
26-09-2023

Issue is reproduced. Crash is observed on JDK 8 debug build. OS: Windows 10 JDK 8u381: Pass JDK 8u381 Fastdebug: Fail ILW = Crash, reproducible on debug build, no known workaround yet = MLM = P4 Moving it to dev team for further analysis.
25-09-2023