OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "base/task_scheduler/scheduler_worker_pool_impl.h" | 5 #include "base/task_scheduler/scheduler_worker_pool_impl.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <memory> | 9 #include <memory> |
10 #include <unordered_set> | 10 #include <unordered_set> |
11 #include <vector> | 11 #include <vector> |
12 | 12 |
13 #include "base/atomicops.h" | 13 #include "base/atomicops.h" |
14 #include "base/bind.h" | 14 #include "base/bind.h" |
15 #include "base/bind_helpers.h" | 15 #include "base/bind_helpers.h" |
16 #include "base/callback.h" | 16 #include "base/callback.h" |
17 #include "base/macros.h" | 17 #include "base/macros.h" |
18 #include "base/memory/ptr_util.h" | 18 #include "base/memory/ptr_util.h" |
19 #include "base/memory/ref_counted.h" | 19 #include "base/memory/ref_counted.h" |
20 #include "base/synchronization/condition_variable.h" | 20 #include "base/synchronization/condition_variable.h" |
21 #include "base/synchronization/lock.h" | 21 #include "base/synchronization/lock.h" |
22 #include "base/synchronization/waitable_event.h" | 22 #include "base/synchronization/waitable_event.h" |
23 #include "base/task_runner.h" | 23 #include "base/task_runner.h" |
24 #include "base/task_scheduler/delayed_task_manager.h" | 24 #include "base/task_scheduler/delayed_task_manager.h" |
25 #include "base/task_scheduler/scheduler_worker_pool_params.h" | 25 #include "base/task_scheduler/scheduler_worker_pool_params.h" |
26 #include "base/task_scheduler/sequence.h" | 26 #include "base/task_scheduler/sequence.h" |
27 #include "base/task_scheduler/sequence_sort_key.h" | 27 #include "base/task_scheduler/sequence_sort_key.h" |
28 #include "base/task_scheduler/task_tracker.h" | 28 #include "base/task_scheduler/task_tracker.h" |
29 #include "base/task_scheduler/test_task_factory.h" | 29 #include "base/task_scheduler/test_task_factory.h" |
30 #include "base/task_scheduler/test_utils.h" | 30 #include "base/test/gtest_util.h" |
31 #include "base/threading/platform_thread.h" | 31 #include "base/threading/platform_thread.h" |
32 #include "base/threading/simple_thread.h" | 32 #include "base/threading/simple_thread.h" |
33 #include "base/threading/thread_checker_impl.h" | 33 #include "base/threading/thread_checker_impl.h" |
34 #include "base/threading/thread_local_storage.h" | 34 #include "base/threading/thread_local_storage.h" |
35 #include "base/threading/thread_restrictions.h" | 35 #include "base/threading/thread_restrictions.h" |
36 #include "base/time/time.h" | 36 #include "base/time/time.h" |
37 #include "testing/gtest/include/gtest/gtest.h" | 37 #include "testing/gtest/include/gtest/gtest.h" |
38 | 38 |
39 namespace base { | 39 namespace base { |
40 namespace internal { | 40 namespace internal { |
(...skipping 510 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
551 count_waiter->Wait(); | 551 count_waiter->Wait(); |
552 | 552 |
553 EXPECT_GT(subtle::NoBarrier_Load(&zero_tls_values_), 0); | 553 EXPECT_GT(subtle::NoBarrier_Load(&zero_tls_values_), 0); |
554 | 554 |
555 // Release tasks waiting on |waiter_|. | 555 // Release tasks waiting on |waiter_|. |
556 waiter_.Signal(); | 556 waiter_.Signal(); |
557 } | 557 } |
558 | 558 |
559 } // namespace internal | 559 } // namespace internal |
560 } // namespace base | 560 } // namespace base |
OLD | NEW |