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

Remove GCLocker::_doing_gc

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P4 P4
    • 17
    • 14
    • hotspot
    • gc
    • b11

      GCLocker has private bool _doing_gc. It is set to true around the gclocker call to heap()->collect() in jni_unlock. The only reference is in jni_lock, where it is used to extend the wait that conditionally blocks entry to the critical region. But all _doing_gc is doing there is effectively extending the blocking period from active && needs_gc to also include inactive && needs_gc, i.e. making the blocking period the same as the needs_gc period. So the blocking predicate can be changed to needs_gc() and the _doing_gc flag can then be removed.

            ayang Albert Yang
            kbarrett Kim Barrett
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: