Skip to content

Commit 5746137

Browse files
committedMay 7, 2024
8331771: ZGC: Remove OopMapCacheAlloc_lock ordering workaround
Reviewed-by: eosterlund, stefank, zgu
1 parent 02c95a6 commit 5746137

File tree

4 files changed

+0
-22
lines changed

4 files changed

+0
-22
lines changed
 

Diff for: ‎src/hotspot/share/gc/shared/collectedHeap.hpp

-1
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,6 @@ class CollectedHeap : public CHeapObj<mtGC> {
9191
friend class VMStructs;
9292
friend class JVMCIVMStructs;
9393
friend class IsSTWGCActiveMark; // Block structured external access to _is_stw_gc_active
94-
friend class DisableIsSTWGCActiveMark; // Disable current IsSTWGCActiveMark
9594
friend class MemAllocator;
9695
friend class ParallelObjectIterator;
9796

Diff for: ‎src/hotspot/share/gc/shared/isGCActiveMark.cpp

-12
Original file line numberDiff line numberDiff line change
@@ -42,15 +42,3 @@ IsSTWGCActiveMark::~IsSTWGCActiveMark() {
4242
assert(heap->is_stw_gc_active(), "Sanity");
4343
heap->_is_stw_gc_active = false;
4444
}
45-
46-
DisableIsSTWGCActiveMark::DisableIsSTWGCActiveMark() {
47-
CollectedHeap* heap = Universe::heap();
48-
assert(heap->is_stw_gc_active(), "Not reentrant");
49-
heap->_is_stw_gc_active = false;
50-
}
51-
52-
DisableIsSTWGCActiveMark::~DisableIsSTWGCActiveMark() {
53-
CollectedHeap* heap = Universe::heap();
54-
assert(!heap->is_stw_gc_active(), "Sanity");
55-
heap->_is_stw_gc_active = true;
56-
}

Diff for: ‎src/hotspot/share/gc/shared/isGCActiveMark.hpp

-6
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,4 @@ class IsSTWGCActiveMark : public StackObj {
3636
~IsSTWGCActiveMark();
3737
};
3838

39-
class DisableIsSTWGCActiveMark : public StackObj {
40-
public:
41-
DisableIsSTWGCActiveMark();
42-
~DisableIsSTWGCActiveMark();
43-
};
44-
4539
#endif // SHARE_GC_SHARED_ISGCACTIVEMARK_HPP

Diff for: ‎src/hotspot/share/gc/z/zVerify.cpp

-3
Original file line numberDiff line numberDiff line change
@@ -483,9 +483,6 @@ void ZVerify::after_mark() {
483483
roots_strong(true /* verify_after_old_mark */);
484484
}
485485
if (ZVerifyObjects) {
486-
// Workaround OopMapCacheAlloc_lock reordering with the StackWatermark_lock
487-
DisableIsSTWGCActiveMark mark;
488-
489486
objects(false /* verify_weaks */);
490487
guarantee(zverify_broken_object == zaddress::null, "Verification failed");
491488
}

0 commit comments

Comments
 (0)