TaskSchedulerSingleThreadTaskRunnerManagerStartTest.PostTaskBeforeStart flaky on Fuchsia x64 |
|||
Issue descriptionIn try https://ci.chromium.org/p/chromium/builders/luci.chromium.try/fuchsia_x64/58619 this flaked with: [ RUN ] TaskSchedulerSingleThreadTaskRunnerManagerStartTest.PostTaskBeforeStart [80448:6893521:0709/183824.522289:46254667:FATAL:scheduler_worker.cc(92)] Check failed: !should_exit_.IsSet(). #00: base::debug::StackTrace::StackTrace(unsigned long) at ../../base/debug/stack_trace_fuchsia.cc:173 #01: endl<char, std::__2::char_traits<char> > at ../../buildtools/third_party/libc++/trunk/include/ostream:1001 (inlined by) operator<< at ../../buildtools/third_party/libc++/trunk/include/ostream:195 (inlined by) ~LogMessage at ../../base/logging.cc:593 #02: WakeUp at ../../base/task_scheduler/scheduler_worker.cc:93 #03: Release at ../../base/memory/ref_counted.h:385 (inlined by) Release at ../../base/memory/scoped_refptr.h:284 (inlined by) ~scoped_refptr at ../../base/memory/scoped_refptr.h:208 (inlined by) Start at ../../base/task_scheduler/scheduler_single_thread_task_runner_manager.cc:430 #04: TestBody at ../../base/task_scheduler/scheduler_single_thread_task_runner_manager_unittest.cc:655 #05: os_stack_trace_getter at ../../third_party/googletest/src/googletest/src/gtest.cc:5332 (inlined by) Run at ../../third_party/googletest/src/googletest/src/gtest.cc:2498 #06: os_stack_trace_getter at ../../third_party/googletest/src/googletest/src/gtest.cc:5332 (inlined by) Run at ../../third_party/googletest/src/googletest/src/gtest.cc:2671 #07: Run at ../../third_party/googletest/src/googletest/src/gtest.cc:2784 #08: RunAllTests at ../../third_party/googletest/src/googletest/src/gtest.cc:5046 #09: Run at ./../../third_party/googletest/src/googletest/src/gtest.cc:? #10: RUN_ALL_TESTS at ../../third_party/googletest/src/googletest/include/gtest/gtest.h:2329 (inlined by) Run at ../../base/test/test_suite.cc:277 #11: Run at ../../base/callback.h:99 (inlined by) LaunchUnitTestsInternal at ../../base/test/launcher/unit_test_launcher.cc:225 #12: LaunchUnitTests at ../../base/test/launcher/unit_test_launcher.cc:576 #13: main at ../../base/test/run_all_base_unittests.cc:12 #14: pc 0x6f412a940e0e (libc.so,0x19e0e) [00046.315] pkgsvr: 2018/07/09 18:38:24 pkgfs:unsupported(/packages/base_unittests/0): dir unlink "app.log" [00046.325] pkgsvr: 2018/07/09 18:38:24 pkgfs:unsupported(/packages/base_unittests/0): dir unlink "app.log" [1653/3112] TaskSchedulerSingleThreadTaskRunnerManagerStartTest.PostTaskBeforeStart (CRASHED) Note that there are already test-ordering-dependent ASAN reports in issue 763055 and issue 763100 , and an Android+ASAN report in issue 754676, although those look to have (in principle) been resolved by robliao@'s https://chromium-review.googlesource.com/773299.
,
Jul 11
,
Jul 12
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/291f0a739f2c952d402f76d3750b9a2340269c18 commit 291f0a739f2c952d402f76d3750b9a2340269c18 Author: Wez <wez@chromium.org> Date: Thu Jul 12 19:42:09 2018 Fix race-condition in SchedulerSingleThreadTaskRunnerManager::Start(). SchedulerSingleThreadTaskRunnerManager allows SingleThreadTaskRunners to be created and tasks posted to them before the worker threads are actually started. The call to Start() the required workers was calling both Start() and WakeUp() on each of them, the latter being unnecessary since if a worker needs to process work then it must already have been woken, when the work was PostTask()d into it. Besides removing an unnecessary wake-up, this resolves a subtle race- condition between wake-up and a potential worker clean-up (see bug). Bug: 862582 Change-Id: I9c4246cec4b1bda6d728e5e1656bb2c5ca7c0f0a Reviewed-on: https://chromium-review.googlesource.com/1133279 Commit-Queue: Wez <wez@chromium.org> Reviewed-by: Robert Liao <robliao@chromium.org> Reviewed-by: Gabriel Charette <gab@chromium.org> Cr-Commit-Position: refs/heads/master@{#574681} [modify] https://crrev.com/291f0a739f2c952d402f76d3750b9a2340269c18/base/task_scheduler/scheduler_single_thread_task_runner_manager.cc
,
Jul 12
|
|||
►
Sign in to add a comment |
|||
Comment 1 by w...@chromium.org
, Jul 11Status: Started (was: Untriaged)