commit | 857fbed2468c25c0e33177d94fcfe46c9d29c282 | [log] [tgz] |
---|---|---|
author | Nate Chapin <japhet@chromium.org> | Fri May 18 19:33:48 2018 |
committer | Commit Bot <commit-bot@chromium.org> | Fri May 18 19:33:48 2018 |
tree | 6061f2ba319b003a94e5e710c9032fb616f688b3 | |
parent | 1420966557eb13e63ddf167e193a8e80d09cd601 [diff] |
Prepare WorkerThreadableLoader for nested workers The logic of WorkerThreadableLoader actually supports nested workers as-is (i.e., it will proxy a nested worker's sync request and run it as an async request on the parent worker's thread), but it does a lot of DCHECKs based on IsMainThread(), which will fail because a nested worker's parent isn't on the main thread. * Initial cleanup step: AsyncTaskForwarder is dead code. Remove it and flatten SyncTaskForward into TaskForwarder. * Rename anything that mentions the main thread to refer to the parent thread instead. * Make DocumentThreadableLoader::GetExecutionContext() public, and use its IsContextThread() for DCHECKs in ParentThreadLoaderHolder * Use WorkerThreadableLoader::worker_global_scope_ for DCHECKS in WorkerThreadableLoader itself. * Plumb a worker task runner to TaskForwarder and WaitableEventWithTasks (#if DCHECK_IS_ON()) for their thread safety checks. Bug: 829119 Change-Id: Ied542e99f2566462f290ae5e0a0d1da57e63730f Reviewed-on: https://chromium-review.googlesource.com/1064796 Commit-Queue: Nate Chapin <japhet@chromium.org> Reviewed-by: Hiroki Nakagawa <nhiroki@chromium.org> Cr-Commit-Position: refs/heads/master@{#559991}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .