Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Clarify SafepointSynchronize::is_cleanup_needed() and SafepointSynchronize::do_cleanup_tasks().

...

  • Changes to the safepoint deflation mechanism by the Async Monitor Deflation project (when async deflation is enabled):
    • If System.gc() is called, then a special deflation request is made which invokes the safepoint deflation mechanism.
    • Added the AsyncDeflationInterval diagnostic option (default 250 millis, 0 means off) to prevent MonitorUsedDeflationThreshold requests from swamping the ServiceThread.
      • Description: Async deflate idle monitors every so many milliseconds when MonitorUsedDeflationThreshold is exceeded (0 is off).
      • A special deflation request can cause an async deflation to happen sooner than AsyncDeflationInterval.
    • SafepointSynchronize::dois_cleanup_tasksneeded() now calls:
      • ObjectSynchronizer::is_safepoint_deflation_needed() instead of ObjectSynchronizer::is_cleanup_needed().
      • is_safepoint_deflation_needed() returns true only if a special deflation request is made (see above).
    • SafepointSynchronize::do_cleanup_tasks() now (indirectly) calls:
      • ObjectSynchronizer::do_safepoint_work() instead of ObjectSynchronizer::deflate_idle_monitors().
      • do_cleanup_tasks() can be called for non deflation related cleanup reasons and that will still result in a call to do_safepoint_work().
    • ObjectSynchronizer::do_safepoint_work() only does the safepoint cleanup tasks if there is a special deflation request. Otherwise it just sets the is_async_deflation_requested flag and notifies the ServiceThread.
    • ObjectSynchronizer::deflate_idle_monitors() and ObjectSynchronizer::deflate_thread_local_monitors() do nothing unless there is a special deflation request.

...