109 while (!_marking_stack->is_empty()) { |
109 while (!_marking_stack->is_empty()) { |
110 oop obj = _marking_stack->pop(); |
110 oop obj = _marking_stack->pop(); |
111 assert (obj->is_gc_marked(), "p must be marked"); |
111 assert (obj->is_gc_marked(), "p must be marked"); |
112 obj->follow_contents(); |
112 obj->follow_contents(); |
113 } |
113 } |
114 while (!_objarray_stack->is_empty()) { |
114 // Process ObjArrays one at a time to avoid marking stack bloat. |
|
115 if (!_objarray_stack->is_empty()) { |
115 ObjArrayTask task = _objarray_stack->pop(); |
116 ObjArrayTask task = _objarray_stack->pop(); |
116 objArrayKlass* const k = (objArrayKlass*)task.obj()->blueprint(); |
117 objArrayKlass* const k = (objArrayKlass*)task.obj()->blueprint(); |
117 k->oop_follow_contents(task.obj(), task.index()); |
118 k->oop_follow_contents(task.obj(), task.index()); |
118 } |
119 } |
119 } while (!_marking_stack->is_empty() || !_objarray_stack->is_empty()); |
120 } while (!_marking_stack->is_empty() || !_objarray_stack->is_empty()); |