| Index: runtime/vm/thread_registry.cc
|
| diff --git a/runtime/vm/thread_registry.cc b/runtime/vm/thread_registry.cc
|
| index eb39501bc0db930332b1975252287f3673306a72..4694cc06a8771c7590f5e378d8bb171aefb851f3 100644
|
| --- a/runtime/vm/thread_registry.cc
|
| +++ b/runtime/vm/thread_registry.cc
|
| @@ -105,6 +105,30 @@ void ThreadRegistry::PrintJSON(JSONStream* stream) const {
|
| #endif
|
|
|
|
|
| +intptr_t ThreadRegistry::CountZoneHandles() const {
|
| + MonitorLocker ml(threads_lock());
|
| + intptr_t count = 0;
|
| + Thread* current = active_list_;
|
| + while (current != NULL) {
|
| + count += current->CountZoneHandles();
|
| + current = current->next_;
|
| + }
|
| + return count;
|
| +}
|
| +
|
| +
|
| +intptr_t ThreadRegistry::CountScopedHandles() const {
|
| + MonitorLocker ml(threads_lock());
|
| + intptr_t count = 0;
|
| + Thread* current = active_list_;
|
| + while (current != NULL) {
|
| + count += current->CountScopedHandles();
|
| + current = current->next_;
|
| + }
|
| + return count;
|
| +}
|
| +
|
| +
|
| void ThreadRegistry::AddToActiveListLocked(Thread* thread) {
|
| ASSERT(thread != NULL);
|
| ASSERT(threads_lock()->IsOwnedByCurrentThread());
|
|
|