Worker: Make ThreadedMessagingProxyBase and WorkletGlobalScopeProxy GC-managed objects

Desktop / Chromium - Hiroki Nakagawa [chromium.org] - 15 June 2017 00:29 EDT

Primary motivation of this change is to make WorkletGlobalScopeProxy GC-managed so that GC-graphs are unified, and to simplify proxy lifetime management for merging ThreadedWorklet into Worklet.

To achieve this, we also need to make ThreadedMessagingProxyBase GC-managed because a proxy for worklets implements both the interfaces and is differently handled depending on an accessor class: a class shared among workers/worklets handles the proxy as ThreadedMessagingProxyBase and a worklet-specific class handles it as WorkletGlobalScopeProxy.



ThreadedMessagingProxyBase <- InProcessWorkerMessagingProxy <- DedicatedWorkerMessagingProxy <- CompositorWorkerMessagingProxy <- ThreadedWorkletMessagingProxy <- ThreadedWorkletMessagingProxy (also implements WorkletGlobalScopeProxy) <- AnimationWorkletMessagingProxy <- AudioWorkletMessagingProxy

Bug: 719775, 727194 Change-Id: I7f63bfc4f69009b57f08599241ea3c8801e65a77 Reviewed-on: https://chromium-review.googlesource.com/527716 Commit-Queue: Hiroki Nakagawa

19663e1 Worker: Make ThreadedMessagingProxyBase and WorkletGlobalScopeProxy GC-managed objects
.../core/workers/DedicatedWorkerMessagingProxy.h | 1 -
.../Source/core/workers/DedicatedWorkerTest.cpp | 23 +++++++-----
.../Source/core/workers/InProcessWorkerBase.cpp | 1 +
.../Source/core/workers/InProcessWorkerBase.h | 7 ++--
.../core/workers/InProcessWorkerMessagingProxy.cpp | 27 +++++---------
.../core/workers/InProcessWorkerMessagingProxy.h | 16 ++++++---
.../core/workers/InProcessWorkerObjectProxy.cpp | 6 ++--
.../core/workers/InProcessWorkerObjectProxy.h | 10 +++---
.../core/workers/ThreadedMessagingProxyBase.cpp | 41 +++++++++++-----------
.../core/workers/ThreadedMessagingProxyBase.h | 38 ++++++++++++++------
.../Source/core/workers/ThreadedObjectProxyBase.h | 3 +-
.../WebKit/Source/core/workers/ThreadedWorklet.cpp | 2 +-
.../WebKit/Source/core/workers/ThreadedWorklet.h | 2 +-
.../core/workers/ThreadedWorkletMessagingProxy.cpp | 19 ++++++----
.../core/workers/ThreadedWorkletMessagingProxy.h | 9 ++---
.../core/workers/ThreadedWorkletObjectProxy.cpp | 6 ++--
.../core/workers/ThreadedWorkletObjectProxy.h | 10 +++---
.../Source/core/workers/ThreadedWorkletTest.cpp | 20 ++++++-----
third_party/WebKit/Source/core/workers/Worklet.cpp | 3 +-
third_party/WebKit/Source/core/workers/Worklet.h | 6 ++--
.../Source/core/workers/WorkletGlobalScopeProxy.h | 5 +--
.../modules/compositorworker/AnimationWorklet.cpp | 1 +
.../modules/compositorworker/AnimationWorklet.h | 7 ++--
.../AnimationWorkletMessagingProxy.cpp | 4 +++
.../AnimationWorkletMessagingProxy.h | 5 ++-
.../CompositorWorkerMessagingProxy.h | 3 --
.../Source/modules/csspaint/PaintWorklet.cpp | 4 +--
.../WebKit/Source/modules/csspaint/PaintWorklet.h | 2 +-
.../csspaint/PaintWorkletGlobalScopeProxy.cpp | 4 +++
.../csspaint/PaintWorkletGlobalScopeProxy.h | 9 +++--
.../Source/modules/csspaint/PaintWorkletTest.cpp | 6 ++--
.../Source/modules/webaudio/AudioWorklet.cpp | 1 +
.../WebKit/Source/modules/webaudio/AudioWorklet.h | 7 ++--
.../modules/webaudio/AudioWorkletMessagingProxy.h | 3 --
34 files changed, 179 insertions(+), 132 deletions(-)

Upstream: git.chromium.org


  • Share