Log when binder thread pool is starved
Log when the number of threads executing binder commands is equal to the
maximium size of the thread pool for >100ms.
Bug: 28201939
Change-Id: I892863d8a81c06e362d4ae18ab08485fdec3c0bb
diff --git a/include/binder/ProcessState.h b/include/binder/ProcessState.h
index f9edc2a..64cf72e 100644
--- a/include/binder/ProcessState.h
+++ b/include/binder/ProcessState.h
@@ -91,6 +91,8 @@
size_t mExecutingThreadsCount;
// Maximum number for binder threads allowed for this process.
size_t mMaxThreads;
+ // Time when thread pool was emptied
+ int64_t mStarvationStartTimeMs;
mutable Mutex mLock; // protects everything below.