Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

8274004: Change 'nonleaf' rank name #5845

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions src/hotspot/os/aix/osThread_aix.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,7 @@ void OSThread::pd_initialize() {

sigemptyset(&_caller_sigmask);

_startThread_lock = new Monitor(Mutex::event, "startThread_lock",
Monitor::_safepoint_check_never);
_startThread_lock = new Monitor(Mutex::event, "startThread_lock");
assert(_startThread_lock != NULL, "check");
}

Expand Down
3 changes: 1 addition & 2 deletions src/hotspot/os/bsd/osThread_bsd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,7 @@ void OSThread::pd_initialize() {

sigemptyset(&_caller_sigmask);

_startThread_lock = new Monitor(Mutex::event, "startThread_lock",
Monitor::_safepoint_check_never);
_startThread_lock = new Monitor(Mutex::event, "startThread_lock");
assert(_startThread_lock !=NULL, "check");
}

Expand Down
3 changes: 1 addition & 2 deletions src/hotspot/os/linux/osThread_linux.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,7 @@ void OSThread::pd_initialize() {

sigemptyset(&_caller_sigmask);

_startThread_lock = new Monitor(Mutex::event, "startThread_lock",
Monitor::_safepoint_check_never);
_startThread_lock = new Monitor(Mutex::event, "startThread_lock");
assert(_startThread_lock !=NULL, "check");
}

