JDK-6805029 : ParOld can miss compacting of regions if each GC threads does not get a drain-stack task.
  • Type: Bug
  • Component: hotspot
  • Sub-Component: gc
  • Affected Version: 7
  • Priority: P4
  • Status: Closed
  • Resolution: Not an Issue
  • OS: generic
  • CPU: generic
  • Submitted: 2009-02-12
  • Updated: 2021-05-17
  • Resolved: 2009-02-25
Related Reports
Relates :  
Description
In the compaction phase of UseParallelOldGC regions may not be processed if
each GC threads does not execute a DrainStacksCompactionTask.
I tried to provoke this bug by putting a sleep into get_task()
after the wait() for worker 0.  I release the monitor before
the sleep.  I expected this to delay worker 0 long enough
such that all the drain-tasks were taken and executed.  That
does seem to have haven't but the bug did not manifest itself.
I think now that the task strealing will take care of regions
that on the stack as  long as those regions are stealable.
In the current code base it looks like the local overflow
stacks are not used. In taskqueue.hpp I find

#define USE_RegionTaskQueueWithOverflow

which would preclude the use of an overflow stack.
I'll be investigating this a little more so won't close
this yet but am lowering the priority.

Comments
EVALUATION Each GC thread has to run a stealing task and for the compaction phase the stealing tasks first drain their own stacks. Therefore no stacks will be missed.
25-02-2009