src/share/vm/gc_implementation/g1/heapRegion.hpp
Print this page
rev 7056 : [mq]: 8058298
rev 7057 : imported patch review
@@ -774,46 +774,6 @@
// True after iteration if the closure was applied to all heap regions
// and returned "false" in all cases.
bool complete() { return _complete; }
};
-// The HeapRegionClaimer is used during parallel iteration over heap regions,
-// allowing workers to claim heap regions, gaining exclusive rights to these regions.
-class HeapRegionClaimer {
- uint _n_workers;
- uint _n_regions;
- uint* _claims;
-
- static const uint Unclaimed = 0;
- static const uint Claimed = 1;
-
- public:
- HeapRegionClaimer() : _n_workers(0), _n_regions(0), _claims(NULL) {}
-
- HeapRegionClaimer(uint n_workers) : _n_workers(n_workers), _n_regions(0), _claims(NULL) {
- initialize(n_workers);
- }
-
- ~HeapRegionClaimer() {
- if (_claims != NULL) {
- FREE_C_HEAP_ARRAY(uint, _claims, mtGC);
- }
- }
-
- inline uint n_regions() const {
- return _n_regions;
- }
-
- inline void initialize(uint n_workers);
-
- // Calculate the starting region for given worker so
- // that they do not all start from the same region.
- inline uint start_region_for_worker(uint worker_id) const;
-
- // Check if region has been claimed with this HRClaimer.
- inline bool is_region_claimed(uint region_index) const;
-
- // Claim the given region, returns true if successfully claimed.
- inline bool claim_region(uint region_index);
-};
-
#endif // SHARE_VM_GC_IMPLEMENTATION_G1_HEAPREGION_HPP