diff options
author | 2017-06-29 11:59:50 -0700 | |
---|---|---|
committer | 2017-06-30 14:24:56 +0000 | |
commit | 46f9340f2a055a8fdfebbfbb739c697c20d83e7c (patch) | |
tree | acb172f74723e4ea9ac7ded73b94c661217ec90d /runtime/thread.h | |
parent | fe9a4f061841a3c597aac6817a47c799c54fcad7 (diff) |
Add SuspendReason enum and change Suspension functions.
More self-documenting and more type safe.
Bug: 62821960
Test: ./test.py
Change-Id: Ic7a1ae6a25e687d65f5aa10c1aad54a7b80dd086
Diffstat (limited to 'runtime/thread.h')
-rw-r--r-- | runtime/thread.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/runtime/thread.h b/runtime/thread.h index 770173e47e..e785ddc803 100644 --- a/runtime/thread.h +++ b/runtime/thread.h @@ -40,6 +40,7 @@ #include "managed_stack.h" #include "offsets.h" #include "runtime_stats.h" +#include "suspend_reason.h" #include "thread_state.h" class BacktraceMap; @@ -244,7 +245,7 @@ class Thread { bool ModifySuspendCount(Thread* self, int delta, AtomicInteger* suspend_barrier, - bool for_debugger) + SuspendReason reason) WARN_UNUSED REQUIRES(Locks::thread_suspend_count_lock_); @@ -1300,7 +1301,7 @@ class Thread { bool ModifySuspendCountInternal(Thread* self, int delta, AtomicInteger* suspend_barrier, - bool for_debugger) + SuspendReason reason) WARN_UNUSED REQUIRES(Locks::thread_suspend_count_lock_); |