mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 23:04:50 +02:00
8222811: Consolidate MutexLockerEx and MutexLocker
Make MutexLocker be MutexLockerEx implementation, remove MutexLockerEx calls. Reviewed-by: dcubed, dholmes, pliden, rehn
This commit is contained in:
parent
88303d1c60
commit
fbafef11c0
127 changed files with 718 additions and 746 deletions
|
@ -150,7 +150,7 @@ SymbolTable::SymbolTable() :
|
|||
|
||||
void SymbolTable::delete_symbol(Symbol* sym) {
|
||||
if (sym->refcount() == PERM_REFCOUNT) {
|
||||
MutexLockerEx ml(SymbolArena_lock, Mutex::_no_safepoint_check_flag); // Protect arena
|
||||
MutexLocker ml(SymbolArena_lock, Mutex::_no_safepoint_check_flag); // Protect arena
|
||||
// Deleting permanent symbol should not occur very often (insert race condition),
|
||||
// so log it.
|
||||
log_trace_symboltable_helper(sym, "Freeing permanent symbol");
|
||||
|
@ -190,7 +190,7 @@ size_t SymbolTable::table_size() {
|
|||
}
|
||||
|
||||
void SymbolTable::trigger_cleanup() {
|
||||
MutexLockerEx ml(Service_lock, Mutex::_no_safepoint_check_flag);
|
||||
MutexLocker ml(Service_lock, Mutex::_no_safepoint_check_flag);
|
||||
SymbolTable::the_table()->_has_work = true;
|
||||
Service_lock->notify_all();
|
||||
}
|
||||
|
@ -208,7 +208,7 @@ Symbol* SymbolTable::allocate_symbol(const char* name, int len, bool c_heap, TRA
|
|||
assert(sym != NULL, "new should call vm_exit_out_of_memory if C_HEAP is exhausted");
|
||||
} else {
|
||||
// Allocate to global arena
|
||||
MutexLockerEx ml(SymbolArena_lock, Mutex::_no_safepoint_check_flag); // Protect arena
|
||||
MutexLocker ml(SymbolArena_lock, Mutex::_no_safepoint_check_flag); // Protect arena
|
||||
sym = new (len, arena(), THREAD) Symbol((const u1*)name, len, PERM_REFCOUNT);
|
||||
}
|
||||
return sym;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue