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

Make it safe for JFR thread to read threadObj

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 16
    • Component/s: hotspot
    • Labels:
      None
    • Subcomponent:
      gc
    • Resolved In Build:
      b15

      Description

      Since the thread oop moved to OopStorage, a bug was introduced. The oop is now read with load barriers. If the JFR thread shoots a thread that holds a load barrier lock, it is stuck holding that lock. Then the JFR thread tries to read the threadObj(), which might grab the same lock. This causes a deadlock.
      There are also some ZGC asserts that fire, not expecting relocation to happen from an unknown non-Java thread.
      I had fixes for said problems in my own concurrent stack scanning branch, but forgot to point it out in the review thread for JDK-8244997.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              eosterlund Erik Ă–sterlund
              Reporter:
              eosterlund Erik Ă–sterlund
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: