comparison src/share/vm/memory/space.hpp @ 20266:6c523f5d5440

8038412: Move object_iterate_careful down from Space to ContigousSpace and CFLSpace Summary: Only declare the functions where they are actually needed. Reviewed-by: tschatzl, stefank
author mgerdin
date Wed, 12 Mar 2014 17:13:48 +0100
parents 5255b195f828
children ff1e37e7eb83
comparison
equal deleted inserted replaced
20265:5255b195f828 20266:6c523f5d5440
186 virtual void object_iterate(ObjectClosure* blk) = 0; 186 virtual void object_iterate(ObjectClosure* blk) = 0;
187 // Similar to object_iterate() except only iterates over 187 // Similar to object_iterate() except only iterates over
188 // objects whose internal references point to objects in the space. 188 // objects whose internal references point to objects in the space.
189 virtual void safe_object_iterate(ObjectClosure* blk) = 0; 189 virtual void safe_object_iterate(ObjectClosure* blk) = 0;
190 190
191 // Iterate over as many initialized objects in the space as possible,
192 // calling "cl.do_object_careful" on each. Return NULL if all objects
193 // in the space (at the start of the iteration) were iterated over.
194 // Return an address indicating the extent of the iteration in the
195 // event that the iteration had to return because of finding an
196 // uninitialized object in the space, or if the closure "cl"
197 // signalled early termination.
198 virtual HeapWord* object_iterate_careful(ObjectClosureCareful* cl);
199 virtual HeapWord* object_iterate_careful_m(MemRegion mr,
200 ObjectClosureCareful* cl);
201
202 // Create and return a new dirty card to oop closure. Can be 191 // Create and return a new dirty card to oop closure. Can be
203 // overriden to return the appropriate type of closure 192 // overriden to return the appropriate type of closure
204 // depending on the type of space in which the closure will 193 // depending on the type of space in which the closure will
205 // operate. ResourceArea allocated. 194 // operate. ResourceArea allocated.
206 virtual DirtyCardToOopClosure* new_dcto_cl(ExtendedOopClosure* cl, 195 virtual DirtyCardToOopClosure* new_dcto_cl(ExtendedOopClosure* cl,
549 void oop_iterate(ExtendedOopClosure* cl); 538 void oop_iterate(ExtendedOopClosure* cl);
550 void object_iterate(ObjectClosure* blk); 539 void object_iterate(ObjectClosure* blk);
551 // For contiguous spaces this method will iterate safely over objects 540 // For contiguous spaces this method will iterate safely over objects
552 // in the space (i.e., between bottom and top) when at a safepoint. 541 // in the space (i.e., between bottom and top) when at a safepoint.
553 void safe_object_iterate(ObjectClosure* blk); 542 void safe_object_iterate(ObjectClosure* blk);
554 // iterates on objects up to the safe limit 543
544 // Iterate over as many initialized objects in the space as possible,
545 // calling "cl.do_object_careful" on each. Return NULL if all objects
546 // in the space (at the start of the iteration) were iterated over.
547 // Return an address indicating the extent of the iteration in the
548 // event that the iteration had to return because of finding an
549 // uninitialized object in the space, or if the closure "cl"
550 // signaled early termination.
555 HeapWord* object_iterate_careful(ObjectClosureCareful* cl); 551 HeapWord* object_iterate_careful(ObjectClosureCareful* cl);
556 HeapWord* concurrent_iteration_safe_limit() { 552 HeapWord* concurrent_iteration_safe_limit() {
557 assert(_concurrent_iteration_safe_limit <= top(), 553 assert(_concurrent_iteration_safe_limit <= top(),
558 "_concurrent_iteration_safe_limit update missed"); 554 "_concurrent_iteration_safe_limit update missed");
559 return _concurrent_iteration_safe_limit; 555 return _concurrent_iteration_safe_limit;