diff options
author | Sebastien Hertz <shertz@google.com> | 2014-08-19 15:33:43 +0200 |
---|---|---|
committer | Sebastien Hertz <shertz@google.com> | 2014-09-02 19:28:34 +0200 |
commit | ed2be1725fb79075892b1a9103487c9d9a95b350 (patch) | |
tree | 8adf1d95f401c2c7e7df1c659c0dfcd4dd27a68f /runtime/base/mutex.h | |
parent | 645f9871115e82ff836397f6470cca825befd245 (diff) | |
download | art-ed2be1725fb79075892b1a9103487c9d9a95b350.zip art-ed2be1725fb79075892b1a9103487c9d9a95b350.tar.gz art-ed2be1725fb79075892b1a9103487c9d9a95b350.tar.bz2 |
Reduce lock contention when debugging
Uses a ReaderWriterMutex for the breakpoint lock to reduce contention during
debugging session.
Also adds missing thread safety annotations on fields and methods related to
instrumentation and debugging.
Bug: 16814665
Bug: 11667502
(cherry picked from commit 59d9d668d4f4286813afe2b4e7c6db839222ce96)
Change-Id: I5f1156da8c6cc8316d6db16e6cfb2470fe289ad3
Diffstat (limited to 'runtime/base/mutex.h')
-rw-r--r-- | runtime/base/mutex.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/runtime/base/mutex.h b/runtime/base/mutex.h index fd76629..2a623fd 100644 --- a/runtime/base/mutex.h +++ b/runtime/base/mutex.h @@ -565,7 +565,7 @@ class Locks { static Mutex* jni_libraries_lock_ ACQUIRED_AFTER(thread_list_lock_); // Guards breakpoints. - static Mutex* breakpoint_lock_ ACQUIRED_AFTER(jni_libraries_lock_); + static ReaderWriterMutex* breakpoint_lock_ ACQUIRED_AFTER(jni_libraries_lock_); // Guards lists of classes within the class linker. static ReaderWriterMutex* classlinker_classes_lock_ ACQUIRED_AFTER(breakpoint_lock_); |