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

start_VTMT and check_suspend_at_safepoint use oops in blocked state

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: repo-loom
    • Fix Version/s: repo-loom
    • Component/s: hotspot
    • Labels:
      None

      Description

      Below are the cases:

      jvmtiThreadState.cpp:
      JvmtiVTMTDisabler::start_VTMT(jthread vthread, int callsite_tag) {
         . . .
         while (true) {
            ThreadBlockInVM tbivm(thread);
            MonitorLocker ml(JvmtiVTMT_lock, Mutex::_no_safepoint_check_flag);

            // Do not allow suspends inside VTMT transitions.
            // Block while transitions are disabled or there are suspend requests.
            if (_VTMT_disable_count > 0 ||
                thread->is_suspended() ||
                JvmtiVTSuspender::is_vthread_suspended(vth()) <== ???

      jvmtiExport.cpp:
      void JvmtiExport::check_suspend_at_safepoint(JavaThread *thread) {
          . . .
          // block while vthread is externally suspended
          while (JvmtiVTSuspender::is_vthread_suspended(vth())) { <== ???
            ml.wait();
          }
        }
      }

        Attachments

          Activity

            People

            Assignee:
            sspitsyn Serguei Spitsyn
            Reporter:
            sspitsyn Serguei Spitsyn
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: