diff options
author | 2023-12-19 18:48:15 +0000 | |
---|---|---|
committer | 2023-12-19 20:32:27 +0000 | |
commit | 8bc6a58df7046b4d6f4b51eb274c7e60fea396ff (patch) | |
tree | ac6aa639279f5cf2048cb147a91cbea98c8088a4 /runtime/cha.cc | |
parent | ee7471ec0a7aba338c3ac90de0f2ef0be9a35fed (diff) |
Revert^17 "Thread suspension cleanup and deadlock fix"
This reverts commit c6371b52df0da31acc174a3526274417b7aac0a7.
Reason for revert: This seems to have two remaining issues:
1. The second DCHECK in WaitForFlipFunction is not completely guaranteed to hold, resulting in failures for 658-fp-read-barrier.
2. WaitForSuspendBarrier seems to time out occasionally, possibly spuriously so. We fail when the futex times out once. That's probably incompatible with the app freezer. We should retry a few times.
Change-Id: Ibd8909b31083fc29e6d4f1fcde003d08eb16fc0a
Diffstat (limited to 'runtime/cha.cc')
-rw-r--r-- | runtime/cha.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/runtime/cha.cc b/runtime/cha.cc index 0c548d384a..8b77f76146 100644 --- a/runtime/cha.cc +++ b/runtime/cha.cc @@ -237,10 +237,11 @@ class CHACheckpoint final : public Closure { : barrier_(0), method_headers_(method_headers) {} - void Run(Thread* thread) override REQUIRES_SHARED(Locks::mutator_lock_) { + void Run(Thread* thread) override { // Note thread and self may not be equal if thread was already suspended at // the point of the request. Thread* self = Thread::Current(); + ScopedObjectAccess soa(self); CHAStackVisitor visitor(thread, nullptr, method_headers_); visitor.WalkStack(); barrier_.Pass(self); |