Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8316950

C2: assert(_base == Int) failed: Not an Int

XMLWordPrintable

    • generic
    • generic

      ADDITIONAL SYSTEM INFORMATION :
      # JRE version: OpenJDK Runtime Environment (8.0_392) (build 1.8.0_392-internal-fastdebug-
      -b00)
      # Java VM: OpenJDK 64-Bit Server VM (25.392-b00-fastdebug compiled mode linux-amd64 compressed oops)

      A DESCRIPTION OF THE PROBLEM :
      I ran a regression test on JDK8u392 and found that the JVM crashed without any options.

      #
      # A fatal error has been detected by the Java Runtime Environment:
      #
      # Internal Error (/data//jdk8u/hotspot/src/share/vm/opto/type.hpp:1492), pid=2385, tid=0x00007f5904e3e700
      # assert(_base == Int) failed: Not an Int
      #
      # JRE version: OpenJDK Runtime Environment (8.0_392) (build 1.8.0_392-internal-fastdebug-
      -b00)
      # Java VM: OpenJDK 64-Bit Server VM (25.392-b00-fastdebug compiled 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 compiler.arraycopy.TestNegArrayLengthAsIndex1

      ACTUAL -
      # To suppress the following error report, specify this argument
      # after -XX: or in .hotspotrc: SuppressErrorAt=/type.hpp:1492
      #
      # A fatal error has been detected by the Java Runtime Environment:
      #
      # Internal Error (/data//jdk8u/hotspot/src/share/vm/opto/type.hpp:1492), pid=66975, tid=0x00007f6399f4f700
      # assert(_base == Int) failed: Not an Int
      #
      # JRE version: OpenJDK Runtime Environment (8.0_392) (build 1.8.0_392-internal-fastdebug--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//toreport/TestNegArrayLengthAsIndex1_09_22_23_51_27/hs_err_pid66975.log
      #
      # Compiler replay data is saved as:
      # /home//repository//toreport/TestNegArrayLengthAsIndex1_09_22_23_51_27/replay_pid66975.log
      #
      # If you would like to submit a bug report, please visit:
      # http://bugreport.java.com/bugreport/crash.jsp
      #

      ---------- BEGIN SOURCE ----------
      package compiler.arraycopy;
      public class TestNegArrayLengthAsIndex1 {

          public static void main(String[] args) throws Exception {
              for (int i = 0; i < 10000; i++) {
                  foo();
              }
          }


          static int foo() {
              int minusOne = -1;
              int[] a = null;
              try {
                  a = new int[minusOne];
              } catch (NegativeArraySizeException e) {
                 return 0;
              }
              return a[a.length - 1];
          }
      }
      ---------- END SOURCE ----------

      FREQUENCY : always


            Unassigned Unassigned
            webbuggrp Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: