481 unsigned int total_collections() const { return _total_collections; } 482 unsigned int total_full_collections() const { return _total_full_collections;} 483 484 // Increment total number of GC collections (started) 485 // Should be protected but used by PSMarkSweep - cleanup for 1.4.2 486 void increment_total_collections(bool full = false) { 487 _total_collections++; 488 if (full) { 489 increment_total_full_collections(); 490 } 491 } 492 493 void increment_total_full_collections() { _total_full_collections++; } 494 495 // Return the AdaptiveSizePolicy for the heap. 496 virtual AdaptiveSizePolicy* size_policy() = 0; 497 498 // Return the CollectorPolicy for the heap 499 virtual CollectorPolicy* collector_policy() const = 0; 500 501 void oop_iterate_no_header(OopClosure* cl); 502 503 // Iterate over all the ref-containing fields of all objects, calling 504 // "cl.do_oop" on each. 505 virtual void oop_iterate(ExtendedOopClosure* cl) = 0; 506 507 // Iterate over all objects, calling "cl.do_object" on each. 508 virtual void object_iterate(ObjectClosure* cl) = 0; 509 510 // Similar to object_iterate() except iterates only 511 // over live objects. 512 virtual void safe_object_iterate(ObjectClosure* cl) = 0; 513 514 // NOTE! There is no requirement that a collector implement these 515 // functions. 516 // 517 // A CollectedHeap is divided into a dense sequence of "blocks"; that is, 518 // each address in the (reserved) heap is a member of exactly 519 // one block. The defining characteristic of a block is that it is 520 // possible to find its size, and thus to progress forward to the next 521 // block. (Blocks may be of different sizes.) Thus, blocks may 522 // represent Java objects, or they might be free blocks in a 523 // free-list-based heap (or subheap), as long as the two kinds are 524 // distinguishable and the size of each is determinable. 525 526 // Returns the address of the start of the "block" that contains the | 481 unsigned int total_collections() const { return _total_collections; } 482 unsigned int total_full_collections() const { return _total_full_collections;} 483 484 // Increment total number of GC collections (started) 485 // Should be protected but used by PSMarkSweep - cleanup for 1.4.2 486 void increment_total_collections(bool full = false) { 487 _total_collections++; 488 if (full) { 489 increment_total_full_collections(); 490 } 491 } 492 493 void increment_total_full_collections() { _total_full_collections++; } 494 495 // Return the AdaptiveSizePolicy for the heap. 496 virtual AdaptiveSizePolicy* size_policy() = 0; 497 498 // Return the CollectorPolicy for the heap 499 virtual CollectorPolicy* collector_policy() const = 0; 500 501 // Iterate over all objects, calling "cl.do_object" on each. 502 virtual void object_iterate(ObjectClosure* cl) = 0; 503 504 // Similar to object_iterate() except iterates only 505 // over live objects. 506 virtual void safe_object_iterate(ObjectClosure* cl) = 0; 507 508 // NOTE! There is no requirement that a collector implement these 509 // functions. 510 // 511 // A CollectedHeap is divided into a dense sequence of "blocks"; that is, 512 // each address in the (reserved) heap is a member of exactly 513 // one block. The defining characteristic of a block is that it is 514 // possible to find its size, and thus to progress forward to the next 515 // block. (Blocks may be of different sizes.) Thus, blocks may 516 // represent Java objects, or they might be free blocks in a 517 // free-list-based heap (or subheap), as long as the two kinds are 518 // distinguishable and the size of each is determinable. 519 520 // Returns the address of the start of the "block" that contains the |