Mercurial > hg > graal-jvmci-8
comparison src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp @ 20309:a08bb8e45ba1
8054341: Remove some obsolete code in G1CollectedHeap class
Summary: Remove dead code.
Reviewed-by: stefank, brutisso
author | tschatzl |
---|---|
date | Thu, 07 Aug 2014 22:28:53 +0200 |
parents | 04d77ac27223 |
children | bfba6779654b |
comparison
equal
deleted
inserted
replaced
20308:9b093813caa9 | 20309:a08bb8e45ba1 |
---|---|
2587 } | 2587 } |
2588 } | 2588 } |
2589 | 2589 |
2590 // Iteration functions. | 2590 // Iteration functions. |
2591 | 2591 |
2592 // Iterates an OopClosure over all ref-containing fields of objects | 2592 // Applies an ExtendedOopClosure onto all references of objects within a HeapRegion. |
2593 // within a HeapRegion. | |
2594 | 2593 |
2595 class IterateOopClosureRegionClosure: public HeapRegionClosure { | 2594 class IterateOopClosureRegionClosure: public HeapRegionClosure { |
2596 MemRegion _mr; | |
2597 ExtendedOopClosure* _cl; | 2595 ExtendedOopClosure* _cl; |
2598 public: | 2596 public: |
2599 IterateOopClosureRegionClosure(MemRegion mr, ExtendedOopClosure* cl) | 2597 IterateOopClosureRegionClosure(ExtendedOopClosure* cl) : _cl(cl) {} |
2600 : _mr(mr), _cl(cl) {} | |
2601 bool doHeapRegion(HeapRegion* r) { | 2598 bool doHeapRegion(HeapRegion* r) { |
2602 if (!r->continuesHumongous()) { | 2599 if (!r->continuesHumongous()) { |
2603 r->oop_iterate(_cl); | 2600 r->oop_iterate(_cl); |
2604 } | 2601 } |
2605 return false; | 2602 return false; |
2606 } | 2603 } |
2607 }; | 2604 }; |
2608 | 2605 |
2609 void G1CollectedHeap::oop_iterate(ExtendedOopClosure* cl) { | 2606 void G1CollectedHeap::oop_iterate(ExtendedOopClosure* cl) { |
2610 IterateOopClosureRegionClosure blk(_g1_committed, cl); | 2607 IterateOopClosureRegionClosure blk(cl); |
2611 heap_region_iterate(&blk); | |
2612 } | |
2613 | |
2614 void G1CollectedHeap::oop_iterate(MemRegion mr, ExtendedOopClosure* cl) { | |
2615 IterateOopClosureRegionClosure blk(mr, cl); | |
2616 heap_region_iterate(&blk); | 2608 heap_region_iterate(&blk); |
2617 } | 2609 } |
2618 | 2610 |
2619 // Iterates an ObjectClosure over all objects within a HeapRegion. | 2611 // Iterates an ObjectClosure over all objects within a HeapRegion. |
2620 | 2612 |
4809 ParallelTaskTerminator _terminator; | 4801 ParallelTaskTerminator _terminator; |
4810 uint _n_workers; | 4802 uint _n_workers; |
4811 | 4803 |
4812 Mutex _stats_lock; | 4804 Mutex _stats_lock; |
4813 Mutex* stats_lock() { return &_stats_lock; } | 4805 Mutex* stats_lock() { return &_stats_lock; } |
4814 | |
4815 size_t getNCards() { | |
4816 return (_g1h->capacity() + G1BlockOffsetSharedArray::N_bytes - 1) | |
4817 / G1BlockOffsetSharedArray::N_bytes; | |
4818 } | |
4819 | 4806 |
4820 public: | 4807 public: |
4821 G1ParTask(G1CollectedHeap* g1h, RefToScanQueueSet *task_queues) | 4808 G1ParTask(G1CollectedHeap* g1h, RefToScanQueueSet *task_queues) |
4822 : AbstractGangTask("G1 collection"), | 4809 : AbstractGangTask("G1 collection"), |
4823 _g1h(g1h), | 4810 _g1h(g1h), |