[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openjdk-serviceability-dev
Subject:    RFR (XS): 8244571: assert(!_thread->is_pending_jni_exception_check()) failed: Pending JNI Exception 
From:       "serguei.spitsyn () oracle ! com" <serguei ! spitsyn () oracle ! com>
Date:       2020-05-19 16:28:59
Message-ID: 994efe77-fad2-66ae-7546-4d4a184803a7 () oracle ! com
[Download RAW message or body]

<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  </head>
  <body>
    <font face="Monaco">Please, review fix for:<br>
        <a class="moz-txt-link-freetext" \
href="https://bugs.openjdk.java.net/browse/JDK-8244571">https://bugs.openjdk.java.net/browse/JDK-8244571</a><br>
  <br>
      Webrev:<br>
       
<a class="moz-txt-link-freetext" \
href="http://cr.openjdk.java.net/~sspitsyn/webrevs/2020/8244571-jvmti-test-jnicheck.1/ \
">http://cr.openjdk.java.net/~sspitsyn/webrevs/2020/8244571-jvmti-test-jnicheck.1/</a><br>
  <br>
      Summary:<br>
        There are two places in the native part of test that cause
      assert and WARNING with the -Xcheck:jni.<br>
        The assert is because there is no check for pending exception
      after the call to:<br>
           </font><span class="removed">jni-&gt;CallBooleanMethod(klass,
      is_hid_mid);<br>
        Using a </span><span class="new">JNI ExceptionCheck()</span><span
      class="removed"> after the call fixes the issue.<br>
      <br>
        The following call to the JVM TI function:<br>
           </span>err = jvmti-&gt;GetClassLoaderClasses(loader,
    &amp;count, &amp;loader_classes);<br>
      produces the warning (with a java level stack trace): WARNING: JNI
    local refs: 94, exceeds capacity: 32<br>
      It is because the GetClassLoaderClasses returns an array of local
    references to the loader classes.<br>
      Using a JNI <span class="new">EnsureLocalCapacity() before the
      JVM TI call also fixes the issue.<br>
      <br>
      Testing:<br>
        Running the test</span>
    test/hotspot/jtreg/serviceability/jvmti/HiddenClass <span
      class="new"></span><span class="new">locally.<br>
        Will run a mach5 job as well.<br>
      <br>
      Thanks,<br>
      Serguei<br>
    </span><br>
    <br>
    <br>
    <span class="removed"></span>
  </body>
</html>


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic