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

hotspot runtime compiler can't handle legal bytecode generated by Jikes compiler properly

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: P4 P4
    • None
    • 1.4.2_08
    • hotspot
    • sparc
    • solaris

      Compile the test program below with jikes and run with a fastdebug build with those options

      java -server -Xcomp -XX:CompileOnly=ArrayClone.clone ArrayClone

      You will see this assertion failure.

      VM option 'CompileOnly=ArrayClone.clone'
      # To suppress the following error report, specify this argument
      # after -XX: or in .hotspotrc: SuppressErrorAt=/ciObject.hpp:182
      #
      # HotSpot Virtual Machine Error, assertion failure
      # Please report this error at
      # http://java.sun.com/cgi-bin/bugreport.cgi
      #
      # Java VM: Java HotSpot(TM) Server VM (1.4.1-internal-debug compiled mode)
      #
      # assert(is_instance_klass(), "bad cast")
      #
      # Error ID: /jle_extra/jpe_dev/mma/j2se/sol/1.4.2_08/hotspot/src/share/vm/ci/ciObject.hpp, 182 [ Patched ]
      #
      # Problematic Thread: prio=5 tid=0x00124308 nid=0x8 runnable
      #

      The test program:

      class ArrayClone implements Cloneable {

        private transient double[] _values;

        public ArrayClone(int count) {
          _values = new double[count];
        }

        public Object clone() {
          try {
            // make a deep copy
            ArrayClone c = (ArrayClone)super.clone();
            c._values = (double[])this._values.clone();
            return c;
          } catch (Throwable t) {
            t.printStackTrace();
          }
          return null;
        }

        public static void main(String args[]) {
          ArrayClone ac = new ArrayClone(12);
          ArrayClone ac2 = (ArrayClone)ac.clone();
          System.err.println(ac);
          System.err.println(ac2);
        }
      }


      ###@###.### 2005-05-17 18:30:58 GMT

            chrisphi Chris Phillips
            mmma Marvin Ma (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: