summaryrefslogtreecommitdiffstats
path: root/runtime/base/mutex.h
diff options
context:
space:
mode:
authorIan Rogers <irogers@google.com>2014-12-05 04:05:51 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2014-12-05 04:05:51 +0000
commitc5454372f23da8248c84c29e251fb1b21c421a63 (patch)
tree4b08c00ba9bc427771413a758c669df56dbba62d /runtime/base/mutex.h
parentaad9c0767a8f8ae6250a7b4edee52cfb6d598687 (diff)
parent015b137efb434528173779bc3ec8d72494456254 (diff)
downloadart-c5454372f23da8248c84c29e251fb1b21c421a63.tar.gz
art-c5454372f23da8248c84c29e251fb1b21c421a63.tar.bz2
art-c5454372f23da8248c84c29e251fb1b21c421a63.zip
Merge "Tidy gAborting."
Diffstat (limited to 'runtime/base/mutex.h')
-rw-r--r--runtime/base/mutex.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/runtime/base/mutex.h b/runtime/base/mutex.h
index 9c93cc624..41b5f12fd 100644
--- a/runtime/base/mutex.h
+++ b/runtime/base/mutex.h
@@ -220,7 +220,7 @@ class LOCKABLE Mutex : public BaseMutex {
// Assert that the Mutex is exclusively held by the current thread.
void AssertExclusiveHeld(const Thread* self) {
- if (kDebugLocking && (gAborting == 0)) {
+ if (kDebugLocking) {
CHECK(IsExclusiveHeld(self)) << *this;
}
}
@@ -228,7 +228,7 @@ class LOCKABLE Mutex : public BaseMutex {
// Assert that the Mutex is not held by the current thread.
void AssertNotHeldExclusive(const Thread* self) {
- if (kDebugLocking && (gAborting == 0)) {
+ if (kDebugLocking) {
CHECK(!IsExclusiveHeld(self)) << *this;
}
}
@@ -318,7 +318,7 @@ class LOCKABLE ReaderWriterMutex : public BaseMutex {
// Assert the current thread has exclusive access to the ReaderWriterMutex.
void AssertExclusiveHeld(const Thread* self) {
- if (kDebugLocking && (gAborting == 0)) {
+ if (kDebugLocking) {
CHECK(IsExclusiveHeld(self)) << *this;
}
}
@@ -326,7 +326,7 @@ class LOCKABLE ReaderWriterMutex : public BaseMutex {
// Assert the current thread doesn't have exclusive access to the ReaderWriterMutex.
void AssertNotExclusiveHeld(const Thread* self) {
- if (kDebugLocking && (gAborting == 0)) {
+ if (kDebugLocking) {
CHECK(!IsExclusiveHeld(self)) << *this;
}
}
@@ -337,7 +337,7 @@ class LOCKABLE ReaderWriterMutex : public BaseMutex {
// Assert the current thread has shared access to the ReaderWriterMutex.
void AssertSharedHeld(const Thread* self) {
- if (kDebugLocking && (gAborting == 0)) {
+ if (kDebugLocking) {
// TODO: we can only assert this well when self != NULL.
CHECK(IsSharedHeld(self) || self == NULL) << *this;
}
@@ -347,7 +347,7 @@ class LOCKABLE ReaderWriterMutex : public BaseMutex {
// Assert the current thread doesn't hold this ReaderWriterMutex either in shared or exclusive
// mode.
void AssertNotHeld(const Thread* self) {
- if (kDebugLocking && (gAborting == 0)) {
+ if (kDebugLocking) {
CHECK(!IsSharedHeld(self)) << *this;
}
}