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

IndexOutOfBoundsException in HeapByteBufferTest.java

XMLWordPrintable

    • b64
    • generic
    • generic

        During some jtreg testing I got next failure on macos-x64 fastdebug:

        command: main -XX:+UnlockDiagnosticVMOptions -XX:-UseUnalignedAccesses HeapByteBufferTest
        reason: User specified action: run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:-UseUnalignedAccesses HeapByteBufferTest
        elapsed time (seconds): 4.259
        STDOUT:
        STDERR:
        java.lang.IndexOutOfBoundsException
        at java.nio.Buffer.checkIndex(Buffer.java:546)
        at java.nio.HeapByteBuffer.getShort(HeapByteBuffer.java:331)
        at MyByteBuffer.getShort(HeapByteBufferTest.java:214)
        at HeapByteBufferTest.step(HeapByteBufferTest.java:300)
        at HeapByteBufferTest.run(HeapByteBufferTest.java:355)
        at HeapByteBufferTest.main(HeapByteBufferTest.java:370)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)


        I was not able to reproduce it. We need to use our random generator Utils.getRandomInstance() to know what seed to use for reproduction.
        And also instead of random test all range of indexes.

              thartmann Tobias Hartmann
              kvn Vladimir Kozlov
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: