Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(430)

Issue 2445763002: Disallow posting tasks to SequencedWorkerPools by default. (Closed)

Created:
4 years, 1 month ago by fdoray
Modified:
4 years ago
Reviewers:
gab, brettw
CC:
chromium-reviews, mlamouri+watch-content_chromium.org, jam, darin-cc_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Disallow posting tasks to SequencedWorkerPools by default. We have observed crash reports in which SequencedWorkerPool workers were active while redirection to TaskScheduler was enabled. This can happen if a task is posted to a SequencedWorkerPool before redirection to TaskScheduler is enabled. With this CL, DumpWithoutCrashing() is called if a task is posted to a SequencedWorkerPool too early. This will help us find offending call sites. A commented DCHECK is also added to find offending call sites. It will be uncommented in a separate CL to avoid a revert of this CL in case it fails on the waterfall. BUG=622400 Committed: https://crrev.com/4606ada249a240e115a08a7c66409e8fdd457ea1 Committed: https://crrev.com/8fd22217395d50b6704109c7f1d4deff59f9a109 Committed: https://crrev.com/50a3834c24c1e4a4a61130db156405240b04b346 Cr-Original-Original-Commit-Position: refs/heads/master@{#432913} Cr-Original-Commit-Position: refs/heads/master@{#433237} Cr-Commit-Position: refs/heads/master@{#433639}

Patch Set 1 #

Patch Set 2 : move #

Patch Set 3 : allow test launcher #

Patch Set 4 : move #

Patch Set 5 : ios #

Patch Set 6 : refactor #

Patch Set 7 : self-review #

Patch Set 8 : self-review #

Patch Set 9 : enable in service process #

Patch Set 10 : rebase #

Patch Set 11 : fix build error #

Patch Set 12 : fix build error #

Patch Set 13 : fix test errors #

Patch Set 14 : refactor #

Patch Set 15 : refactor #

Patch Set 16 : fix test errors #

Patch Set 17 : self-review #

Patch Set 18 : self-review #

Patch Set 19 : self-review #

Total comments: 6

Patch Set 20 : CR gab #57 #

Total comments: 6

Patch Set 21 : CR gab #61 #

Patch Set 22 : self-review #

Total comments: 2

Patch Set 23 : rebase #

Patch Set 24 : rebase #

Patch Set 25 : rebase #

Patch Set 26 : prevent DCHECK failures when SWP is not enabled #

Patch Set 27 : rebase #

Patch Set 28 : self-review #

Patch Set 29 : self-review #

Unified diffs Side-by-side diffs Delta from patch set Stats (+162 lines, -110 lines) Patch
M base/test/launcher/test_launcher.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 26 2 chunks +6 lines, -0 lines 0 comments Download
M base/test/test_suite.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 24 26 2 chunks +6 lines, -0 lines 0 comments Download
M base/threading/sequenced_worker_pool.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 26 2 chunks +23 lines, -17 lines 0 comments Download
M base/threading/sequenced_worker_pool.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 25 chunks +69 lines, -89 lines 0 comments Download
M base/threading/sequenced_worker_pool_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 26 2 chunks +12 lines, -3 lines 0 comments Download
M chrome/service/service_process.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 26 1 chunk +6 lines, -0 lines 0 comments Download
M components/task_scheduler_util/initialization_util.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 26 1 chunk +3 lines, -1 line 0 comments Download
M content/browser/browser_main_loop.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 3 chunks +14 lines, -0 lines 0 comments Download
M content/public/test/browser_test_base.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 26 2 chunks +8 lines, -0 lines 0 comments Download
M content/renderer/render_thread_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 2 chunks +8 lines, -0 lines 0 comments Download
M content/renderer/render_thread_impl_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 26 2 chunks +7 lines, -0 lines 0 comments Download

Messages

