Skip to content

Commit d70b452

Browse files
author
duke
committed
Automatic merge of jdk:master into master
2 parents f835094 + b823ad9 commit d70b452

File tree

10 files changed

+62
-63
lines changed

10 files changed

+62
-63
lines changed

src/hotspot/share/gc/z/zHeap.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -302,8 +302,8 @@ void ZHeap::process_non_strong_references() {
302302
// Process Soft/Weak/Final/PhantomReferences
303303
_reference_processor.process_references();
304304

305-
// Process concurrent weak roots
306-
_weak_roots_processor.process_concurrent_weak_roots();
305+
// Process weak roots
306+
_weak_roots_processor.process_weak_roots();
307307

308308
// Unlink stale metadata and nmethods
309309
_unload.unlink();

src/hotspot/share/gc/z/zHeapIterator.cpp

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -162,8 +162,8 @@ ZHeapIterator::ZHeapIterator(uint nworkers, bool visit_weaks) :
162162
_bitmaps_lock(),
163163
_queues(nworkers),
164164
_array_queues(nworkers),
165-
_concurrent_roots(ClassLoaderData::_claim_other),
166-
_concurrent_weak_roots(),
165+
_roots(ClassLoaderData::_claim_other),
166+
_weak_roots(),
167167
_terminator(nworkers, &_queues) {
168168

169169
// Create queues
@@ -280,15 +280,15 @@ void ZHeapIterator::push_strong_roots(const ZHeapIteratorContext& context) {
280280
ZHeapIteratorNMethodClosure nm_cl(&cl);
281281
ZHeapIteratorThreadClosure thread_cl(&cl, &nm_cl);
282282

283-
_concurrent_roots.apply(&cl,
284-
&cld_cl,
285-
&thread_cl,
286-
&nm_cl);
283+
_roots.apply(&cl,
284+
&cld_cl,
285+
&thread_cl,
286+
&nm_cl);
287287
}
288288

289289
void ZHeapIterator::push_weak_roots(const ZHeapIteratorContext& context) {
290290
ZHeapIteratorRootOopClosure<true /* Weak */> cl(context);
291-
_concurrent_weak_roots.apply(&cl);
291+
_weak_roots.apply(&cl);
292292
}
293293

294294
template <bool VisitWeaks>

src/hotspot/share/gc/z/zHeapIterator.hpp

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,15 @@ class ZHeapIterator : public ParallelObjectIterator {
4646
friend class ZHeapIteratorContext;
4747

4848
private:
49-
const bool _visit_weaks;
50-
ZStatTimerDisable _timer_disable;
51-
ZHeapIteratorBitMaps _bitmaps;
52-
ZLock _bitmaps_lock;
53-
ZHeapIteratorQueues _queues;
54-
ZHeapIteratorArrayQueues _array_queues;
55-
ZConcurrentRootsIterator _concurrent_roots;
56-
ZConcurrentWeakRootsIterator _concurrent_weak_roots;
57-
TaskTerminator _terminator;
49+
const bool _visit_weaks;
50+
ZStatTimerDisable _timer_disable;
51+
ZHeapIteratorBitMaps _bitmaps;
52+
ZLock _bitmaps_lock;
53+
ZHeapIteratorQueues _queues;
54+
ZHeapIteratorArrayQueues _array_queues;
55+
ZRootsIterator _roots;
56+
ZWeakRootsIterator _weak_roots;
57+
TaskTerminator _terminator;
5858

5959
ZHeapIteratorBitMap* object_bitmap(oop obj);
6060

src/hotspot/share/gc/z/zMark.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -644,20 +644,20 @@ class ZMarkNMethodClosure : public NMethodClosure {
644644

645645
typedef ClaimingCLDToOopClosure<ClassLoaderData::_claim_strong> ZMarkCLDClosure;
646646

647-
class ZMarkConcurrentRootsTask : public ZTask {
647+
class ZMarkRootsTask : public ZTask {
648648
private:
649649
ZMark* const _mark;
650650
SuspendibleThreadSetJoiner _sts_joiner;
651-
ZConcurrentRootsIterator _roots;
651+
ZRootsIterator _roots;
652652

653653
ZMarkOopClosure _cl;
654654
ZMarkCLDClosure _cld_cl;
655655
ZMarkThreadClosure _thread_cl;
656656
ZMarkNMethodClosure _nm_cl;
657657

658658
public:
659-
ZMarkConcurrentRootsTask(ZMark* mark) :
660-
ZTask("ZMarkConcurrentRootsTask"),
659+
ZMarkRootsTask(ZMark* mark) :
660+
ZTask("ZMarkRootsTask"),
661661
_mark(mark),
662662
_sts_joiner(),
663663
_roots(ClassLoaderData::_claim_strong),
@@ -668,7 +668,7 @@ class ZMarkConcurrentRootsTask : public ZTask {
668668
ClassLoaderDataGraph_lock->lock();
669669
}
670670

671-
~ZMarkConcurrentRootsTask() {
671+
~ZMarkRootsTask() {
672672
ClassLoaderDataGraph_lock->unlock();
673673
}
674674

@@ -710,7 +710,7 @@ class ZMarkTask : public ZTask {
710710

711711
void ZMark::mark(bool initial) {
712712
if (initial) {
713-
ZMarkConcurrentRootsTask task(this);
713+
ZMarkRootsTask task(this);
714714
_workers->run_concurrent(&task);
715715
}
716716

src/hotspot/share/gc/z/zRootsIterator.cpp

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,6 @@ void ZParallelApply<Iterator>::apply(ClosureType* cl) {
5252
}
5353
}
5454

55-
5655
ZStrongOopStorageSetIterator::ZStrongOopStorageSetIterator() :
5756
_iter() {}
5857

@@ -104,16 +103,16 @@ void ZNMethodsIterator::apply(NMethodClosure* cl) {
104103
ZNMethod::nmethods_do(cl);
105104
}
106105

107-
ZConcurrentRootsIterator::ZConcurrentRootsIterator(int cld_claim) {
106+
ZRootsIterator::ZRootsIterator(int cld_claim) {
108107
if (cld_claim != ClassLoaderData::_claim_none) {
109108
ClassLoaderDataGraph::clear_claimed_marks(cld_claim);
110109
}
111110
}
112111

113-
void ZConcurrentRootsIterator::apply(OopClosure* cl,
114-
CLDClosure* cld_cl,
115-
ThreadClosure* thread_cl,
116-
NMethodClosure* nm_cl) {
112+
void ZRootsIterator::apply(OopClosure* cl,
113+
CLDClosure* cld_cl,
114+
ThreadClosure* thread_cl,
115+
NMethodClosure* nm_cl) {
117116
_oop_storage_set.apply(cl);
118117
_class_loader_data_graph.apply(cld_cl);
119118
_java_threads.apply(thread_cl);
@@ -134,10 +133,10 @@ void ZWeakOopStorageSetIterator::report_num_dead() {
134133
_iter.report_num_dead();
135134
}
136135

137-
void ZConcurrentWeakRootsIterator::report_num_dead() {
136+
void ZWeakRootsIterator::report_num_dead() {
138137
_oop_storage_set.iter().report_num_dead();
139138
}
140139

141-
void ZConcurrentWeakRootsIterator::apply(OopClosure* cl) {
140+
void ZWeakRootsIterator::apply(OopClosure* cl) {
142141
_oop_storage_set.apply(cl);
143142
}

src/hotspot/share/gc/z/zRootsIterator.hpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -83,15 +83,15 @@ class ZNMethodsIterator {
8383
void apply(NMethodClosure* cl);
8484
};
8585

86-
class ZConcurrentRootsIterator {
86+
class ZRootsIterator {
8787
private:
8888
ZParallelApply<ZStrongOopStorageSetIterator> _oop_storage_set;
8989
ZParallelApply<ZStrongCLDsIterator> _class_loader_data_graph;
9090
ZParallelApply<ZJavaThreadsIterator> _java_threads;
9191
ZParallelApply<ZNMethodsIterator> _nmethods;
9292

9393
public:
94-
ZConcurrentRootsIterator(int cld_claim);
94+
ZRootsIterator(int cld_claim);
9595

9696
void apply(OopClosure* cl,
9797
CLDClosure* cld_cl,
@@ -111,7 +111,7 @@ class ZWeakOopStorageSetIterator {
111111
void report_num_dead();
112112
};
113113

114-
class ZConcurrentWeakRootsIterator {
114+
class ZWeakRootsIterator {
115115
private:
116116
ZParallelApply<ZWeakOopStorageSetIterator> _oop_storage_set;
117117

src/hotspot/share/gc/z/zVerify.cpp

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -251,33 +251,33 @@ class ZVerifyNMethodClosure : public NMethodClosure {
251251
}
252252
};
253253

254-
void ZVerify::roots_concurrent_strong(bool verify_fixed) {
254+
void ZVerify::roots_strong(bool verify_fixed) {
255255
ZVerifyRootClosure cl(verify_fixed);
256256
ZVerifyCLDClosure cld_cl(&cl);
257257
ZVerifyThreadClosure thread_cl(&cl);
258258
ZVerifyNMethodClosure nm_cl(&cl, verify_fixed);
259259

260-
ZConcurrentRootsIterator iter(ClassLoaderData::_claim_none);
260+
ZRootsIterator iter(ClassLoaderData::_claim_none);
261261
iter.apply(&cl,
262262
&cld_cl,
263263
&thread_cl,
264264
&nm_cl);
265265
}
266266

267-
void ZVerify::roots_concurrent_weak() {
267+
void ZVerify::roots_weak() {
268268
ZVerifyRootClosure cl(true /* verify_fixed */);
269-
ZConcurrentWeakRootsIterator iter;
269+
ZWeakRootsIterator iter;
270270
iter.apply(&cl);
271271
}
272272

273-
void ZVerify::roots(bool verify_concurrent_strong, bool verify_weaks) {
273+
void ZVerify::roots(bool verify_strong, bool verify_weaks) {
274274
assert(SafepointSynchronize::is_at_safepoint(), "Must be at a safepoint");
275275
assert(!ZResurrection::is_blocked(), "Invalid phase");
276276

277277
if (ZVerifyRoots) {
278-
roots_concurrent_strong(verify_concurrent_strong);
278+
roots_strong(verify_strong);
279279
if (verify_weaks) {
280-
roots_concurrent_weak();
280+
roots_weak();
281281
}
282282
}
283283
}
@@ -294,27 +294,27 @@ void ZVerify::objects(bool verify_weaks) {
294294
}
295295
}
296296

297-
void ZVerify::roots_and_objects(bool verify_concurrent_strong, bool verify_weaks) {
298-
roots(verify_concurrent_strong, verify_weaks);
297+
void ZVerify::roots_and_objects(bool verify_strong, bool verify_weaks) {
298+
roots(verify_strong, verify_weaks);
299299
objects(verify_weaks);
300300
}
301301

302302
void ZVerify::before_zoperation() {
303303
// Verify strong roots
304304
ZStatTimerDisable disable;
305-
roots(false /* verify_concurrent_strong */, false /* verify_weaks */);
305+
roots(false /* verify_strong */, false /* verify_weaks */);
306306
}
307307

308308
void ZVerify::after_mark() {
309309
// Verify all strong roots and strong references
310310
ZStatTimerDisable disable;
311-
roots_and_objects(true /* verify_concurrent_strong*/, false /* verify_weaks */);
311+
roots_and_objects(true /* verify_strong */, false /* verify_weaks */);
312312
}
313313

314314
void ZVerify::after_weak_processing() {
315315
// Verify all roots and all references
316316
ZStatTimerDisable disable;
317-
roots_and_objects(true /* verify_concurrent_strong*/, true /* verify_weaks */);
317+
roots_and_objects(true /* verify_strong */, true /* verify_weaks */);
318318
}
319319

320320
template <bool Map>

src/hotspot/share/gc/z/zVerify.hpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,12 +31,12 @@ class ZPageAllocator;
3131

3232
class ZVerify : public AllStatic {
3333
private:
34-
static void roots_concurrent_strong(bool verify_fixed);
35-
static void roots_concurrent_weak();
34+
static void roots_strong(bool verify_fixed);
35+
static void roots_weak();
3636

37-
static void roots(bool verify_concurrent_strong, bool verify_weaks);
37+
static void roots(bool verify_strong, bool verify_weaks);
3838
static void objects(bool verify_weaks);
39-
static void roots_and_objects(bool verify_concurrent_strong, bool verify_weaks);
39+
static void roots_and_objects(bool verify_strong, bool verify_weaks);
4040

4141
public:
4242
static void before_zoperation();

src/hotspot/share/gc/z/zWeakRootsProcessor.cpp

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -54,26 +54,26 @@ class ZPhantomCleanOopClosure : public OopClosure {
5454
ZWeakRootsProcessor::ZWeakRootsProcessor(ZWorkers* workers) :
5555
_workers(workers) {}
5656

57-
class ZProcessConcurrentWeakRootsTask : public ZTask {
57+
class ZProcessWeakRootsTask : public ZTask {
5858
private:
59-
ZConcurrentWeakRootsIterator _concurrent_weak_roots;
59+
ZWeakRootsIterator _weak_roots;
6060

6161
public:
62-
ZProcessConcurrentWeakRootsTask() :
63-
ZTask("ZProcessConccurentWeakRootsTask"),
64-
_concurrent_weak_roots() {}
62+
ZProcessWeakRootsTask() :
63+
ZTask("ZProcessWeakRootsTask"),
64+
_weak_roots() {}
6565

66-
~ZProcessConcurrentWeakRootsTask() {
67-
_concurrent_weak_roots.report_num_dead();
66+
~ZProcessWeakRootsTask() {
67+
_weak_roots.report_num_dead();
6868
}
6969

7070
virtual void work() {
7171
ZPhantomCleanOopClosure cl;
72-
_concurrent_weak_roots.apply(&cl);
72+
_weak_roots.apply(&cl);
7373
}
7474
};
7575

76-
void ZWeakRootsProcessor::process_concurrent_weak_roots() {
77-
ZProcessConcurrentWeakRootsTask task;
76+
void ZWeakRootsProcessor::process_weak_roots() {
77+
ZProcessWeakRootsTask task;
7878
_workers->run_concurrent(&task);
7979
}

src/hotspot/share/gc/z/zWeakRootsProcessor.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2017, 2019, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2017, 2020, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -33,7 +33,7 @@ class ZWeakRootsProcessor {
3333
public:
3434
ZWeakRootsProcessor(ZWorkers* workers);
3535

36-
void process_concurrent_weak_roots();
36+
void process_weak_roots();
3737
};
3838

3939
#endif // SHARE_GC_Z_ZWEAKROOTSPROCESSOR_HPP

0 commit comments

Comments
 (0)