Index: base/task_scheduler/task_tracker.cc |
diff --git a/base/task_scheduler/task_tracker.cc b/base/task_scheduler/task_tracker.cc |
index 55230aa93742ee3c58da9d43a2a67dc72d452cd8..5509e3219cb563bc9063c76d4dea6b2b5af64d31 100644 |
--- a/base/task_scheduler/task_tracker.cc |
+++ b/base/task_scheduler/task_tracker.cc |
@@ -388,6 +388,10 @@ bool TaskTracker::IsPostingBlockShutdownTaskAfterShutdownAllowed() { |
} |
#endif |
+int TaskTracker::GetNumPendingUndelayedTasksForTesting() const { |
+ return subtle::Acquire_Load(&num_pending_undelayed_tasks_); |
gab
2017/05/23 15:26:13
Reason to Acquire_Load?
fdoray
2017/05/25 19:17:33
I would have liked to Acquire_NoBarrier, but this
gab
2017/05/25 19:29:29
As mentioned offline there is NoBarrier_Load
fdoray
2017/05/25 20:06:44
Done.
|
+} |
+ |
bool TaskTracker::BeforePostTask(TaskShutdownBehavior shutdown_behavior) { |
if (shutdown_behavior == TaskShutdownBehavior::BLOCK_SHUTDOWN) { |
// BLOCK_SHUTDOWN tasks block shutdown between the moment they are posted |