Total messages: 126 (101 generated)
gab
https://codereview.chromium.org/2445763002/diff/360001/base/threading/sequenced_worker_pool.cc File base/threading/sequenced_worker_pool.cc (right): https://codereview.chromium.org/2445763002/diff/360001/base/threading/sequenced_worker_pool.cc#newcode1409 base/threading/sequenced_worker_pool.cc:1409: void SequencedWorkerPool::EnableForProcess() { DCHECK_EQ(POST_TASK_DISABLED, ...)? https://codereview.chromium.org/2445763002/diff/360001/base/threading/sequenced_worker_pool.cc#newcode1416 base/threading/sequenced_worker_pool.cc:1416: DCHECK_EQ(AllPoolsState::POST_TASK_DISABLED, g_all_pools_state); ...
4 years, 1 month ago (2016-11-01 16:09:48 UTC) #57
fdoray
PTAnL https://codereview.chromium.org/2445763002/diff/360001/base/threading/sequenced_worker_pool.cc File base/threading/sequenced_worker_pool.cc (right): https://codereview.chromium.org/2445763002/diff/360001/base/threading/sequenced_worker_pool.cc#newcode1409 base/threading/sequenced_worker_pool.cc:1409: void SequencedWorkerPool::EnableForProcess() { On 2016/11/01 16:09:47, gab wrote: ...
4 years, 1 month ago (2016-11-01 20:40:29 UTC) #60
gab
Also, add CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_chromium_tsan_rel_ng to your CL's description to catch anything now instead of on waterfall ...
4 years, 1 month ago (2016-11-01 21:48:02 UTC) #61
fdoray
PTAnL https://codereview.chromium.org/2445763002/diff/380001/base/threading/sequenced_worker_pool.h File base/threading/sequenced_worker_pool.h (right): https://codereview.chromium.org/2445763002/diff/380001/base/threading/sequenced_worker_pool.h#newcode205 base/threading/sequenced_worker_pool.h:205: // Returns true is posting tasks to this ...
4 years, 1 month ago (2016-11-02 12:56:09 UTC) #66
gab
lgtm https://codereview.chromium.org/2445763002/diff/420001/chrome/browser/chrome_browser_main.cc File chrome/browser/chrome_browser_main.cc (right): https://codereview.chromium.org/2445763002/diff/420001/chrome/browser/chrome_browser_main.cc#newcode332 chrome/browser/chrome_browser_main.cc:332: return sequenced_worker_pool_redirected; No var, just return false on ...
4 years, 1 month ago (2016-11-02 13:29:55 UTC) #68
fdoray
brettw@: PTAL https://codereview.chromium.org/2445763002/diff/420001/chrome/browser/chrome_browser_main.cc File chrome/browser/chrome_browser_main.cc (right): https://codereview.chromium.org/2445763002/diff/420001/chrome/browser/chrome_browser_main.cc#newcode332 chrome/browser/chrome_browser_main.cc:332: return sequenced_worker_pool_redirected; On 2016/11/02 13:29:55, gab wrote: ...
4 years, 1 month ago (2016-11-02 20:02:16 UTC) #72
brettw
lgtm
4 years, 1 month ago (2016-11-16 18:33:56 UTC) #81
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2445763002/460001
4 years, 1 month ago (2016-11-16 22:12:48 UTC) #85
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_chromeos_compile_dbg_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_chromeos_compile_dbg_ng/builds/299514) linux_chromium_chromeos_ozone_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, ...
4 years, 1 month ago (2016-11-17 00:28:00 UTC) #87
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2445763002/460001
4 years, 1 month ago (2016-11-17 13:28:57 UTC) #89
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_chromeos_ozone_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_chromeos_ozone_rel_ng/builds/274603)
4 years, 1 month ago (2016-11-17 15:30:01 UTC) #91
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2445763002/460001
4 years, 1 month ago (2016-11-17 15:55:27 UTC) #93
commit-bot: I haz the power
Committed patchset #24 (id:460001)
4 years, 1 month ago (2016-11-17 18:07:58 UTC) #95
commit-bot: I haz the power
Patchset 24 (id:??) landed as https://crrev.com/4606ada249a240e115a08a7c66409e8fdd457ea1 Cr-Commit-Position: refs/heads/master@{#432913}
4 years, 1 month ago (2016-11-17 18:25:22 UTC) #97
Evan Stade
A revert of this CL (patchset #24 id:460001) has been created in https://codereview.chromium.org/2517443002/ by estade@chromium.org. ...
4 years, 1 month ago (2016-11-17 22:12:00 UTC) #98
fdoray
Re-landing with commented DCHECK...
4 years, 1 month ago (2016-11-18 14:42:15 UTC) #101
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2445763002/480001
4 years, 1 month ago (2016-11-18 14:42:32 UTC) #104
commit-bot: I haz the power
Committed patchset #25 (id:480001)
4 years, 1 month ago (2016-11-18 18:13:59 UTC) #106
commit-bot: I haz the power
Patchset 25 (id:??) landed as https://crrev.com/8fd22217395d50b6704109c7f1d4deff59f9a109 Cr-Commit-Position: refs/heads/master@{#433237}
4 years, 1 month ago (2016-11-18 18:16:47 UTC) #108
Fady Samuel
A revert of this CL (patchset #25 id:480001) has been created in https://codereview.chromium.org/2519543002/ by fsamuel@chromium.org. ...
4 years, 1 month ago (2016-11-18 19:34:13 UTC) #109
fdoray
On 2016/11/18 19:34:13, Fady Samuel wrote: > A revert of this CL (patchset #25 id:480001) ...
4 years ago (2016-11-21 15:24:07 UTC) #111
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2445763002/560001
4 years ago (2016-11-21 15:35:30 UTC) #114
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2445763002/560001
4 years ago (2016-11-21 20:40:05 UTC) #121
commit-bot: I haz the power
Committed patchset #29 (id:560001)
4 years ago (2016-11-21 20:46:43 UTC) #124
commit-bot: I haz the power
4 years ago (2016-11-21 20:48:49 UTC) #126
Message was sent while issue was closed.
Patchset 29 (id:??) landed as
https://crrev.com/50a3834c24c1e4a4a61130db156405240b04b346
Cr-Commit-Position: refs/heads/master@{#433639}

Powered by Google App Engine
This is Rietveld 408576698