JDWP: Improve locking in doPendingTasks() after JDK-8274687

XMLWordPrintable

    • Type: Enhancement
    • Resolution: Not an Issue
    • Priority: P4
    • tbd
    • Affects Version/s: None
    • Component/s: core-svc
    • None

      JDK-8274687 will add the following fragment to doPendingTasks() in the JDWP agent:

              /*
               * trackAppResume() (indirectly) aquires handlerLock. For proper lock
               * ordering handlerLock has to be acquired before threadLock.
               */
              debugMonitorExit(threadLock);
              eventHandler_lock();
              debugMonitorEnter(threadLock);

      Investigate if this can be improved by hoisting the first monitor exit on threadLock up into the caller threadControl_onEventHandlerExit() such that doPendingTasks() would be called without any locks held.

            Assignee:
            Chris Plummer
            Reporter:
            Richard Reingruber
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: