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

Test serviceability/HeapDump/UnmountedVThreadNativeMethodAtTop.java should mark as /native

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P4 P4
    • 26
    • 25, 26
    • hotspot
    • None
    • svc
    • master
    • generic
    • generic

      jtreg serviceability/HeapDump/UnmountedVThreadNativeMethodAtTop.java will report failure as below.

      STDERR:
      STARTED UnmountedVThreadNativeMethodAtTop::VThreadBlockedAtSynchronizedNative 'VThreadBlockedAtSynchronizedNative()'
      java.lang.UnsatisfiedLinkError: no UnmountedVThreadNativeMethodAtTop in java.library.path: /usr/java/packages/lib:/usr/lib64:/lib64:/lib:/usr/lib
              at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2285)
              at java.base/java.lang.Runtime.loadLibrary0(Runtime.java:822)
              at java.base/java.lang.System.loadLibrary(System.java:1685)
              at UnmountedVThreadNativeMethodAtTop.<clinit>(UnmountedVThreadNativeMethodAtTop.java:164)
              at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized0(Native Method)
              at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized(Unsafe.java:1169)
              at java.base/java.lang.reflect.Constructor.acquireConstructorAccessor(Constructor.java:546)
              at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:496)
              at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:483)
              at java.base/java.util.Optional.orElseGet(Optional.java:364)
              at java.base/java.util.ArrayList.forEach(ArrayList.java:1604)
              at java.base/java.util.ArrayList.forEach(ArrayList.java:1604)
      FAILED UnmountedVThreadNativeMethodAtTop::VThreadBlockedAtSynchronizedNative 'VThreadBlockedAtSynchronizedNative()' [4ms]
      STARTED UnmountedVThreadNativeMethodAtTop::VThreadBlockedAtOjectWait 'VThreadBlockedAtOjectWait()'
      java.lang.NoClassDefFoundError: Could not initialize class UnmountedVThreadNativeMethodAtTop
              at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized0(Native Method)
              at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized(Unsafe.java:1169)
              at java.base/java.lang.reflect.Constructor.acquireConstructorAccessor(Constructor.java:546)
              at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:496)
              at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:483)
              at java.base/java.util.Optional.orElseGet(Optional.java:364)
              at java.base/java.util.ArrayList.forEach(ArrayList.java:1604)
              at java.base/java.util.ArrayList.forEach(ArrayList.java:1604)
      Caused by: java.lang.ExceptionInInitializerError: Exception java.lang.UnsatisfiedLinkError: no UnmountedVThreadNativeMethodAtTop in java.library.path: /usr/java/packages/lib:/usr/lib64:/lib64:/lib:/usr/lib [in thread "MainThread"]
              at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2285)
              at java.base/java.lang.Runtime.loadLibrary0(Runtime.java:822)
              at java.base/java.lang.System.loadLibrary(System.java:1685)
              at UnmountedVThreadNativeMethodAtTop.<clinit>(UnmountedVThreadNativeMethodAtTop.java:164)
              ... 8 more
      FAILED UnmountedVThreadNativeMethodAtTop::VThreadBlockedAtOjectWait 'VThreadBlockedAtOjectWait()' [1ms]
      JavaTest Message: JUnit Platform Failure(s): 2

      [ JUnit Containers: found 4, started 4, succeeded 4, failed 0, aborted 0, skipped 0]
      [ JUnit Tests: found 2, started 2, succeeded 0, failed 2, aborted 0, skipped 0]

      java.lang.Exception: JUnit test failure
              at com.sun.javatest.regtest.agent.JUnitRunner.runWithJUnitPlatform(JUnitRunner.java:179)
              at com.sun.javatest.regtest.agent.JUnitRunner.main(JUnitRunner.java:110)
              at com.sun.javatest.regtest.agent.JUnitRunner.main(JUnitRunner.java:76)

            syan Sendao Yan
            syan Sendao Yan
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: