Chromium Code Reviews
Description[Reland] DevTools: Make WorkerThreadDebugger available for Worklets
Original CL: https://codereview.chromium.org/2456733002/
The original CL was reverted because there was a memory leak. This leak was
fixed by https://codereview.chromium.org/2482393002/
In addition to that, this reland CL changes layout tests added by the original
CL because they depended on leaked Document context. After the leak is fixed,
the context can be destroyed earlier than console messages from Worklets are
printed. New layout tests wait until console messages are printed.
<Original Description>
DevTools is now disabled on Worklets because worker's debugger infrastructure(*)
cannot host multiple worklet execution contexts on a single thread.
(*) Worklet has been implemented on the worker infrastructure.
To support it, this CL does following things:
- This expands 1:1 relationship between WorkerThreadDebugger and WorkerThread to
1:M relationship. The debugger has a ID-WorkerThread map to manage multiple
WorkerThreads. WorkerThread is added when worklet context is created and
removed when the context is destroyed.
- This decouples lifetime of WorkerThreadDebugger from lifetime of worklet
context. Before this CL, the debugger has the same lifetime of the context.
This prevents the debugger from hosting multiple contexts. After this CL,
the debugger has the same lifetime of WorkerBackingThread, and attaches to
worklet context when it's created.
DesignDoc: https://docs.google.com/document/d/1v0dNB6jWMe7w6OeK-Vlnn-Q4qW7KI4m97LGnMefUx1k/edit
BUG=646559
Committed: https://crrev.com/0bdb1f395432064cc19799facf055317a12ec6ce
Cr-Commit-Position: refs/heads/master@{#431198}
Patch Set 1 : Original CL #Patch Set 2 : Change layout tests #Messages
Total messages: 26 (16 generated)
|