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

Issue 2910953002: Worklet: Enqueue tasks into outsideSetting's event loop (Closed)

Created:
3 years, 6 months ago by nhiroki
Modified:
3 years, 6 months ago
Reviewers:
kinuko, falken, haraken
CC:
chromium-reviews, shimazu+worker_chromium.org, kinuko+worker_chromium.org, blink-reviews, horo+watch_chromium.org, falken+watch_chromium.org, blink-worker-reviews_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Worklet: Enqueue tasks into outsideSetting's event loop The Worklet spec requires some of tasks during addModule() algorithm are enqueued into the outsideSetting's event loop. From implementation point of view, this corresponds to parent frame's task runners. This CL introduces the parent frame task runners for such places. Note that in the current implementation all code related to addModule() run on the main thread because only the main thread worklets support module loading, so technically this change is not necessary for now. This change will be really necessary when the threaded worklets also support module loading to jump over the thread boundary between the main thread and worklet's context thread. There are no unit tests, but layout tests confirm this change doesn't break any thing. Spec: https://drafts.css-houdini.org/worklets/#dom-worklet-addmodule DesignDoc: https://docs.google.com/document/d/1cgLcrua7H_7x_o5GlzYrAi2qt-TqTzgtOeixFAugR6g/edit?usp=sharing BUG=727194 Review-Url: https://codereview.chromium.org/2910953002 Cr-Commit-Position: refs/heads/master@{#475456} Committed: https://chromium.googlesource.com/chromium/src/+/315dddc6bbfe2ca11f6d3b127f02e5fc66d71aae

Patch Set 1 #

Total comments: 2

Patch Set 2 : clean up #

Patch Set 3 : fix #

Total comments: 8

Patch Set 4 : add comments #

Total comments: 4

Patch Set 5 : ParentFrameTaskRunners -> WebTaskRunner #

Patch Set 6 : fix header inclusion #

Total comments: 4

Patch Set 7 : outside_settings_task_runner #

Total comments: 2

Messages

Total messages: 47 (29 generated)
nhiroki
PTAL, thanks!
3 years, 6 months ago (2017-05-29 09:44:28 UTC) #11
kinuko
https://codereview.chromium.org/2910953002/diff/40001/third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h File third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h (right): https://codereview.chromium.org/2910953002/diff/40001/third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h#newcode32 third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h:32: CrossThreadPersistent<ParentFrameTaskRunners> task_runners_; Does this need to be cross-thread persistent?
3 years, 6 months ago (2017-05-29 14:08:55 UTC) #16
nhiroki
Thank you. https://codereview.chromium.org/2910953002/diff/40001/third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h File third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h (right): https://codereview.chromium.org/2910953002/diff/40001/third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h#newcode32 third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h:32: CrossThreadPersistent<ParentFrameTaskRunners> task_runners_; On 2017/05/29 14:08:55, kinuko wrote: ...
3 years, 6 months ago (2017-05-29 14:25:03 UTC) #17
falken
Some nitty comments. Is there no unit test appropriate for this CL? https://codereview.chromium.org/2910953002/diff/80001/third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp File third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp ...
3 years, 6 months ago (2017-05-30 01:33:23 UTC) #20
nhiroki
Thanks for your comments. On 2017/05/30 01:33:23, falken wrote: > Some nitty comments. > > ...
3 years, 6 months ago (2017-05-30 02:14:08 UTC) #21
nhiroki
https://codereview.chromium.org/2910953002/diff/80001/third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp File third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp (right): https://codereview.chromium.org/2910953002/diff/80001/third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp#newcode63 third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp:63: // purpose. On 2017/05/30 01:33:23, falken wrote: > Would ...
3 years, 6 months ago (2017-05-30 02:14:23 UTC) #22
falken
On 2017/05/30 02:14:08, nhiroki (slow) wrote: > Thanks for your comments. > > On 2017/05/30 ...
3 years, 6 months ago (2017-05-30 02:18:01 UTC) #23
falken
ah sent that too early. lgtm.
3 years, 6 months ago (2017-05-30 02:19:10 UTC) #24
kinuko
Looking good, a few more questions... https://codereview.chromium.org/2910953002/diff/100001/third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp File third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp (right): https://codereview.chromium.org/2910953002/diff/100001/third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp#newcode63 third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp:63: // ParentFrameTaskRunners does ...
3 years, 6 months ago (2017-05-30 02:32:59 UTC) #25
nhiroki
Thank you! Updated. https://codereview.chromium.org/2910953002/diff/100001/third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp File third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp (right): https://codereview.chromium.org/2910953002/diff/100001/third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp#newcode63 third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp:63: // ParentFrameTaskRunners does this. On 2017/05/30 ...
3 years, 6 months ago (2017-05-30 04:03:40 UTC) #29
kinuko
lgtm https://codereview.chromium.org/2910953002/diff/140001/third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp File third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp (right): https://codereview.chromium.org/2910953002/diff/140001/third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp#newcode62 third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp:62: // does this. Now the last part of ...
3 years, 6 months ago (2017-05-30 04:38:53 UTC) #32
nhiroki
Thank you. https://codereview.chromium.org/2910953002/diff/140001/third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp File third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp (right): https://codereview.chromium.org/2910953002/diff/140001/third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp#newcode62 third_party/WebKit/Source/core/workers/MainThreadWorklet.cpp:62: // does this. On 2017/05/30 04:38:52, kinuko ...
3 years, 6 months ago (2017-05-30 05:25:31 UTC) #34
nhiroki
+haraken@, can you review modules/csspaint? Thanks
3 years, 6 months ago (2017-05-30 05:27:12 UTC) #37
haraken
LGTM https://codereview.chromium.org/2910953002/diff/160001/third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h File third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h (right): https://codereview.chromium.org/2910953002/diff/160001/third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h#newcode33 third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h:33: CrossThreadPersistent<WorkletPendingTasks> pending_tasks_; Why do we need to change ...
3 years, 6 months ago (2017-05-30 05:33:43 UTC) #38
nhiroki
Thank you. https://codereview.chromium.org/2910953002/diff/160001/third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h File third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h (right): https://codereview.chromium.org/2910953002/diff/160001/third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h#newcode33 third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h:33: CrossThreadPersistent<WorkletPendingTasks> pending_tasks_; On 2017/05/30 05:33:43, haraken wrote: ...
3 years, 6 months ago (2017-05-30 05:59:00 UTC) #39
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/2910953002/160001
3 years, 6 months ago (2017-05-30 06:01:54 UTC) #43
haraken
On 2017/05/30 05:59:00, nhiroki (slow) wrote: > Thank you. > > https://codereview.chromium.org/2910953002/diff/160001/third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h > File third_party/WebKit/Source/core/workers/WorkletModuleTreeClient.h ...
3 years, 6 months ago (2017-05-30 06:02:02 UTC) #44
commit-bot: I haz the power
3 years, 6 months ago (2017-05-30 07:53:23 UTC) #47
Message was sent while issue was closed.
Committed patchset #7 (id:160001) as
https://chromium.googlesource.com/chromium/src/+/315dddc6bbfe2ca11f6d3b127f02...

Powered by Google App Engine
This is Rietveld 408576698