Expand Down
3 changes: 1 addition & 2 deletions src/hotspot/share/classfile/classLoaderData.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,7 @@ void ClassLoaderData::initialize_name(Handle class_loader) {

ClassLoaderData::ClassLoaderData(Handle h_class_loader, bool has_class_mirror_holder) :
_metaspace(NULL),
_metaspace_lock(new Mutex(Mutex::nosafepoint-2, "MetaspaceAllocation_lock",
Mutex::_safepoint_check_never)),
_metaspace_lock(new Mutex(Mutex::nosafepoint-2, "MetaspaceAllocation_lock")),
_unloading(false), _has_class_mirror_holder(has_class_mirror_holder),
_modified_oops(true),
// A non-strong hidden class loader data doesn't have anything to keep
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/compiler/compileTask.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ class CompileTask : public CHeapObj<mtCompiler> {

public:
CompileTask() : _failure_reason(NULL), _failure_reason_on_C_heap(false) {
_lock = new Monitor(Mutex::nonleaf, "CompileTask_lock", Mutex::_safepoint_check_always);
_lock = new Monitor(Mutex::safepoint, "CompileTask_lock");
}

void initialize(int compile_id, const methodHandle& method, int osr_bci, int comp_level,
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/gc/g1/g1RegionToSpaceMapper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ class G1RegionsSmallerThanCommitSizeMapper : public G1RegionToSpaceMapper {
MEMFLAGS type) :
G1RegionToSpaceMapper(rs, actual_size, page_size, alloc_granularity, commit_factor, type),
_regions_per_page((page_size * commit_factor) / alloc_granularity),
_lock(Mutex::service-3, "G1Mapper_lock", Mutex::_safepoint_check_never) {
_lock(Mutex::service-3, "G1Mapper_lock") {

guarantee((page_size * commit_factor) >= alloc_granularity, "allocation granularity smaller than commit granularity");
}
Expand Down
4 changes: 1 addition & 3 deletions src/hotspot/share/gc/g1/g1ServiceThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,7 @@ void G1SentinelTask::execute() {

G1ServiceThread::G1ServiceThread() :
ConcurrentGCThread(),
_monitor(Mutex::nosafepoint,
"G1ServiceThread_lock",
Monitor::_safepoint_check_never),
_monitor(Mutex::nosafepoint, "G1ServiceThread_lock"),
_task_queue() {
set_name("G1 Service");
create_and_start();
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/gc/g1/heapRegion.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ HeapRegion::HeapRegion(uint hrm_index,
_top(NULL),
_compaction_top(NULL),
_bot_part(bot, this),
_par_alloc_lock(Mutex::service-2, "HeapRegionParAlloc_lock", Mutex::_safepoint_check_never),
_par_alloc_lock(Mutex::service-2, "HeapRegionParAlloc_lock"),
_pre_dummy_top(NULL),
_rem_set(NULL),
_hrm_index(hrm_index),
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/gc/g1/heapRegionRemSet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ const char* HeapRegionRemSet::_short_state_strings[] = {"UNTRA", "UPDAT", "CMPL

HeapRegionRemSet::HeapRegionRemSet(HeapRegion* hr,
G1CardSetConfiguration* config) :
_m(Mutex::service - 1, FormatBuffer<128>("HeapRegionRemSet#%u_lock", hr->hrm_index()), Monitor::_safepoint_check_never),
_m(Mutex::service - 1, FormatBuffer<128>("HeapRegionRemSet#%u_lock", hr->hrm_index())),
_code_roots(),
_card_set_mm(config, G1CardSetFreePool::free_list_pool()),
_card_set(config, &_card_set_mm),
Expand Down
3 changes: 1 addition & 2 deletions src/hotspot/share/gc/parallel/psCompactionManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,7 @@ void ParCompactionManager::initialize(ParMarkBitMap* mbm) {

_shadow_region_array = new (ResourceObj::C_HEAP, mtGC) GrowableArray<size_t >(10, mtGC);

_shadow_region_monitor = new Monitor(Mutex::nosafepoint, "CompactionManager_lock",
Monitor::_safepoint_check_never);
_shadow_region_monitor = new Monitor(Mutex::nosafepoint, "CompactionManager_lock");
}

void ParCompactionManager::reset_all_bitmap_query_caches() {
Expand Down
3 changes: 1 addition & 2 deletions src/hotspot/share/gc/shared/gcLogPrecious.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,7 @@ void GCLogPrecious::initialize() {
_lines = new (ResourceObj::C_HEAP, mtGC) stringStream();
_temp = new (ResourceObj::C_HEAP, mtGC) stringStream();
_lock = new Mutex(Mutex::event, /* The lowest lock rank I could find */
"GCLogPrecious Lock",
Mutex::_safepoint_check_never);
"GCLogPrecious Lock");
}

void GCLogPrecious::vwrite_inner(LogTargetHandle log, const char* format, va_list args) {
Expand Down
8 changes: 2 additions & 6 deletions src/hotspot/share/gc/shared/oopStorage.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -811,10 +811,10 @@ const size_t initial_active_array_size = 8;

static Mutex* make_oopstorage_mutex(const char* storage_name,
const char* kind,
int rank) {
Mutex::Rank rank) {
char name[256];
os::snprintf(name, sizeof(name), "%s %s lock", storage_name, kind);
return new PaddedMutex(rank, name, Mutex::_safepoint_check_never);
return new PaddedMutex(rank, name);
}

void* OopStorage::operator new(size_t size, MEMFLAGS memflags) {
Expand Down Expand Up @@ -844,10 +844,6 @@ OopStorage::OopStorage(const char* name, MEMFLAGS memflags) :
"%s: active_mutex must have lower rank than allocation_mutex", _name);
assert(Service_lock->rank() < _active_mutex->rank(),
"%s: active_mutex must have higher rank than Service_lock", _name);
assert(_active_mutex->_safepoint_check_required == Mutex::_safepoint_check_never,
"%s: active mutex requires never safepoint check", _name);
assert(_allocation_mutex->_safepoint_check_required == Mutex::_safepoint_check_never,
"%s: allocation mutex requires never safepoint check", _name);
}

void OopStorage::delete_empty_block(const Block& block) {
Expand Down
3 changes: 1 addition & 2 deletions src/hotspot/share/gc/shared/space.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -773,8 +773,7 @@ void OffsetTableContigSpace::alloc_block(HeapWord* start, HeapWord* end) {
OffsetTableContigSpace::OffsetTableContigSpace(BlockOffsetSharedArray* sharedOffsetArray,
MemRegion mr) :
_offsets(sharedOffsetArray, mr),
_par_alloc_lock(Mutex::nonleaf, "OffsetTableContigSpaceParAlloc_lock",
Mutex::_safepoint_check_always, true)
_par_alloc_lock(Mutex::safepoint, "OffsetTableContigSpaceParAlloc_lock", true)
{
_offsets.set_contig_space(this);
initialize(mr, SpaceDecorator::Clear, SpaceDecorator::Mangle);
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/gc/shared/taskTerminator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ TaskTerminator::TaskTerminator(uint n_threads, TaskQueueSetSuper* queue_set) :
_n_threads(n_threads),
_queue_set(queue_set),
_offered_termination(0),
_blocker(Mutex::nosafepoint, "TaskTerminator_lock", Monitor::_safepoint_check_never),
_blocker(Mutex::nosafepoint, "TaskTerminator_lock"),
_spin_master(NULL) { }

TaskTerminator::~TaskTerminator() {
Expand Down
3 changes: 1 addition & 2 deletions src/hotspot/share/gc/shared/workgroup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -245,8 +245,7 @@ void GangWorker::loop() {
// *** WorkGangBarrierSync

WorkGangBarrierSync::WorkGangBarrierSync()
: _monitor(Mutex::nosafepoint, "WorkGangBarrierSync_lock",
Monitor::_safepoint_check_never),
: _monitor(Mutex::nosafepoint, "WorkGangBarrierSync_lock"),
_n_workers(0), _n_completed(0), _should_reset(false), _aborted(false) {
}

Expand Down
4 changes: 2 additions & 2 deletions src/hotspot/share/gc/shenandoah/shenandoahControlThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@

ShenandoahControlThread::ShenandoahControlThread() :
ConcurrentGCThread(),
_alloc_failure_waiters_lock(Mutex::nonleaf, "ShenandoahAllocFailureGC_lock", Monitor::_safepoint_check_always, true),
_gc_waiters_lock(Mutex::nonleaf, "ShenandoahRequestedGC_lock", Monitor::_safepoint_check_always, true),
_alloc_failure_waiters_lock(Mutex::safepoint, "ShenandoahAllocFailureGC_lock", true),
_gc_waiters_lock(Mutex::safepoint, "ShenandoahRequestedGC_lock", true),
_periodic_task(this),
_requested_gc_cause(GCCause::_no_cause_specified),
_degen_point(ShenandoahGC::_degenerated_outside_cycle),
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/gc/shenandoah/shenandoahPacer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ class ShenandoahPacer : public CHeapObj<mtGC> {
_heap(heap),
_last_time(os::elapsedTime()),
_progress_history(new TruncatedSeq(5)),
_wait_monitor(new Monitor(Mutex::nonleaf-1, "ShenandoahWaitMonitor_lock", Monitor::_safepoint_check_always, true)),
_wait_monitor(new Monitor(Mutex::safepoint-1, "ShenandoahWaitMonitor_lock", true)),
_epoch(0),
_tax_rate(1),
_budget(0),
Expand Down
4 changes: 1 addition & 3 deletions src/hotspot/share/gc/z/zMessagePort.inline.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,7 @@ class ZMessageRequest : public StackObj {

template <typename T>
inline ZMessagePort<T>::ZMessagePort() :
_monitor(Monitor::nosafepoint,
"ZMessagePort_lock",
Monitor::_safepoint_check_never),
_monitor(Monitor::nosafepoint, "ZMessagePort_lock"),
_has_message(false),
_seqnum(0),
_queue() {}
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/gc/z/zMetronome.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
#include "utilities/ticks.hpp"

ZMetronome::ZMetronome(uint64_t hz) :
_monitor(Monitor::nosafepoint, "ZMetronome_lock", Monitor::_safepoint_check_never),
_monitor(Monitor::nosafepoint, "ZMetronome_lock"),
_interval_ms(MILLIUNITS / hz),
_start_ms(0),
_nticks(0),
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/memory/heapInspection.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ class ParHeapInspectTask : public AbstractGangTask {
_filter(filter),
_missed_count(0),
_success(true),
_mutex(Mutex::nosafepoint, "ParHeapInspectTask_lock", Mutex::_safepoint_check_never) {}
_mutex(Mutex::nosafepoint, "ParHeapInspectTask_lock") {}

uintx missed_count() const {
return _missed_count;
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/memory/metaspace/testHelpers.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ MetaspaceTestContext::~MetaspaceTestContext() {
// Create an arena, feeding off this area.
MetaspaceTestArena* MetaspaceTestContext::create_arena(Metaspace::MetaspaceType type) {
const ArenaGrowthPolicy* growth_policy = ArenaGrowthPolicy::policy_for_space_type(type, false);
Mutex* lock = new Mutex(Monitor::nosafepoint, "MetaspaceTestArea_lock", Monitor::_safepoint_check_never);
Mutex* lock = new Mutex(Monitor::nosafepoint, "MetaspaceTestArea_lock");
MetaspaceArena* arena = NULL;
{
MutexLocker ml(lock, Mutex::_no_safepoint_check_flag);
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/oops/methodData.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1207,7 +1207,7 @@ void MethodData::post_initialize(BytecodeStream* stream) {
MethodData::MethodData(const methodHandle& method)
: _method(method()),
// Holds Compile_lock
_extra_data_lock(Mutex::nonleaf-2, "MDOExtraData_lock", Mutex::_safepoint_check_always),
_extra_data_lock(Mutex::safepoint-2, "MDOExtraData_lock"),
_compiler_counters(),
_parameters_type_data_di(parameters_uninitialized) {
initialize();
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/prims/jvmtiTagMap.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ bool JvmtiTagMap::_has_object_free_events = false;
// create a JvmtiTagMap
JvmtiTagMap::JvmtiTagMap(JvmtiEnv* env) :
_env(env),
_lock(Mutex::nosafepoint, "JvmtiTagMap_lock", Mutex::_safepoint_check_never),
_lock(Mutex::nosafepoint, "JvmtiTagMap_lock"),
_needs_rehashing(false),
_needs_cleaning(false) {

Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/runtime/handshake.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,7 @@ void Handshake::execute(AsyncHandshakeClosure* hs_cl, JavaThread* target) {
HandshakeState::HandshakeState(JavaThread* target) :
_handshakee(target),
_queue(),
_lock(Monitor::nosafepoint, "HandshakeState_lock", Monitor::_safepoint_check_never),
_lock(Monitor::nosafepoint, "HandshakeState_lock"),
_active_handshaker(),
_suspended(false),
_async_suspend_handshake(false)
Expand Down
Loading