summaryrefslogtreecommitdiff
path: root/runtime/base/mutex.cc
diff options
context:
space:
mode:
author Andreas Gampe <agampe@google.com> 2014-07-10 07:54:06 +0000
committer Gerrit Code Review <noreply-gerritcodereview@google.com> 2014-07-09 14:45:53 +0000
commitc4f72ec44660f804b595bfaf2b959f46fd2ff00d (patch)
treedf8764e4ec382b4e4810b8d0309823a40ef47d5c /runtime/base/mutex.cc
parentaf4cf5d72a2bf77f0e442bedb208f9227f262c89 (diff)
parent74240819ae09e29b2753ef38f4eb4be1c2762e2e (diff)
Merge "Use memory chunks for monitors on LP64"
Diffstat (limited to 'runtime/base/mutex.cc')
-rw-r--r--runtime/base/mutex.cc6
1 files changed, 6 insertions, 0 deletions
diff --git a/runtime/base/mutex.cc b/runtime/base/mutex.cc
index bde28866c9..7779547725 100644
--- a/runtime/base/mutex.cc
+++ b/runtime/base/mutex.cc
@@ -30,6 +30,7 @@
namespace art {
Mutex* Locks::abort_lock_ = nullptr;
+Mutex* Locks::allocated_monitor_ids_lock_ = nullptr;
Mutex* Locks::allocated_thread_ids_lock_ = nullptr;
Mutex* Locks::breakpoint_lock_ = nullptr;
ReaderWriterMutex* Locks::classlinker_classes_lock_ = nullptr;
@@ -832,6 +833,7 @@ void Locks::Init() {
DCHECK(modify_ldt_lock_ == nullptr);
}
DCHECK(abort_lock_ != nullptr);
+ DCHECK(allocated_monitor_ids_lock_ != nullptr);
DCHECK(allocated_thread_ids_lock_ != nullptr);
DCHECK(breakpoint_lock_ != nullptr);
DCHECK(classlinker_classes_lock_ != nullptr);
@@ -883,6 +885,10 @@ void Locks::Init() {
classlinker_classes_lock_ = new ReaderWriterMutex("ClassLinker classes lock",
current_lock_level);
+ UPDATE_CURRENT_LOCK_LEVEL(kMonitorPoolLock);
+ DCHECK(allocated_monitor_ids_lock_ == nullptr);
+ allocated_monitor_ids_lock_ = new Mutex("allocated monitor ids lock", current_lock_level);
+
UPDATE_CURRENT_LOCK_LEVEL(kAllocatedThreadIdsLock);
DCHECK(allocated_thread_ids_lock_ == nullptr);
allocated_thread_ids_lock_ = new Mutex("allocated thread ids lock", current_lock_level);