--- a/src/hotspot/share/runtime/mutexLocker.cpp Tue Jul 16 08:56:08 2019 +0200
+++ b/src/hotspot/share/runtime/mutexLocker.cpp Fri Sep 27 07:56:02 2019 -0400
@@ -191,148 +191,148 @@
#endif
#define def(var, type, pri, vm_block, safepoint_check_allowed ) { \
- var = new type(Mutex::pri, #var, vm_block, safepoint_check_allowed); \
+ var = new type(Mutex::pri, #var, vm_block, Mutex::safepoint_check_allowed); \
assert(_num_mutex < MAX_NUM_MUTEX, "increase MAX_NUM_MUTEX"); \
_mutex_array[_num_mutex++] = var; \
}
// Using Padded subclasses to prevent false sharing of these global monitors and mutexes.
void mutex_init() {
- def(tty_lock , PaddedMutex , tty, true, Monitor::_safepoint_check_never); // allow to lock in VM
+ def(tty_lock , PaddedMutex , tty, true, _safepoint_check_never); // allow to lock in VM
- def(CGC_lock , PaddedMonitor, special, true, Monitor::_safepoint_check_never); // coordinate between fore- and background GC
- def(STS_lock , PaddedMonitor, leaf, true, Monitor::_safepoint_check_never);
+ def(CGC_lock , PaddedMonitor, special, true, _safepoint_check_never); // coordinate between fore- and background GC
+ def(STS_lock , PaddedMonitor, leaf, true, _safepoint_check_never);
- def(FullGCCount_lock , PaddedMonitor, leaf, true, Monitor::_safepoint_check_never); // in support of ExplicitGCInvokesConcurrent
+ def(FullGCCount_lock , PaddedMonitor, leaf, true, _safepoint_check_never); // in support of ExplicitGCInvokesConcurrent
if (UseG1GC) {
- def(DirtyCardQ_CBL_mon , PaddedMonitor, access, true, Monitor::_safepoint_check_never);
- def(Shared_DirtyCardQ_lock , PaddedMutex , access + 1, true, Monitor::_safepoint_check_never);
+ def(DirtyCardQ_CBL_mon , PaddedMonitor, access, true, _safepoint_check_never);
+ def(Shared_DirtyCardQ_lock , PaddedMutex , access + 1, true, _safepoint_check_never);
- def(FreeList_lock , PaddedMutex , leaf , true, Monitor::_safepoint_check_never);
- def(OldSets_lock , PaddedMutex , leaf , true, Monitor::_safepoint_check_never);
- def(RootRegionScan_lock , PaddedMonitor, leaf , true, Monitor::_safepoint_check_never);
+ def(FreeList_lock , PaddedMutex , leaf , true, _safepoint_check_never);
+ def(OldSets_lock , PaddedMutex , leaf , true, _safepoint_check_never);
+ def(RootRegionScan_lock , PaddedMonitor, leaf , true, _safepoint_check_never);
- def(StringDedupQueue_lock , PaddedMonitor, leaf, true, Monitor::_safepoint_check_never);
- def(StringDedupTable_lock , PaddedMutex , leaf, true, Monitor::_safepoint_check_never);
+ def(StringDedupQueue_lock , PaddedMonitor, leaf, true, _safepoint_check_never);
+ def(StringDedupTable_lock , PaddedMutex , leaf, true, _safepoint_check_never);
- def(MarkStackFreeList_lock , PaddedMutex , leaf , true, Monitor::_safepoint_check_never);
- def(MarkStackChunkList_lock , PaddedMutex , leaf , true, Monitor::_safepoint_check_never);
+ def(MarkStackFreeList_lock , PaddedMutex , leaf , true, _safepoint_check_never);
+ def(MarkStackChunkList_lock , PaddedMutex , leaf , true, _safepoint_check_never);
- def(MonitoringSupport_lock , PaddedMutex , native , true, Monitor::_safepoint_check_never); // used for serviceability monitoring support
+ def(MonitoringSupport_lock , PaddedMutex , native , true, _safepoint_check_never); // used for serviceability monitoring support
}
if (UseShenandoahGC) {
- def(StringDedupQueue_lock , PaddedMonitor, leaf, true, Monitor::_safepoint_check_never);
- def(StringDedupTable_lock , PaddedMutex , leaf, true, Monitor::_safepoint_check_never);
+ def(StringDedupQueue_lock , PaddedMonitor, leaf, true, _safepoint_check_never);
+ def(StringDedupTable_lock , PaddedMutex , leaf, true, _safepoint_check_never);
}
- def(ParGCRareEvent_lock , PaddedMutex , leaf , true, Monitor::_safepoint_check_always);
- def(CGCPhaseManager_lock , PaddedMonitor, leaf, false, Monitor::_safepoint_check_always);
- def(CodeCache_lock , PaddedMonitor, special, true, Monitor::_safepoint_check_never);
- def(RawMonitor_lock , PaddedMutex , special, true, Monitor::_safepoint_check_never);
- def(OopMapCacheAlloc_lock , PaddedMutex , leaf, true, Monitor::_safepoint_check_always); // used for oop_map_cache allocation.
+ def(ParGCRareEvent_lock , PaddedMutex , leaf , true, _safepoint_check_always);
+ def(CGCPhaseManager_lock , PaddedMonitor, leaf, false, _safepoint_check_always);
+ def(CodeCache_lock , PaddedMonitor, special, true, _safepoint_check_never);
+ def(RawMonitor_lock , PaddedMutex , special, true, _safepoint_check_never);
+ def(OopMapCacheAlloc_lock , PaddedMutex , leaf, true, _safepoint_check_always); // used for oop_map_cache allocation.
- def(MetaspaceExpand_lock , PaddedMutex , leaf-1, true, Monitor::_safepoint_check_never);
- def(ClassLoaderDataGraph_lock , PaddedMutex , nonleaf, false, Monitor::_safepoint_check_always);
+ def(MetaspaceExpand_lock , PaddedMutex , leaf-1, true, _safepoint_check_never);
+ def(ClassLoaderDataGraph_lock , PaddedMutex , nonleaf, false, _safepoint_check_always);
- def(Patching_lock , PaddedMutex , special, true, Monitor::_safepoint_check_never); // used for safepointing and code patching.
- def(CompiledMethod_lock , PaddedMutex , special-1, true, Monitor::_safepoint_check_never);
- def(Service_lock , PaddedMonitor, special, true, Monitor::_safepoint_check_never); // used for service thread operations
- def(JmethodIdCreation_lock , PaddedMutex , leaf, true, Monitor::_safepoint_check_always); // used for creating jmethodIDs.
+ def(Patching_lock , PaddedMutex , special, true, _safepoint_check_never); // used for safepointing and code patching.
+ def(CompiledMethod_lock , PaddedMutex , special-1, true, _safepoint_check_never);
+ def(Service_lock , PaddedMonitor, special, true, _safepoint_check_never); // used for service thread operations
+ def(JmethodIdCreation_lock , PaddedMutex , leaf, true, _safepoint_check_always); // used for creating jmethodIDs.
- def(SystemDictionary_lock , PaddedMonitor, leaf, true, Monitor::_safepoint_check_always);
- def(ProtectionDomainSet_lock , PaddedMutex , leaf-1, true, Monitor::_safepoint_check_never);
- def(SharedDictionary_lock , PaddedMutex , leaf, true, Monitor::_safepoint_check_always);
- def(Module_lock , PaddedMutex , leaf+2, false, Monitor::_safepoint_check_always);
- def(InlineCacheBuffer_lock , PaddedMutex , leaf, true, Monitor::_safepoint_check_never);
- def(VMStatistic_lock , PaddedMutex , leaf, false, Monitor::_safepoint_check_always);
- def(ExpandHeap_lock , PaddedMutex , leaf, true, Monitor::_safepoint_check_always); // Used during compilation by VM thread
- def(JNIHandleBlockFreeList_lock , PaddedMutex , leaf-1, true, Monitor::_safepoint_check_never); // handles are used by VM thread
- def(SignatureHandlerLibrary_lock , PaddedMutex , leaf, false, Monitor::_safepoint_check_always);
- def(SymbolArena_lock , PaddedMutex , leaf+2, true, Monitor::_safepoint_check_never);
- def(ProfilePrint_lock , PaddedMutex , leaf, false, Monitor::_safepoint_check_always); // serial profile printing
- def(ExceptionCache_lock , PaddedMutex , leaf, false, Monitor::_safepoint_check_always); // serial profile printing
- def(Debug1_lock , PaddedMutex , leaf, true, Monitor::_safepoint_check_never);
+ def(SystemDictionary_lock , PaddedMonitor, leaf, true, _safepoint_check_always);
+ def(ProtectionDomainSet_lock , PaddedMutex , leaf-1, true, _safepoint_check_never);
+ def(SharedDictionary_lock , PaddedMutex , leaf, true, _safepoint_check_always);
+ def(Module_lock , PaddedMutex , leaf+2, false, _safepoint_check_always);
+ def(InlineCacheBuffer_lock , PaddedMutex , leaf, true, _safepoint_check_never);
+ def(VMStatistic_lock , PaddedMutex , leaf, false, _safepoint_check_always);
+ def(ExpandHeap_lock , PaddedMutex , leaf, true, _safepoint_check_always); // Used during compilation by VM thread
+ def(JNIHandleBlockFreeList_lock , PaddedMutex , leaf-1, true, _safepoint_check_never); // handles are used by VM thread
+ def(SignatureHandlerLibrary_lock , PaddedMutex , leaf, false, _safepoint_check_always);
+ def(SymbolArena_lock , PaddedMutex , leaf+2, true, _safepoint_check_never);
+ def(ProfilePrint_lock , PaddedMutex , leaf, false, _safepoint_check_always); // serial profile printing
+ def(ExceptionCache_lock , PaddedMutex , leaf, false, _safepoint_check_always); // serial profile printing
+ def(Debug1_lock , PaddedMutex , leaf, true, _safepoint_check_never);
#ifndef PRODUCT
- def(FullGCALot_lock , PaddedMutex , leaf, false, Monitor::_safepoint_check_always); // a lock to make FullGCALot MT safe
+ def(FullGCALot_lock , PaddedMutex , leaf, false, _safepoint_check_always); // a lock to make FullGCALot MT safe
#endif
- def(BeforeExit_lock , PaddedMonitor, leaf, true, Monitor::_safepoint_check_always);
- def(PerfDataMemAlloc_lock , PaddedMutex , leaf, true, Monitor::_safepoint_check_always); // used for allocating PerfData memory for performance data
- def(PerfDataManager_lock , PaddedMutex , leaf, true, Monitor::_safepoint_check_always); // used for synchronized access to PerfDataManager resources
+ def(BeforeExit_lock , PaddedMonitor, leaf, true, _safepoint_check_always);
+ def(PerfDataMemAlloc_lock , PaddedMutex , leaf, true, _safepoint_check_always); // used for allocating PerfData memory for performance data
+ def(PerfDataManager_lock , PaddedMutex , leaf, true, _safepoint_check_always); // used for synchronized access to PerfDataManager resources
// CMS_modUnionTable_lock leaf
// CMS_bitMap_lock leaf 1
// CMS_freeList_lock leaf 2
- def(Threads_lock , PaddedMonitor, barrier, true, Monitor::_safepoint_check_always); // Used for safepoint protocol.
- def(NonJavaThreadsList_lock , PaddedMutex, leaf, true, Monitor::_safepoint_check_never);
- def(NonJavaThreadsListSync_lock , PaddedMutex, leaf, true, Monitor::_safepoint_check_never);
+ def(Threads_lock , PaddedMonitor, barrier, true, _safepoint_check_always); // Used for safepoint protocol.
+ def(NonJavaThreadsList_lock , PaddedMutex, leaf, true, _safepoint_check_never);
+ def(NonJavaThreadsListSync_lock , PaddedMutex, leaf, true, _safepoint_check_never);
- def(VMOperationQueue_lock , PaddedMonitor, nonleaf, true, Monitor::_safepoint_check_never); // VM_thread allowed to block on these
- def(VMOperationRequest_lock , PaddedMonitor, nonleaf, true, Monitor::_safepoint_check_always);
- def(RetData_lock , PaddedMutex , nonleaf, false, Monitor::_safepoint_check_always);
- def(Terminator_lock , PaddedMonitor, nonleaf, true, Monitor::_safepoint_check_always);
- def(InitCompleted_lock , PaddedMonitor, leaf, true, Monitor::_safepoint_check_never);
- def(VtableStubs_lock , PaddedMutex , nonleaf, true, Monitor::_safepoint_check_never);
- def(Notify_lock , PaddedMonitor, nonleaf, true, Monitor::_safepoint_check_always);
- def(JNICritical_lock , PaddedMonitor, nonleaf, true, Monitor::_safepoint_check_always); // used for JNI critical regions
- def(AdapterHandlerLibrary_lock , PaddedMutex , nonleaf, true, Monitor::_safepoint_check_always);
+ def(VMOperationQueue_lock , PaddedMonitor, nonleaf, true, _safepoint_check_never); // VM_thread allowed to block on these
+ def(VMOperationRequest_lock , PaddedMonitor, nonleaf, true, _safepoint_check_always);
+ def(RetData_lock , PaddedMutex , nonleaf, false, _safepoint_check_always);
+ def(Terminator_lock , PaddedMonitor, nonleaf, true, _safepoint_check_always);
+ def(InitCompleted_lock , PaddedMonitor, leaf, true, _safepoint_check_never);
+ def(VtableStubs_lock , PaddedMutex , nonleaf, true, _safepoint_check_never);
+ def(Notify_lock , PaddedMonitor, nonleaf, true, _safepoint_check_always);
+ def(JNICritical_lock , PaddedMonitor, nonleaf, true, _safepoint_check_always); // used for JNI critical regions
+ def(AdapterHandlerLibrary_lock , PaddedMutex , nonleaf, true, _safepoint_check_always);
- def(Heap_lock , PaddedMonitor, nonleaf+1, false, Monitor::_safepoint_check_sometimes); // Doesn't safepoint check during termination.
- def(JfieldIdCreation_lock , PaddedMutex , nonleaf+1, true, Monitor::_safepoint_check_always); // jfieldID, Used in VM_Operation
+ def(Heap_lock , PaddedMonitor, nonleaf+1, false, _safepoint_check_sometimes); // Doesn't safepoint check during termination.
+ def(JfieldIdCreation_lock , PaddedMutex , nonleaf+1, true, _safepoint_check_always); // jfieldID, Used in VM_Operation
- def(CompiledIC_lock , PaddedMutex , nonleaf+2, false, Monitor::_safepoint_check_never); // locks VtableStubs_lock, InlineCacheBuffer_lock
- def(CompileTaskAlloc_lock , PaddedMutex , nonleaf+2, true, Monitor::_safepoint_check_always);
- def(CompileStatistics_lock , PaddedMutex , nonleaf+2, false, Monitor::_safepoint_check_always);
- def(DirectivesStack_lock , PaddedMutex , special, true, Monitor::_safepoint_check_never);
- def(MultiArray_lock , PaddedMutex , nonleaf+2, false, Monitor::_safepoint_check_always);
+ def(CompiledIC_lock , PaddedMutex , nonleaf+2, false, _safepoint_check_never); // locks VtableStubs_lock, InlineCacheBuffer_lock
+ def(CompileTaskAlloc_lock , PaddedMutex , nonleaf+2, true, _safepoint_check_always);
+ def(CompileStatistics_lock , PaddedMutex , nonleaf+2, false, _safepoint_check_always);
+ def(DirectivesStack_lock , PaddedMutex , special, true, _safepoint_check_never);
+ def(MultiArray_lock , PaddedMutex , nonleaf+2, false, _safepoint_check_always);
- def(JvmtiThreadState_lock , PaddedMutex , nonleaf+2, false, Monitor::_safepoint_check_always); // Used by JvmtiThreadState/JvmtiEventController
- def(Management_lock , PaddedMutex , nonleaf+2, false, Monitor::_safepoint_check_always); // used for JVM management
+ def(JvmtiThreadState_lock , PaddedMutex , nonleaf+2, false, _safepoint_check_always); // Used by JvmtiThreadState/JvmtiEventController
+ def(Management_lock , PaddedMutex , nonleaf+2, false, _safepoint_check_always); // used for JVM management
- def(Compile_lock , PaddedMutex , nonleaf+3, true, Monitor::_safepoint_check_always);
- def(MethodData_lock , PaddedMutex , nonleaf+3, false, Monitor::_safepoint_check_always);
- def(TouchedMethodLog_lock , PaddedMutex , nonleaf+3, false, Monitor::_safepoint_check_always);
+ def(Compile_lock , PaddedMutex , nonleaf+3, true, _safepoint_check_always);
+ def(MethodData_lock , PaddedMutex , nonleaf+3, false, _safepoint_check_always);
+ def(TouchedMethodLog_lock , PaddedMutex , nonleaf+3, false, _safepoint_check_always);
- def(MethodCompileQueue_lock , PaddedMonitor, nonleaf+4, false, Monitor::_safepoint_check_always);
- def(Debug2_lock , PaddedMutex , nonleaf+4, true, Monitor::_safepoint_check_never);
- def(Debug3_lock , PaddedMutex , nonleaf+4, true, Monitor::_safepoint_check_never);
- def(CompileThread_lock , PaddedMonitor, nonleaf+5, false, Monitor::_safepoint_check_always);
- def(PeriodicTask_lock , PaddedMonitor, nonleaf+5, true, Monitor::_safepoint_check_always);
- def(RedefineClasses_lock , PaddedMonitor, nonleaf+5, true, Monitor::_safepoint_check_always);
+ def(MethodCompileQueue_lock , PaddedMonitor, nonleaf+4, false, _safepoint_check_always);
+ def(Debug2_lock , PaddedMutex , nonleaf+4, true, _safepoint_check_never);
+ def(Debug3_lock , PaddedMutex , nonleaf+4, true, _safepoint_check_never);
+ def(CompileThread_lock , PaddedMonitor, nonleaf+5, false, _safepoint_check_always);
+ def(PeriodicTask_lock , PaddedMonitor, nonleaf+5, true, _safepoint_check_always);
+ def(RedefineClasses_lock , PaddedMonitor, nonleaf+5, true, _safepoint_check_always);
if (WhiteBoxAPI) {
- def(Compilation_lock , PaddedMonitor, leaf, false, Monitor::_safepoint_check_never);
+ def(Compilation_lock , PaddedMonitor, leaf, false, _safepoint_check_never);
}
#if INCLUDE_JFR
- def(JfrMsg_lock , PaddedMonitor, leaf, true, Monitor::_safepoint_check_always);
- def(JfrBuffer_lock , PaddedMutex , leaf, true, Monitor::_safepoint_check_never);
- def(JfrStream_lock , PaddedMutex , leaf+1, true, Monitor::_safepoint_check_never); // ensure to rank lower than 'safepoint'
- def(JfrStacktrace_lock , PaddedMutex , special, true, Monitor::_safepoint_check_never);
- def(JfrThreadSampler_lock , PaddedMonitor, leaf, true, Monitor::_safepoint_check_never);
+ def(JfrMsg_lock , PaddedMonitor, leaf, true, _safepoint_check_always);
+ def(JfrBuffer_lock , PaddedMutex , leaf, true, _safepoint_check_never);
+ def(JfrStream_lock , PaddedMutex , leaf+1, true, _safepoint_check_never); // ensure to rank lower than 'safepoint'
+ def(JfrStacktrace_lock , PaddedMutex , special, true, _safepoint_check_never);
+ def(JfrThreadSampler_lock , PaddedMonitor, leaf, true, _safepoint_check_never);
#endif
#ifndef SUPPORTS_NATIVE_CX8
- def(UnsafeJlong_lock , PaddedMutex , special, false, Monitor::_safepoint_check_never);
+ def(UnsafeJlong_lock , PaddedMutex , special, false, _safepoint_check_never);
#endif
- def(CodeHeapStateAnalytics_lock , PaddedMutex , leaf, true, Monitor::_safepoint_check_never);
- def(NMethodSweeperStats_lock , PaddedMutex , special, true, Monitor::_safepoint_check_never);
- def(ThreadsSMRDelete_lock , PaddedMonitor, special, true, Monitor::_safepoint_check_never);
- def(ThreadIdTableCreate_lock , PaddedMutex , leaf, false, Monitor::_safepoint_check_always);
- def(SharedDecoder_lock , PaddedMutex , native, false, Monitor::_safepoint_check_never);
- def(DCmdFactory_lock , PaddedMutex , leaf, true, Monitor::_safepoint_check_never);
+ def(CodeHeapStateAnalytics_lock , PaddedMutex , leaf, true, _safepoint_check_never);
+ def(NMethodSweeperStats_lock , PaddedMutex , special, true, _safepoint_check_never);
+ def(ThreadsSMRDelete_lock , PaddedMonitor, special, true, _safepoint_check_never);
+ def(ThreadIdTableCreate_lock , PaddedMutex , leaf, false, _safepoint_check_always);
+ def(SharedDecoder_lock , PaddedMutex , native, false, _safepoint_check_never);
+ def(DCmdFactory_lock , PaddedMutex , leaf, true, _safepoint_check_never);
#if INCLUDE_NMT
- def(NMTQuery_lock , PaddedMutex , max_nonleaf, false, Monitor::_safepoint_check_always);
+ def(NMTQuery_lock , PaddedMutex , max_nonleaf, false, _safepoint_check_always);
#endif
#if INCLUDE_CDS
#if INCLUDE_JVMTI
- def(CDSClassFileStream_lock , PaddedMutex , max_nonleaf, false, Monitor::_safepoint_check_always);
+ def(CDSClassFileStream_lock , PaddedMutex , max_nonleaf, false, _safepoint_check_always);
#endif
#if INCLUDE_JVMCI
- def(JVMCI_lock , PaddedMonitor, nonleaf+2, true, Monitor::_safepoint_check_always);
+ def(JVMCI_lock , PaddedMonitor, nonleaf+2, true, _safepoint_check_always);
#endif
- def(DumpTimeTable_lock , PaddedMutex , leaf, true, Monitor::_safepoint_check_never);
+ def(DumpTimeTable_lock , PaddedMutex , leaf, true, _safepoint_check_never);
#endif // INCLUDE_CDS
}