mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 15:24:43 +02:00
8254671: ZGC: Remove unused roots iterator types
Reviewed-by: stefank
This commit is contained in:
parent
9c9349098a
commit
6fe209b564
2 changed files with 0 additions and 52 deletions
|
@ -29,7 +29,6 @@
|
|||
#include "gc/shared/barrierSet.hpp"
|
||||
#include "gc/shared/barrierSetNMethod.hpp"
|
||||
#include "gc/shared/oopStorageSet.hpp"
|
||||
#include "gc/shared/oopStorageParState.inline.hpp"
|
||||
#include "gc/shared/oopStorageSetParState.inline.hpp"
|
||||
#include "gc/shared/suspendibleThreadSet.hpp"
|
||||
#include "gc/z/zBarrierSetNMethod.hpp"
|
||||
|
@ -62,18 +61,6 @@ static const ZStatSubPhase ZSubPhaseConcurrentRootsCodeCache("Concurrent Roots C
|
|||
static const ZStatSubPhase ZSubPhasePauseWeakRootsJVMTIWeakExport("Pause Weak Roots JVMTIWeakExport");
|
||||
static const ZStatSubPhase ZSubPhaseConcurrentWeakRootsOopStorageSet("Concurrent Weak Roots OopStorageSet");
|
||||
|
||||
template <typename T, void (T::*F)(ZRootsIteratorClosure*)>
|
||||
ZSerialOopsDo<T, F>::ZSerialOopsDo(T* iter) :
|
||||
_iter(iter),
|
||||
_claimed(false) {}
|
||||
|
||||
template <typename T, void (T::*F)(ZRootsIteratorClosure*)>
|
||||
void ZSerialOopsDo<T, F>::oops_do(ZRootsIteratorClosure* cl) {
|
||||
if (!_claimed && Atomic::cmpxchg(&_claimed, false, true) == false) {
|
||||
(_iter->*F)(cl);
|
||||
}
|
||||
}
|
||||
|
||||
template <typename T, void (T::*F)(ZRootsIteratorClosure*)>
|
||||
ZParallelOopsDo<T, F>::ZParallelOopsDo(T* iter) :
|
||||
_iter(iter),
|
||||
|
@ -101,21 +88,6 @@ void ZSerialWeakOopsDo<T, F>::weak_oops_do(BoolObjectClosure* is_alive, ZRootsIt
|
|||
}
|
||||
}
|
||||
|
||||
template <typename T, void (T::*F)(BoolObjectClosure*, ZRootsIteratorClosure*)>
|
||||
ZParallelWeakOopsDo<T, F>::ZParallelWeakOopsDo(T* iter) :
|
||||
_iter(iter),
|
||||
_completed(false) {}
|
||||
|
||||
template <typename T, void (T::*F)(BoolObjectClosure*, ZRootsIteratorClosure*)>
|
||||
void ZParallelWeakOopsDo<T, F>::weak_oops_do(BoolObjectClosure* is_alive, ZRootsIteratorClosure* cl) {
|
||||
if (!_completed) {
|
||||
(_iter->*F)(is_alive, cl);
|
||||
if (!_completed) {
|
||||
_completed = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ZJavaThreadsIterator::ZJavaThreadsIterator() :
|
||||
_threads(),
|
||||
_claimed(0) {}
|
||||
|
|
|
@ -24,7 +24,6 @@
|
|||
#ifndef SHARE_GC_Z_ZROOTSITERATOR_HPP
|
||||
#define SHARE_GC_Z_ZROOTSITERATOR_HPP
|
||||
|
||||
#include "gc/shared/oopStorageParState.hpp"
|
||||
#include "gc/shared/oopStorageSetParState.hpp"
|
||||
#include "gc/shared/suspendibleThreadSet.hpp"
|
||||
#include "memory/allocation.hpp"
|
||||
|
@ -35,21 +34,9 @@
|
|||
|
||||
class ZRootsIteratorClosure;
|
||||
|
||||
typedef OopStorage::ParState<true /* concurrent */, false /* is_const */> ZOopStorageIterator;
|
||||
typedef OopStorageSetStrongParState<true /* concurrent */, false /* is_const */> ZOopStorageSetStrongIterator;
|
||||
typedef OopStorageSetWeakParState<true /* concurrent */, false /* is_const */> ZOopStorageSetWeakIterator;
|
||||
|
||||
template <typename T, void (T::*F)(ZRootsIteratorClosure*)>
|
||||
class ZSerialOopsDo {
|
||||
private:
|
||||
T* const _iter;
|
||||
volatile bool _claimed;
|
||||
|
||||
public:
|
||||
ZSerialOopsDo(T* iter);
|
||||
void oops_do(ZRootsIteratorClosure* cl);
|
||||
};
|
||||
|
||||
template <typename T, void (T::*F)(ZRootsIteratorClosure*)>
|
||||
class ZParallelOopsDo {
|
||||
private:
|
||||
|
@ -72,17 +59,6 @@ public:
|
|||
void weak_oops_do(BoolObjectClosure* is_alive, ZRootsIteratorClosure* cl);
|
||||
};
|
||||
|
||||
template <typename T, void (T::*F)(BoolObjectClosure*, ZRootsIteratorClosure*)>
|
||||
class ZParallelWeakOopsDo {
|
||||
private:
|
||||
T* const _iter;
|
||||
volatile bool _completed;
|
||||
|
||||
public:
|
||||
ZParallelWeakOopsDo(T* iter);
|
||||
void weak_oops_do(BoolObjectClosure* is_alive, ZRootsIteratorClosure* cl);
|
||||
};
|
||||
|
||||
class ZRootsIteratorClosure : public OopClosure {
|
||||
public:
|
||||
virtual void do_thread(Thread* thread) {}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue