Rename PCompositor to PCompositorBridge. (bug 1258479 part 2, r=mattwoodrow)
authorDavid Anderson <danderson@mozilla.com>
Tue, 22 Mar 2016 14:08:38 -0400
changeset 289831 4f1482e6da917442cfd73f8994ebac3c58f8fe5c
parent 289830 92ece637da91a904708bbd3165950fb47e235f1e
child 289832 16e429ad56969b36f7b7af0c2f1076771dba8652
push id74010
push userdanderson@mozilla.com
push dateTue, 22 Mar 2016 21:12:29 +0000
treeherdermozilla-inbound@4f1482e6da91 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmattwoodrow
bugs1258479
milestone48.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Rename PCompositor to PCompositorBridge. (bug 1258479 part 2, r=mattwoodrow)
dom/base/nsDOMWindowUtils.cpp
dom/base/nsFrameLoader.cpp
dom/ipc/ContentChild.cpp
dom/ipc/ContentParent.cpp
dom/ipc/TabChild.cpp
dom/ipc/TabParent.cpp
dom/media/systemservices/MediaSystemResourceService.cpp
gfx/doc/Silk.md
gfx/layers/Compositor.cpp
gfx/layers/Compositor.h
gfx/layers/LayerScope.cpp
gfx/layers/apz/src/APZCTreeManager.cpp
gfx/layers/apz/src/APZCTreeManager.h
gfx/layers/apz/src/AsyncPanZoomController.cpp
gfx/layers/apz/src/AsyncPanZoomController.h
gfx/layers/apz/test/gtest/APZTestCommon.h
gfx/layers/apz/util/ChromeProcessController.cpp
gfx/layers/client/CanvasClient.cpp
gfx/layers/client/ClientLayerManager.cpp
gfx/layers/client/ClientLayerManager.h
gfx/layers/client/ClientTiledPaintedLayer.cpp
gfx/layers/client/ContentClient.cpp
gfx/layers/client/TextureClient.cpp
gfx/layers/client/TiledContentClient.cpp
gfx/layers/composite/AsyncCompositionManager.cpp
gfx/layers/composite/AsyncCompositionManager.h
gfx/layers/composite/LayerManagerComposite.h
gfx/layers/d3d9/CompositorD3D9.cpp
gfx/layers/d3d9/CompositorD3D9.h
gfx/layers/ipc/CompositableTransactionParent.cpp
gfx/layers/ipc/CompositorBridgeChild.cpp
gfx/layers/ipc/CompositorBridgeChild.h
gfx/layers/ipc/CompositorBridgeParent.cpp
gfx/layers/ipc/CompositorBridgeParent.h
gfx/layers/ipc/CompositorChild.cpp
gfx/layers/ipc/CompositorChild.h
gfx/layers/ipc/CompositorLRU.cpp
gfx/layers/ipc/CompositorParent.cpp
gfx/layers/ipc/CompositorParent.h
gfx/layers/ipc/ImageBridgeChild.cpp
gfx/layers/ipc/ImageBridgeParent.cpp
gfx/layers/ipc/ImageBridgeParent.h
gfx/layers/ipc/LayerTransactionChild.cpp
gfx/layers/ipc/LayerTransactionChild.h
gfx/layers/ipc/LayerTransactionParent.cpp
gfx/layers/ipc/LayerTransactionParent.h
gfx/layers/ipc/RemoteContentController.cpp
gfx/layers/moz.build
gfx/tests/gtest/TestLayers.cpp
gfx/thebes/gfxAndroidPlatform.cpp
gfx/thebes/gfxPlatform.cpp
gfx/thebes/gfxPlatformMac.cpp
gfx/thebes/gfxWindowsPlatform.cpp
gfx/vr/ipc/VRManagerChild.cpp
gfx/vr/ipc/VRManagerChild.h
gfx/vr/ipc/VRManagerParent.cpp
gfx/vr/ipc/VRManagerParent.h
layout/base/nsPresShell.cpp
layout/ipc/RenderFrameParent.cpp
testing/mozbase/mozleak/mozleak/leaklog.py
widget/VsyncDispatcher.cpp
widget/android/AndroidBridge.cpp
widget/android/nsWindow.cpp
widget/android/nsWindow.h
widget/cocoa/nsChildView.mm
widget/gonk/GeckoTouchDispatcher.cpp
widget/gonk/HwcComposer2D.cpp
widget/gonk/HwcComposer2D.h
widget/gonk/nativewindow/FakeSurfaceComposer.cpp
widget/gonk/nsAppShell.cpp
widget/gonk/nsScreenManagerGonk.cpp
widget/gonk/nsScreenManagerGonk.h
widget/gonk/nsWindow.cpp
widget/gonk/nsWindow.h
widget/gtk/nsWindow.cpp
widget/nsBaseWidget.cpp
widget/nsBaseWidget.h
widget/nsIWidget.h
widget/windows/nsWindow.cpp
widget/windows/nsWindowGfx.cpp
xpcom/build/XPCOMInit.cpp
--- a/dom/base/nsDOMWindowUtils.cpp
+++ b/dom/base/nsDOMWindowUtils.cpp
@@ -1,17 +1,17 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "nsDOMWindowUtils.h"
 
-#include "mozilla/layers/CompositorChild.h"
+#include "mozilla/layers/CompositorBridgeChild.h"
 #include "mozilla/layers/LayerTransactionChild.h"
 #include "nsPresContext.h"
 #include "nsDOMClassInfoID.h"
 #include "nsError.h"
 #include "nsIDOMEvent.h"
 #include "nsQueryContentEventResult.h"
 #include "nsGlobalWindow.h"
 #include "nsIDocument.h"
--- a/dom/base/nsFrameLoader.cpp
+++ b/dom/base/nsFrameLoader.cpp
@@ -87,17 +87,17 @@
 #include "mozilla/jsipc/CrossProcessObjectWrappers.h"
 #include "mozilla/layout/RenderFrameParent.h"
 #include "nsIAppsService.h"
 #include "GeckoProfiler.h"
 
 #include "jsapi.h"
 #include "mozilla/dom/HTMLIFrameElement.h"
 #include "nsSandboxFlags.h"
-#include "mozilla/layers/CompositorChild.h"
+#include "mozilla/layers/CompositorBridgeChild.h"
 
 #include "mozilla/dom/ipc/StructuredCloneData.h"
 #include "mozilla/WebBrowserPersistLocalDocument.h"
 
 #include "nsPrincipal.h"
 
 #ifdef MOZ_XUL
 #include "nsXULPopupManager.h"
@@ -1732,17 +1732,17 @@ nsFrameLoader::ShouldUseRemoteProcess()
   if (PR_GetEnv("MOZ_DISABLE_OOP_TABS") ||
       Preferences::GetBool("dom.ipc.tabs.disabled", false)) {
     return false;
   }
 
   // Don't try to launch nested children if we don't have OMTC.
   // They won't render!
   if (XRE_IsContentProcess() &&
-      !CompositorChild::ChildProcessHasCompositor()) {
+      !CompositorBridgeChild::ChildProcessHasCompositor()) {
     return false;
   }
 
   if (XRE_IsContentProcess() &&
       !(PR_GetEnv("MOZ_NESTED_OOP_TABS") ||
         Preferences::GetBool("dom.ipc.tabs.nested.enabled", false))) {
     return false;
   }
--- a/dom/ipc/ContentChild.cpp
+++ b/dom/ipc/ContentChild.cpp
@@ -40,19 +40,18 @@
 #include "mozilla/hal_sandbox/PHalChild.h"
 #include "mozilla/ipc/BackgroundChild.h"
 #include "mozilla/ipc/FileDescriptorSetChild.h"
 #include "mozilla/ipc/FileDescriptorUtils.h"
 #include "mozilla/ipc/GeckoChildProcessHost.h"
 #include "mozilla/ipc/TestShellChild.h"
 #include "mozilla/jsipc/CrossProcessObjectWrappers.h"
 #include "mozilla/layers/APZChild.h"
-#include "mozilla/layers/CompositorChild.h"
+#include "mozilla/layers/CompositorBridgeChild.h"
 #include "mozilla/layers/ImageBridgeChild.h"
-#include "mozilla/layers/PCompositorBridgeChild.h"
 #include "mozilla/layers/SharedBufferManagerChild.h"
 #include "mozilla/layout/RenderFrameChild.h"
 #include "mozilla/net/NeckoChild.h"
 #include "mozilla/plugins/PluginInstanceParent.h"
 #include "mozilla/plugins/PluginModuleParent.h"
 #include "mozilla/widget/WidgetMessageUtils.h"
 #include "mozilla/media/MediaChild.h"
 #include "mozilla/BasePrincipal.h"
@@ -1283,17 +1282,17 @@ ContentChild::DeallocPAPZChild(PAPZChild
   delete aActor;
   return true;
 }
 
 PCompositorBridgeChild*
 ContentChild::AllocPCompositorBridgeChild(mozilla::ipc::Transport* aTransport,
                                           base::ProcessId aOtherProcess)
 {
-  return CompositorChild::Create(aTransport, aOtherProcess);
+  return CompositorBridgeChild::Create(aTransport, aOtherProcess);
 }
 
 PSharedBufferManagerChild*
 ContentChild::AllocPSharedBufferManagerChild(mozilla::ipc::Transport* aTransport,
                                               base::ProcessId aOtherProcess)
 {
   return SharedBufferManagerChild::StartUpInChildProcess(aTransport, aOtherProcess);
 }
--- a/dom/ipc/ContentParent.cpp
+++ b/dom/ipc/ContentParent.cpp
@@ -80,17 +80,17 @@
 #include "mozilla/ipc/BackgroundParent.h"
 #include "mozilla/ipc/FileDescriptorSetParent.h"
 #include "mozilla/ipc/FileDescriptorUtils.h"
 #include "mozilla/ipc/PFileDescriptorSetParent.h"
 #include "mozilla/ipc/TestShellParent.h"
 #include "mozilla/ipc/InputStreamUtils.h"
 #include "mozilla/jsipc/CrossProcessObjectWrappers.h"
 #include "mozilla/layers/PAPZParent.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/layers/ImageBridgeParent.h"
 #include "mozilla/layers/SharedBufferManagerParent.h"
 #include "mozilla/LookAndFeel.h"
 #include "mozilla/media/MediaParent.h"
 #include "mozilla/Move.h"
 #include "mozilla/net/NeckoParent.h"
 #include "mozilla/plugins/PluginBridge.h"
 #include "mozilla/Preferences.h"
@@ -1916,27 +1916,27 @@ ContentParent::AllocateLayerTreeId(TabPa
 }
 
 /* static */
 bool
 ContentParent::AllocateLayerTreeId(ContentParent* aContent,
                                    TabParent* aTopLevel, const TabId& aTabId,
                                    uint64_t* aId)
 {
-  *aId = CompositorParent::AllocateLayerTreeId();
+  *aId = CompositorBridgeParent::AllocateLayerTreeId();
 
   if (!gfxPlatform::AsyncPanZoomEnabled()) {
     return true;
   }
 
   if (!aContent || !aTopLevel) {
     return false;
   }
 
-  return CompositorParent::UpdateRemoteContentController(*aId, aContent,
+  return CompositorBridgeParent::UpdateRemoteContentController(*aId, aContent,
                                                          aTabId, aTopLevel);
 }
 
 bool
 ContentParent::RecvAllocateLayerTreeId(const ContentParentId& aCpId,
                                        const TabId& aTabId, uint64_t* aId)
 {
   // Protect against spoofing by a compromised child. aCpId must either
@@ -1974,17 +1974,17 @@ ContentParent::RecvAllocateLayerTreeId(c
 }
 
 bool
 ContentParent::RecvDeallocateLayerTreeId(const uint64_t& aId)
 {
   auto iter = NestedBrowserLayerIds().find(this);
   if (iter != NestedBrowserLayerIds().end() &&
     iter->second.find(aId) != iter->second.end()) {
-    CompositorParent::DeallocateLayerTreeId(aId);
+    CompositorBridgeParent::DeallocateLayerTreeId(aId);
   } else {
     // You can't deallocate layer tree ids that you didn't allocate
     KillHard("DeallocateLayerTreeId");
   }
   return true;
 }
 
 namespace {
@@ -2538,24 +2538,24 @@ ContentParent::InitInternal(ProcessPrior
   // from this process.
   //
   // This call can cause us to send IPC messages to the child process, so it
   // must come after the Open() call above.
   ProcessPriorityManager::SetProcessPriority(this, aInitialPriority);
 
   if (aSetupOffMainThreadCompositing) {
     // NB: internally, this will send an IPC message to the child
-    // process to get it to create the CompositorChild.  This
+    // process to get it to create the CompositorBridgeChild.  This
     // message goes through the regular IPC queue for this
     // channel, so delivery will happen-before any other messages
-    // we send.  The CompositorChild must be created before any
+    // we send.  The CompositorBridgeChild must be created before any
     // PBrowsers are created, because they rely on the Compositor
     // already being around.  (Creation is async, so can't happen
     // on demand.)
-    bool useOffMainThreadCompositing = !!CompositorParent::CompositorLoop();
+    bool useOffMainThreadCompositing = !!CompositorBridgeParent::CompositorLoop();
     if (useOffMainThreadCompositing) {
       DebugOnly<bool> opened = PCompositorBridge::Open(this);
       MOZ_ASSERT(opened);
 
       opened = PImageBridge::Open(this);
       MOZ_ASSERT(opened);
 
       opened = gfx::PVRManager::Open(this);
@@ -3332,17 +3332,17 @@ ContentParent::DeallocPAPZParent(PAPZPar
 {
   return true;
 }
 
 PCompositorBridgeParent*
 ContentParent::AllocPCompositorBridgeParent(mozilla::ipc::Transport* aTransport,
                                             base::ProcessId aOtherProcess)
 {
-  return CompositorParent::Create(aTransport, aOtherProcess);
+  return CompositorBridgeParent::Create(aTransport, aOtherProcess);
 }
 
 gfx::PVRManagerParent*
 ContentParent::AllocPVRManagerParent(Transport* aTransport,
                                      ProcessId aOtherProcess)
 {
   return gfx::VRManagerParent::CreateCrossProcess(aTransport, aOtherProcess);
 }
--- a/dom/ipc/TabChild.cpp
+++ b/dom/ipc/TabChild.cpp
@@ -28,17 +28,17 @@
 #ifdef MOZ_NUWA_PROCESS
 #include "ipc/Nuwa.h"
 #endif
 #include "mozilla/ipc/FileDescriptorUtils.h"
 #include "mozilla/layers/APZChild.h"
 #include "mozilla/layers/APZCCallbackHelper.h"
 #include "mozilla/layers/APZCTreeManager.h"
 #include "mozilla/layers/APZEventState.h"
-#include "mozilla/layers/CompositorChild.h"
+#include "mozilla/layers/CompositorBridgeChild.h"
 #include "mozilla/layers/DoubleTapToZoom.h"
 #include "mozilla/layers/ImageBridgeChild.h"
 #include "mozilla/layers/InputAPZContext.h"
 #include "mozilla/layers/ShadowLayers.h"
 #include "mozilla/layout/RenderFrameChild.h"
 #include "mozilla/layout/RenderFrameParent.h"
 #include "mozilla/LookAndFeel.h"
 #include "mozilla/MouseEvents.h"
@@ -1209,17 +1209,17 @@ TabChild::ActorDestroy(ActorDestroyReaso
   if (mTabChildGlobal) {
     // The messageManager relays messages via the TabChild which
     // no longer exists.
     static_cast<nsFrameMessageManager*>
       (mTabChildGlobal->mMessageManager.get())->Disconnect();
     mTabChildGlobal->mMessageManager = nullptr;
   }
 
-  CompositorChild* compositorChild = static_cast<CompositorChild*>(CompositorChild::Get());
+  CompositorBridgeChild* compositorChild = static_cast<CompositorBridgeChild*>(CompositorBridgeChild::Get());
   compositorChild->CancelNotifyAfterRemotePaint(this);
 
   if (GetTabId() != 0) {
     NestedTabChildMap().erase(GetTabId());
   }
 }
 
 TabChild::~TabChild()
@@ -2532,19 +2532,19 @@ TabChild::InitRenderingState(const Textu
         return false;
     }
 
     MOZ_ASSERT(aLayersId != 0);
     mTextureFactoryIdentifier = aTextureFactoryIdentifier;
 
     // Pushing layers transactions directly to a separate
     // compositor context.
-    PCompositorBridgeChild* compositorChild = CompositorChild::Get();
+    PCompositorBridgeChild* compositorChild = CompositorBridgeChild::Get();
     if (!compositorChild) {
-      NS_WARNING("failed to get CompositorChild instance");
+      NS_WARNING("failed to get CompositorBridgeChild instance");
       PRenderFrameChild::Send__delete__(remoteFrame);
       return false;
     }
     nsTArray<LayersBackend> backends;
     backends.AppendElement(mTextureFactoryIdentifier.mParentBackend);
     bool success;
     PLayerTransactionChild* shadowManager =
         compositorChild->SendPLayerTransactionConstructor(backends,
@@ -2640,35 +2640,35 @@ TabChild::NotifyPainted()
         mRemoteFrame->SendNotifyCompositorTransaction();
         mNotified = true;
     }
 }
 
 void
 TabChild::MakeVisible()
 {
-  CompositorChild* compositor = CompositorChild::Get();
+  CompositorBridgeChild* compositor = CompositorBridgeChild::Get();
   if (UsingCompositorLRU()) {
     compositor->SendNotifyVisible(mLayersId);
   }
 
   if (mPuppetWidget) {
     mPuppetWidget->Show(true);
   }
 }
 
 void
 TabChild::MakeHidden()
 {
-  CompositorChild* compositor = CompositorChild::Get();
+  CompositorBridgeChild* compositor = CompositorBridgeChild::Get();
   if (UsingCompositorLRU()) {
     compositor->SendNotifyHidden(mLayersId);
   } else {
     // Clear cached resources directly. This avoids one extra IPC
-    // round-trip from CompositorChild to CompositorParent when
+    // round-trip from CompositorBridgeChild to CompositorBridgeParent when
     // CompositorLRU is not used.
     compositor->RecvClearCachedResources(mLayersId);
   }
 
   if (mPuppetWidget) {
     mPuppetWidget->Show(false);
   }
 }
@@ -2892,20 +2892,20 @@ TabChild::OnHideTooltip()
 {
     SendHideTooltip();
     return NS_OK;
 }
 
 bool
 TabChild::RecvRequestNotifyAfterRemotePaint()
 {
-  // Get the CompositorChild instance for this content thread.
-  CompositorChild* compositor = CompositorChild::Get();
-
-  // Tell the CompositorChild that, when it gets a RemotePaintIsReady
+  // Get the CompositorBridgeChild instance for this content thread.
+  CompositorBridgeChild* compositor = CompositorBridgeChild::Get();
+
+  // Tell the CompositorBridgeChild that, when it gets a RemotePaintIsReady
   // message that it should forward it us so that we can bounce it to our
   // RenderFrameParent.
   compositor->RequestNotifyAfterRemotePaint(this);
   return true;
 }
 
 bool
 TabChild::RecvUIResolutionChanged(const float& aDpi, const double& aScale)
--- a/dom/ipc/TabParent.cpp
+++ b/dom/ipc/TabParent.cpp
@@ -24,17 +24,17 @@
 #include "mozilla/plugins/PluginWidgetParent.h"
 #include "mozilla/EventStateManager.h"
 #include "mozilla/gfx/2D.h"
 #include "mozilla/Hal.h"
 #include "mozilla/IMEStateManager.h"
 #include "mozilla/ipc/DocumentRendererParent.h"
 #include "mozilla/jsipc/CrossProcessObjectWrappers.h"
 #include "mozilla/layers/AsyncDragMetrics.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/layers/InputAPZContext.h"
 #include "mozilla/layout/RenderFrameParent.h"
 #include "mozilla/LookAndFeel.h"
 #include "mozilla/MouseEvents.h"
 #include "mozilla/net/NeckoChild.h"
 #include "mozilla/Preferences.h"
 #include "mozilla/TextEvents.h"
 #include "mozilla/TouchEvents.h"
@@ -2910,32 +2910,34 @@ class LayerTreeUpdateObserver : public C
 
 bool
 TabParent::RequestNotifyLayerTreeReady()
 {
   RenderFrameParent* frame = GetRenderFrame();
   if (!frame) {
     mNeedLayerTreeReadyNotification = true;
   } else {
-    CompositorParent::RequestNotifyLayerTreeReady(frame->GetLayersId(),
-                                                  new LayerTreeUpdateObserver());
+    CompositorBridgeParent::RequestNotifyLayerTreeReady(
+      frame->GetLayersId(),
+      new LayerTreeUpdateObserver());
   }
   return true;
 }
 
 bool
 TabParent::RequestNotifyLayerTreeCleared()
 {
   RenderFrameParent* frame = GetRenderFrame();
   if (!frame) {
     return false;
   }
 
-  CompositorParent::RequestNotifyLayerTreeCleared(frame->GetLayersId(),
-                                                  new LayerTreeUpdateObserver());
+  CompositorBridgeParent::RequestNotifyLayerTreeCleared(
+    frame->GetLayersId(),
+    new LayerTreeUpdateObserver());
   return true;
 }
 
 bool
 TabParent::LayerTreeUpdate(bool aActive)
 {
   nsCOMPtr<mozilla::dom::EventTarget> target = do_QueryInterface(mFrameElement);
   if (!target) {
@@ -2960,22 +2962,23 @@ void
 TabParent::SwapLayerTreeObservers(TabParent* aOther)
 {
   if (IsDestroyed() || aOther->IsDestroyed()) {
     return;
   }
 
   RenderFrameParent* rfp = GetRenderFrame();
   RenderFrameParent* otherRfp = aOther->GetRenderFrame();
-  if(!rfp || !otherRfp) {
+  if (!rfp || !otherRfp) {
     return;
   }
 
-  CompositorParent::SwapLayerTreeObservers(rfp->GetLayersId(),
-                                           otherRfp->GetLayersId());
+  CompositorBridgeParent::SwapLayerTreeObservers(
+    rfp->GetLayersId(),
+    otherRfp->GetLayersId());
 }
 
 bool
 TabParent::RecvRemotePaintIsReady()
 {
   nsCOMPtr<mozilla::dom::EventTarget> target = do_QueryInterface(mFrameElement);
   if (!target) {
     NS_WARNING("Could not locate target for MozAfterRemotePaint message.");
--- a/dom/media/systemservices/MediaSystemResourceService.cpp
+++ b/dom/media/systemservices/MediaSystemResourceService.cpp
@@ -1,16 +1,16 @@
 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim:set ts=2 sw=2 sts=2 et cindent: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this file,
  * You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "MediaSystemResourceManagerParent.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/unused.h"
 
 #include "MediaSystemResourceService.h"
 
 using namespace mozilla::layers;
 
 namespace mozilla {
 
@@ -41,17 +41,17 @@ MediaSystemResourceService::Shutdown()
     sSingleton->Destroy();
     sSingleton = nullptr;
   }
 }
 
 MediaSystemResourceService::MediaSystemResourceService()
   : mDestroyed(false)
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
 #ifdef MOZ_WIDGET_GONK
   // The maximum number of hardware resoureces available.
   // XXX need to hange to a dynamic way.
   enum
   {
     VIDEO_DECODER_COUNT = 1,
     VIDEO_ENCODER_COUNT = 1
   };
@@ -77,17 +77,17 @@ MediaSystemResourceService::Destroy()
 }
 
 void
 MediaSystemResourceService::Acquire(media::MediaSystemResourceManagerParent* aParent,
                                     uint32_t aId,
                                     MediaSystemResourceType aResourceType,
                                     bool aWillWait)
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   MOZ_ASSERT(aParent);
 
   if (mDestroyed) {
     return;
   }
 
   MediaSystemResource* resource = mResources.Get(static_cast<uint32_t>(aResourceType));
 
@@ -118,17 +118,17 @@ MediaSystemResourceService::Acquire(medi
     MediaSystemResourceRequest(aParent, aId));
 }
 
 void
 MediaSystemResourceService::ReleaseResource(media::MediaSystemResourceManagerParent* aParent,
                                             uint32_t aId,
                                             MediaSystemResourceType aResourceType)
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   MOZ_ASSERT(aParent);
 
   if (mDestroyed) {
     return;
   }
 
   MediaSystemResource* resource = mResources.Get(static_cast<uint32_t>(aResourceType));
 
--- a/gfx/doc/Silk.md
+++ b/gfx/doc/Silk.md
@@ -49,28 +49,28 @@ There is only one **VsyncSource** object
 Each platform is expected to implement their own **VsyncSource** to manage vsync events.
 On Firefox OS, this is through the **HwcComposer2D**.
 On OS X, this is through **CVDisplayLinkRef**.
 On Windows, it should be through **DwmGetCompositionTimingInfo**.
 
 #Compositor
 When the **CompositorVsyncDispatcher** is notified of the vsync event, the **CompositorVsyncObserver** associated with the **CompositorVsyncDispatcher** begins execution.
 Since the **CompositorVsyncDispatcher** executes on the *Hardware Vsync Thread* and the **Compositor** composites on the *CompositorThread*, the **CompositorVsyncObserver** posts a task to the *CompositorThread*.
-The **CompositorParent** then composites.
+The **CompositorBridgeParent** then composites.
 The model where the **CompositorVsyncDispatcher** notifies components on the *Hardware Vsync Thread*, and the component schedules the task on the appropriate thread is used everywhere.
 
 The **CompositorVsyncObserver** listens to vsync events as needed and stops listening to vsync when composites are no longer scheduled or required.
-Every **CompositorParent** is associated and tied to one **CompositorVsyncObserver**, which is associated with the **CompositorVsyncDispatcher**.
-Each **CompositorParent** is associated with one widget and is created when a new platform window or **nsBaseWidget** is created.
-The **CompositorParent**, **CompositorVsyncDispatcher**, **CompositorVsyncObserver**, and **nsBaseWidget** all have the same lifetimes, which are created and destroyed together.
+Every **CompositorBridgeParent** is associated and tied to one **CompositorVsyncObserver**, which is associated with the **CompositorVsyncDispatcher**.
+Each **CompositorBridgeParent** is associated with one widget and is created when a new platform window or **nsBaseWidget** is created.
+The **CompositorBridgeParent**, **CompositorVsyncDispatcher**, **CompositorVsyncObserver**, and **nsBaseWidget** all have the same lifetimes, which are created and destroyed together.
 
 ###CompositorVsyncDispatcher
 The **CompositorVsyncDispatcher** executes on the *Hardware Vsync Thread*.
 It contains references to the **nsBaseWidget** it is associated with and has a lifetime equal to the **nsBaseWidget**.
-The **CompositorVsyncDispatcher** is responsible for notifying the **CompositorParent** that a vsync event has occured.
+The **CompositorVsyncDispatcher** is responsible for notifying the **CompositorBridgeParent** that a vsync event has occured.
 There can be multiple **CompositorVsyncDispatchers** per **Display**, one **CompositorVsyncDispatcher** per window.
 The only responsibility of the **CompositorVsyncDispatcher** is to notify components when a vsync event has occured, and to stop listening to vsync when no components require vsync events.
 We require one **CompositorVsyncDispatcher** per window so that we can handle multiple **Displays**.
 
 ###Multiple Displays
 The **VsyncSource** has an API to switch a **CompositorVsyncDispatcher** from one **Display** to another **Display**.
 For example, when one window either goes into full screen mode or moves from one connected monitor to another.
 When one window moves to another monitor, we expect a platform specific notification to occur.
@@ -107,39 +107,39 @@ As of this writing, we have not analyzed
 
 One slight quirk is that input events can start a composite, for example during a scroll and after the **Compositor** is no longer listening to vsync events.
 In these cases, we notify the **Compositor** to observe vsync so that it dispatches touch events.
 If touch events were not dispatched, and since the **Compositor** is not listening to vsync events, the touch events would never be dispatched.
 The **GeckoTouchDispatcher** handles this case by always forcing the **Compositor** to listen to vsync events while touch events are occurring.
 
 ###Widget, Compositor, CompositorVsyncDispatcher, GeckoTouchDispatcher Shutdown Procedure
 When the [nsBaseWidget shuts down](http://hg.mozilla.org/mozilla-central/file/0df249a0e4d3/widget/nsBaseWidget.cpp#l182) - It calls nsBaseWidget::DestroyCompositor on the *Gecko Main Thread*.
-During nsBaseWidget::DestroyCompositor, it first destroys the CompositorChild.
-CompositorChild sends a sync IPC call to CompositorParent::RecvStop, which calls [CompositorParent::Destroy](http://hg.mozilla.org/mozilla-central/file/ab0490972e1e/gfx/layers/ipc/CompositorParent.cpp#l509).
+During nsBaseWidget::DestroyCompositor, it first destroys the CompositorBridgeChild.
+CompositorBridgeChild sends a sync IPC call to CompositorBridgeParent::RecvStop, which calls [CompositorBridgeParent::Destroy](http://hg.mozilla.org/mozilla-central/file/ab0490972e1e/gfx/layers/ipc/CompositorBridgeParent.cpp#l509).
 During this time, the *main thread* is blocked on the parent process.
-CompositorParent::RecvStop runs on the *Compositor thread* and cleans up some resources, including setting the **CompositorVsyncObserver** to nullptr.
-CompositorParent::RecvStop also explicitly keeps the CompositorParent alive and posts another task to run CompositorParent::DeferredDestroy on the Compositor loop so that all ipdl code can finish executing.
+CompositorBridgeParent::RecvStop runs on the *Compositor thread* and cleans up some resources, including setting the **CompositorVsyncObserver** to nullptr.
+CompositorBridgeParent::RecvStop also explicitly keeps the CompositorBridgeParent alive and posts another task to run CompositorBridgeParent::DeferredDestroy on the Compositor loop so that all ipdl code can finish executing.
 The **CompositorVsyncObserver** also unobserves from vsync and cancels any pending composite tasks.
-Once CompositorParent::RecvStop finishes, the *main thread* in the parent process continues shutting down the nsBaseWidget.
+Once CompositorBridgeParent::RecvStop finishes, the *main thread* in the parent process continues shutting down the nsBaseWidget.
 
-At the same time, the *Compositor thread* is executing tasks until CompositorParent::DeferredDestroy runs, which flushes the compositor message loop.
-Now we have two tasks as both the nsBaseWidget releases a reference to the Compositor on the *main thread* during destruction and the CompositorParent::DeferredDestroy releases a reference to the CompositorParent on the *Compositor Thread*.
-Finally, the CompositorParent itself is destroyed on the *main thread* once both references are gone due to explicit [main thread destruction](http://hg.mozilla.org/mozilla-central/file/50b95032152c/gfx/layers/ipc/CompositorParent.h#l148).
+At the same time, the *Compositor thread* is executing tasks until CompositorBridgeParent::DeferredDestroy runs, which flushes the compositor message loop.
+Now we have two tasks as both the nsBaseWidget releases a reference to the Compositor on the *main thread* during destruction and the CompositorBridgeParent::DeferredDestroy releases a reference to the CompositorBridgeParent on the *Compositor Thread*.
+Finally, the CompositorBridgeParent itself is destroyed on the *main thread* once both references are gone due to explicit [main thread destruction](http://hg.mozilla.org/mozilla-central/file/50b95032152c/gfx/layers/ipc/CompositorBridgeParent.h#l148).
 
 With the **CompositorVsyncObserver**, any accesses to the widget after nsBaseWidget::DestroyCompositor executes are invalid.
 Any accesses to the compositor between the time the nsBaseWidget::DestroyCompositor runs and the CompositorVsyncObserver's destructor runs aren't safe yet a hardware vsync event could occur between these times.
-Since any tasks posted on the Compositor loop after CompositorParent::DeferredDestroy is posted are invalid, we make sure that no vsync tasks can be posted once CompositorParent::RecvStop executes and DeferredDestroy is posted on the Compositor thread.
-When the sync call to CompositorParent::RecvStop executes, we explicitly set the CompositorVsyncObserver to null to prevent vsync notifications from occurring.
-If vsync notifications were allowed to occur, since the **CompositorVsyncObserver**'s vsync notification executes on the *hardware vsync thread*, it would post a task to the Compositor loop and may execute after CompositorParent::DeferredDestroy.
-Thus, we explicitly shut down vsync events in the **CompositorVsyncDispatcher** and **CompositorVsyncObserver** during nsBaseWidget::Shutdown to prevent any vsync tasks from executing after CompositorParent::DeferredDestroy.
+Since any tasks posted on the Compositor loop after CompositorBridgeParent::DeferredDestroy is posted are invalid, we make sure that no vsync tasks can be posted once CompositorBridgeParent::RecvStop executes and DeferredDestroy is posted on the Compositor thread.
+When the sync call to CompositorBridgeParent::RecvStop executes, we explicitly set the CompositorVsyncObserver to null to prevent vsync notifications from occurring.
+If vsync notifications were allowed to occur, since the **CompositorVsyncObserver**'s vsync notification executes on the *hardware vsync thread*, it would post a task to the Compositor loop and may execute after CompositorBridgeParent::DeferredDestroy.
+Thus, we explicitly shut down vsync events in the **CompositorVsyncDispatcher** and **CompositorVsyncObserver** during nsBaseWidget::Shutdown to prevent any vsync tasks from executing after CompositorBridgeParent::DeferredDestroy.
 
 The **CompositorVsyncDispatcher** may be destroyed on either the *main thread* or *Compositor Thread*, since both the nsBaseWidget and **CompositorVsyncObserver** race to destroy on different threads.
 nsBaseWidget is destroyed on the *main thread* and releases a reference to the **CompositorVsyncDispatcher** during destruction.
-The **CompositorVsyncObserver** has a race to be destroyed either during CompositorParent shutdown or from the **GeckoTouchDispatcher** which is destroyed on the main thread with [ClearOnShutdown](http://hg.mozilla.org/mozilla-central/file/21567e9a6e40/xpcom/base/ClearOnShutdown.h#l15).
-Whichever object, the CompositorParent or the **GeckoTouchDispatcher** is destroyed last will hold the last reference to the **CompositorVsyncDispatcher**, which destroys the object.
+The **CompositorVsyncObserver** has a race to be destroyed either during CompositorBridgeParent shutdown or from the **GeckoTouchDispatcher** which is destroyed on the main thread with [ClearOnShutdown](http://hg.mozilla.org/mozilla-central/file/21567e9a6e40/xpcom/base/ClearOnShutdown.h#l15).
+Whichever object, the CompositorBridgeParent or the **GeckoTouchDispatcher** is destroyed last will hold the last reference to the **CompositorVsyncDispatcher**, which destroys the object.
 
 #Refresh Driver
 The Refresh Driver is ticked from a [single active timer](http://hg.mozilla.org/mozilla-central/file/ab0490972e1e/layout/base/nsRefreshDriver.cpp#l11).
 The assumption is that there are multiple **RefreshDrivers** connected to a single **RefreshTimer**.
 There are two **RefreshTimers**: an active and an inactive **RefreshTimer**.
 Each Tab has its own **RefreshDriver**, which connects to one of the global **RefreshTimers**.
 The **RefreshTimers** execute on the *Main Thread* and tick their connected **RefreshDrivers**.
 We do not want to break this model of multiple **RefreshDrivers** per a set of two global **RefreshTimers**.
@@ -207,17 +207,17 @@ Based on which display the window is on,
 Each **TabParent** should also send a notification to their child.
 Each **TabChild**, given the display ID, switches to the correct **RefreshTimer** associated with the display ID.
 When each display vsync occurs, it sends one IPC message to notify vsync.
 The vsync message contains a display ID, to tick the appropriate **RefreshTimer** on the content process.
 There is still only one **VsyncParent/VsyncChild** pair, just each vsync notification will include a display ID, which maps to the correct **RefreshTimer**.
 
 #Object Lifetime
 1. CompositorVsyncDispatcher - Lives as long as the nsBaseWidget associated with the VsyncDispatcher
-2. CompositorVsyncObserver - Lives and dies the same time as the CompositorParent.
+2. CompositorVsyncObserver - Lives and dies the same time as the CompositorBridgeParent.
 3. RefreshTimerVsyncDispatcher - As long as the associated display object, which is the lifetime of Firefox.
 4. VsyncSource - Lives as long as the gfxPlatform on the chrome process, which is the lifetime of Firefox.
 5. VsyncParent/VsyncChild - Lives as long as the content process
 6. RefreshTimer - Lives as long as the process
 
 #Threads
 All **VsyncObservers** are notified on the *Hardware Vsync Thread*. It is the responsibility of the **VsyncObservers** to post tasks to their respective correct thread. For example, the **CompositorVsyncObserver** will be notified on the *Hardware Vsync Thread*, and post a task to the *Compositor Thread* to do the actual composition.
 
--- a/gfx/layers/Compositor.cpp
+++ b/gfx/layers/Compositor.cpp
@@ -1,16 +1,16 @@
 /* -*- Mode: C++; tab-width: 20; indent-tabs-mode: nil; c-basic-offset: 2 -*-
  * This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "mozilla/layers/Compositor.h"
 #include "base/message_loop.h"          // for MessageLoop
-#include "mozilla/layers/CompositorParent.h"  // for CompositorParent
+#include "mozilla/layers/CompositorBridgeParent.h"  // for CompositorBridgeParent
 #include "mozilla/layers/Effects.h"     // for Effect, EffectChain, etc
 #include "mozilla/mozalloc.h"           // for operator delete, etc
 #include "gfx2DGlue.h"
 #include "nsAppRunner.h"
 
 #if defined(MOZ_WIDGET_GONK) && ANDROID_VERSION >= 17
 #include "libdisplay/GonkDisplay.h"     // for GonkDisplay
 #include <ui/Fence.h>
@@ -20,18 +20,18 @@
 
 namespace mozilla {
 
 namespace layers {
 
 /* static */ void
 Compositor::AssertOnCompositorThread()
 {
-  MOZ_ASSERT(!CompositorParent::CompositorLoop() ||
-             CompositorParent::CompositorLoop() == MessageLoop::current(),
+  MOZ_ASSERT(!CompositorBridgeParent::CompositorLoop() ||
+             CompositorBridgeParent::CompositorLoop() == MessageLoop::current(),
              "Can only call this from the compositor thread!");
 }
 
 bool
 Compositor::ShouldDrawDiagnostics(DiagnosticFlags aFlags)
 {
   if ((aFlags & DiagnosticFlags::TILE) && !(mDiagnosticTypes & DiagnosticTypes::TILE_BORDERS)) {
     return false;
--- a/gfx/layers/Compositor.h
+++ b/gfx/layers/Compositor.h
@@ -121,17 +121,17 @@ namespace layers {
 struct Effect;
 struct EffectChain;
 class Image;
 class ImageHostOverlay;
 class Layer;
 class TextureSource;
 class DataTextureSource;
 class CompositingRenderTarget;
-class CompositorParent;
+class CompositorBridgeParent;
 class LayerManagerComposite;
 
 enum SurfaceInitMode
 {
   INIT_MODE_NONE,
   INIT_MODE_CLEAR
 };
 
@@ -180,17 +180,17 @@ enum SurfaceInitMode
 class Compositor
 {
 protected:
   virtual ~Compositor() {}
 
 public:
   NS_INLINE_DECL_REFCOUNTING(Compositor)
 
-  explicit Compositor(CompositorParent* aParent = nullptr)
+  explicit Compositor(CompositorBridgeParent* aParent = nullptr)
     : mCompositorID(0)
     , mDiagnosticTypes(DiagnosticTypes::NO_DIAGNOSTIC)
     , mParent(aParent)
     , mScreenRotation(ROTATION_0)
   {
   }
 
   virtual already_AddRefed<DataTextureSource> CreateDataTextureSource(TextureFlags aFlags = TextureFlags::NO_FLAGS) = 0;
@@ -549,17 +549,17 @@ protected:
    * When nonnull, during rendering, some compositable indicated that it will
    * change its rendering at this time. In order not to miss it, we composite
    * on every vsync until this time occurs (this is the latest such time).
    */
   TimeStamp mCompositeUntilTime;
 
   uint32_t mCompositorID;
   DiagnosticTypes mDiagnosticTypes;
-  CompositorParent* mParent;
+  CompositorBridgeParent* mParent;
 
   /**
    * We keep track of the total number of pixels filled as we composite the
    * current frame. This value is an approximation and is not accurate,
    * especially in the presence of transforms.
    */
   size_t mPixelsPerFrame;
   size_t mPixelsFilled;
--- a/gfx/layers/LayerScope.cpp
+++ b/gfx/layers/LayerScope.cpp
@@ -12,17 +12,17 @@
 #include "Effects.h"
 #include "mozilla/Endian.h"
 #include "mozilla/MathAlgorithms.h"
 #include "mozilla/Preferences.h"
 #include "mozilla/TimeStamp.h"
 
 #include "TexturePoolOGL.h"
 #include "mozilla/layers/CompositorOGL.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/layers/LayerManagerComposite.h"
 #include "mozilla/layers/TextureHostOGL.h"
 
 #include "gfxContext.h"
 #include "gfxUtils.h"
 #include "gfxPrefs.h"
 #include "nsIWidget.h"
 
@@ -1894,17 +1894,17 @@ LayerScope::SendLayerDump(UniquePtr<Pack
         new DebugGLLayersData(Move(aPacket)));
 }
 
 /*static*/
 bool
 LayerScope::CheckSendable()
 {
     // Only compositor threads check LayerScope status
-    MOZ_ASSERT(CompositorParent::IsInCompositorThread() || gIsGtest);
+    MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread() || gIsGtest);
 
     if (!gfxPrefs::LayerScopeEnabled()) {
         return false;
     }
     if (!gLayerScopeManager.GetSocketManager()) {
         Init();
         return false;
     }
--- a/gfx/layers/apz/src/APZCTreeManager.cpp
+++ b/gfx/layers/apz/src/APZCTreeManager.cpp
@@ -14,17 +14,17 @@
 #include "InputData.h"                  // for InputData, etc
 #include "Layers.h"                     // for Layer, etc
 #include "mozilla/dom/Touch.h"          // for Touch
 #include "mozilla/gfx/Logging.h"        // for gfx::TreeLog
 #include "mozilla/gfx/Point.h"          // for Point
 #include "mozilla/layers/APZThreadUtils.h"  // for AssertOnCompositorThread, etc
 #include "mozilla/layers/AsyncCompositionManager.h" // for ViewTransform
 #include "mozilla/layers/AsyncDragMetrics.h" // for AsyncDragMetrics
-#include "mozilla/layers/CompositorParent.h" // for CompositorParent, etc
+#include "mozilla/layers/CompositorBridgeParent.h" // for CompositorBridgeParent, etc
 #include "mozilla/layers/LayerMetricsWrapper.h"
 #include "mozilla/MouseEvents.h"
 #include "mozilla/mozalloc.h"           // for operator new
 #include "mozilla/TouchEvents.h"
 #include "mozilla/Preferences.h"        // for Preferences
 #include "mozilla/EventStateManager.h"  // for WheelPrefs
 #include "nsDebug.h"                    // for NS_WARNING
 #include "nsPoint.h"                    // for nsIntPoint
@@ -50,28 +50,28 @@ namespace layers {
 
 typedef mozilla::gfx::Point Point;
 typedef mozilla::gfx::Point4D Point4D;
 typedef mozilla::gfx::Matrix4x4 Matrix4x4;
 
 float APZCTreeManager::sDPI = 160.0;
 
 struct APZCTreeManager::TreeBuildingState {
-  TreeBuildingState(CompositorParent* aCompositor,
+  TreeBuildingState(CompositorBridgeParent* aCompositor,
                     bool aIsFirstPaint, uint64_t aOriginatingLayersId,
                     APZTestData* aTestData, uint32_t aPaintSequence)
     : mCompositor(aCompositor)
     , mIsFirstPaint(aIsFirstPaint)
     , mOriginatingLayersId(aOriginatingLayersId)
     , mPaintLogger(aTestData, aPaintSequence)
   {
   }
 
   // State that doesn't change as we recurse in the tree building
-  CompositorParent* const mCompositor;
+  CompositorBridgeParent* const mCompositor;
   const bool mIsFirstPaint;
   const uint64_t mOriginatingLayersId;
   const APZPaintLogHelper mPaintLogger;
 
   // State that is updated as we perform the tree build
 
   // A list of nodes that need to be destroyed at the end of the tree building.
   // This is initialized with all nodes in the old tree, and nodes are removed
@@ -126,31 +126,31 @@ APZCTreeManager::GetFrameTime()
 void
 APZCTreeManager::SetAllowedTouchBehavior(uint64_t aInputBlockId,
                                          const nsTArray<TouchBehaviorFlags> &aValues)
 {
   mInputQueue->SetAllowedTouchBehavior(aInputBlockId, aValues);
 }
 
 void
-APZCTreeManager::UpdateHitTestingTree(CompositorParent* aCompositor,
+APZCTreeManager::UpdateHitTestingTree(CompositorBridgeParent* aCompositor,
                                       Layer* aRoot,
                                       bool aIsFirstPaint,
                                       uint64_t aOriginatingLayersId,
                                       uint32_t aPaintSequenceNumber)
 {
   APZThreadUtils::AssertOnCompositorThread();
 
   MutexAutoLock lock(mTreeLock);
 
   // For testing purposes, we log some data to the APZTestData associated with
   // the layers id that originated this update.
   APZTestData* testData = nullptr;
   if (gfxPrefs::APZTestLoggingEnabled()) {
-    if (CompositorParent::LayerTreeState* state = CompositorParent::GetIndirectShadowTree(aOriginatingLayersId)) {
+    if (CompositorBridgeParent::LayerTreeState* state = CompositorBridgeParent::GetIndirectShadowTree(aOriginatingLayersId)) {
       testData = &state->mApzTestData;
       testData->StartNewPaint(aPaintSequenceNumber);
     }
   }
 
   TreeBuildingState state(aCompositor, aIsFirstPaint, aOriginatingLayersId,
                           testData, aPaintSequenceNumber);
 
@@ -346,17 +346,17 @@ APZCTreeManager::PrepareNodeForLayer(con
 {
   mTreeLock.AssertCurrentThreadOwns();
 
   bool needsApzc = true;
   if (!aMetrics.IsScrollable()) {
     needsApzc = false;
   }
 
-  const CompositorParent::LayerTreeState* state = CompositorParent::GetIndirectShadowTree(aLayersId);
+  const CompositorBridgeParent::LayerTreeState* state = CompositorBridgeParent::GetIndirectShadowTree(aLayersId);
   if (!(state && state->mController.get())) {
     needsApzc = false;
   }
 
   RefPtr<HitTestingTreeNode> node = nullptr;
   if (!needsApzc) {
     node = RecycleOrCreateNode(aState, nullptr, aLayersId);
     AttachNodeToTree(node, aParent, aNextSibling);
@@ -433,17 +433,17 @@ APZCTreeManager::PrepareNodeForLayer(con
 
     // The APZC we get off the layer may have been destroyed previously if the
     // layer was inactive or omitted from the layer tree for whatever reason
     // from a layers update. If it later comes back it will have a reference to
     // a destroyed APZC and so we need to throw that out and make a new one.
     bool newApzc = (apzc == nullptr || apzc->IsDestroyed());
     if (newApzc) {
       apzc = NewAPZCInstance(aLayersId, state->mController);
-      apzc->SetCompositorParent(aState.mCompositor);
+      apzc->SetCompositorBridgeParent(aState.mCompositor);
       if (state->mCrossProcessParent != nullptr) {
         apzc->ShareFrameMetricsAcrossProcesses();
       }
       MOZ_ASSERT(node == nullptr);
       node = new HitTestingTreeNode(apzc, true, aLayersId);
     } else {
       // If we are re-using a node for this layer clear the tree pointers
       // so that it doesn't continue pointing to nodes that might no longer
@@ -638,17 +638,18 @@ WillHandleInput(const PanGestureOrScroll
 
 void
 APZCTreeManager::FlushApzRepaints(uint64_t aLayersId)
 {
   // Previously, paints were throttled and therefore this method was used to
   // ensure any pending paints were flushed. Now, paints are flushed
   // immediately, so it is safe to simply send a notification now.
   APZCTM_LOG("Flushing repaints for layers id %" PRIu64, aLayersId);
-  const CompositorParent::LayerTreeState* state = CompositorParent::GetIndirectShadowTree(aLayersId);
+  const CompositorBridgeParent::LayerTreeState* state =
+    CompositorBridgeParent::GetIndirectShadowTree(aLayersId);
   MOZ_ASSERT(state && state->mController);
   NS_DispatchToMainThread(NS_NewRunnableMethod(
     state->mController.get(), &GeckoContentController::NotifyFlushComplete));
 }
 
 nsEventStatus
 APZCTreeManager::ReceiveInputEvent(InputData& aEvent,
                                    ScrollableLayerGuid* aOutTargetGuid,
--- a/gfx/layers/apz/src/APZCTreeManager.h
+++ b/gfx/layers/apz/src/APZCTreeManager.h
@@ -46,17 +46,17 @@ enum ZoomToRectBehavior : uint32_t {
   DISABLE_ZOOM_OUT =   1 << 0,
   PAN_INTO_VIEW_ONLY = 1 << 1,
   ONLY_ZOOM_TO_DEFAULT_SCALE  = 1 << 2
 };
 
 class Layer;
 class AsyncDragMetrics;
 class AsyncPanZoomController;
-class CompositorParent;
+class CompositorBridgeParent;
 class OverscrollHandoffChain;
 struct OverscrollHandoffState;
 struct FlingHandoffState;
 class LayerMetricsWrapper;
 class InputQueue;
 class GeckoContentController;
 class HitTestingTreeNode;
 
@@ -73,17 +73,17 @@ class HitTestingTreeNode;
  * The interpretation of the lock ordering is that if lock A precedes lock B
  * in the ordering sequence, then you must NOT wait on A while holding B.
  *
  * **************************************************************************
  */
 
 /**
  * This class manages the tree of AsyncPanZoomController instances. There is one
- * instance of this class owned by each CompositorParent, and it contains as
+ * instance of this class owned by each CompositorBridgeParent, and it contains as
  * many AsyncPanZoomController instances as there are scrollable container layers.
  * This class generally lives on the compositor thread, although some functions
  * may be called from other threads as noted; thread safety is ensured internally.
  *
  * The bulk of the work of this class happens as part of the UpdateHitTestingTree
  * function, which is when a layer tree update is received by the compositor.
  * This function walks through the layer tree and creates a tree of
  * HitTestingTreeNode instances to match the layer tree and for use in
@@ -132,17 +132,17 @@ public:
    *                      to included a first-paint. If this is true, the part of
    *                      the tree that is affected by the first-paint flag is
    *                      indicated by the aFirstPaintLayersId parameter.
    * @param aPaintSequenceNumber The sequence number of the paint that triggered
    *                             this layer update. Note that every layer child
    *                             process' layer subtree has its own sequence
    *                             numbers.
    */
-  void UpdateHitTestingTree(CompositorParent* aCompositor,
+  void UpdateHitTestingTree(CompositorBridgeParent* aCompositor,
                             Layer* aRoot,
                             bool aIsFirstPaint,
                             uint64_t aOriginatingLayersId,
                             uint32_t aPaintSequenceNumber);
 
   /**
    * Walk the tree of APZCs and flushes the repaint requests for all the APZCS
    * corresponding to the given layers id. Finally, sends a flush complete
--- a/gfx/layers/apz/src/AsyncPanZoomController.cpp
+++ b/gfx/layers/apz/src/AsyncPanZoomController.cpp
@@ -46,19 +46,18 @@
 #include "mozilla/gfx/Point.h"          // for Point, RoundedToInt, etc
 #include "mozilla/gfx/Rect.h"           // for RoundedIn
 #include "mozilla/gfx/ScaleFactor.h"    // for ScaleFactor
 #include "mozilla/layers/APZCTreeManager.h"  // for ScrollableLayerGuid
 #include "mozilla/layers/APZThreadUtils.h"  // for AssertOnControllerThread, etc
 #include "mozilla/layers/AsyncCompositionManager.h"  // for ViewTransform
 #include "mozilla/layers/AxisPhysicsModel.h" // for AxisPhysicsModel
 #include "mozilla/layers/AxisPhysicsMSDModel.h" // for AxisPhysicsMSDModel
-#include "mozilla/layers/CompositorParent.h" // for CompositorParent
+#include "mozilla/layers/CompositorBridgeParent.h" // for CompositorBridgeParent
 #include "mozilla/layers/LayerTransactionParent.h" // for LayerTransactionParent
-#include "mozilla/layers/PCompositorBridgeParent.h" // for PCompositorBridgeParent
 #include "mozilla/layers/ScrollInputMethods.h" // for ScrollInputMethod
 #include "mozilla/mozalloc.h"           // for operator new, etc
 #include "mozilla/unused.h"             // for unused
 #include "mozilla/FloatingPoint.h"      // for FuzzyEquals*
 #include "nsAlgorithm.h"                // for clamped
 #include "nsAutoPtr.h"                  // for nsRefPtr
 #include "nsCOMPtr.h"                   // for already_AddRefed
 #include "nsDebug.h"                    // for NS_WARNING
@@ -885,23 +884,23 @@ AsyncPanZoomController::~AsyncPanZoomCon
 }
 
 PCompositorBridgeParent*
 AsyncPanZoomController::GetSharedFrameMetricsCompositor()
 {
   APZThreadUtils::AssertOnCompositorThread();
 
   if (mSharingFrameMetricsAcrossProcesses) {
-    // |state| may be null here if the CrossProcessCompositorParent has already been destroyed.
-    if (const CompositorParent::LayerTreeState* state = CompositorParent::GetIndirectShadowTree(mLayersId)) {
+    // |state| may be null here if the CrossProcessCompositorBridgeParent has already been destroyed.
+    if (const CompositorBridgeParent::LayerTreeState* state = CompositorBridgeParent::GetIndirectShadowTree(mLayersId)) {
       return state->CrossProcessPCompositorBridge();
     }
     return nullptr;
   }
-  return mCompositorParent.get();
+  return mCompositorBridgeParent.get();
 }
 
 already_AddRefed<GeckoContentController>
 AsyncPanZoomController::GetGeckoContentController() const {
   MonitorAutoLock lock(mRefPtrMonitor);
   RefPtr<GeckoContentController> controller = mGeckoContentController;
   return controller.forget();
 }
@@ -2699,18 +2698,18 @@ void AsyncPanZoomController::CancelAnima
 }
 
 void AsyncPanZoomController::ClearOverscroll() {
   ReentrantMonitorAutoEnter lock(mMonitor);
   mX.ClearOverscroll();
   mY.ClearOverscroll();
 }
 
-void AsyncPanZoomController::SetCompositorParent(CompositorParent* aCompositorParent) {
-  mCompositorParent = aCompositorParent;
+void AsyncPanZoomController::SetCompositorBridgeParent(CompositorBridgeParent* aCompositorBridgeParent) {
+  mCompositorBridgeParent = aCompositorBridgeParent;
 }
 
 void AsyncPanZoomController::ShareFrameMetricsAcrossProcesses() {
   mSharingFrameMetricsAcrossProcesses = true;
 }
 
 void AsyncPanZoomController::AdjustScrollForSurfaceShift(const ScreenPoint& aShift)
 {
@@ -2844,18 +2843,18 @@ const ScreenMargin AsyncPanZoomControlle
   cssMargins.top = -displayPort.y;
   cssMargins.right = displayPort.width - compositionSize.width - cssMargins.left;
   cssMargins.bottom = displayPort.height - compositionSize.height - cssMargins.top;
 
   return cssMargins * aFrameMetrics.DisplayportPixelsPerCSSPixel();
 }
 
 void AsyncPanZoomController::ScheduleComposite() {
-  if (mCompositorParent) {
-    mCompositorParent->ScheduleRenderOnCompositorThread();
+  if (mCompositorBridgeParent) {
+    mCompositorBridgeParent->ScheduleRenderOnCompositorThread();
   }
 }
 
 void AsyncPanZoomController::ScheduleCompositeAndMaybeRepaint() {
   ScheduleComposite();
   RequestContentRepaint();
 }
 
@@ -3770,26 +3769,26 @@ void AsyncPanZoomController::DispatchSta
 
   if (RefPtr<GeckoContentController> controller = GetGeckoContentController()) {
     if (!IsTransformingState(aOldState) && IsTransformingState(aNewState)) {
       controller->NotifyAPZStateChange(
           GetGuid(), APZStateChange::TransformBegin);
 #if defined(XP_WIN) || defined(MOZ_WIDGET_GTK)
       // Let the compositor know about scroll state changes so it can manage
       // windowed plugins.
-      if (mCompositorParent) {
-        mCompositorParent->ScheduleHideAllPluginWindows();
+      if (mCompositorBridgeParent) {
+        mCompositorBridgeParent->ScheduleHideAllPluginWindows();
       }
 #endif
     } else if (IsTransformingState(aOldState) && !IsTransformingState(aNewState)) {
       controller->NotifyAPZStateChange(
           GetGuid(), APZStateChange::TransformEnd);
 #if defined(XP_WIN) || defined(MOZ_WIDGET_GTK)
-      if (mCompositorParent) {
-        mCompositorParent->ScheduleShowAllPluginWindows();
+      if (mCompositorBridgeParent) {
+        mCompositorBridgeParent->ScheduleShowAllPluginWindows();
       }
 #endif
     }
   }
 }
 
 bool AsyncPanZoomController::IsTransformingState(PanZoomState aState) {
   return !(aState == NOTHING || aState == TOUCHING);
--- a/gfx/layers/apz/src/AsyncPanZoomController.h
+++ b/gfx/layers/apz/src/AsyncPanZoomController.h
@@ -37,17 +37,17 @@ namespace ipc {
 class SharedMemoryBasic;
 
 } // namespace ipc
 
 namespace layers {
 
 class AsyncDragMetrics;
 struct ScrollableLayerGuid;
-class CompositorParent;
+class CompositorBridgeParent;
 class GestureEventListener;
 class PCompositorBridgeParent;
 struct AsyncTransform;
 class AsyncPanZoomAnimation;
 class FlingAnimation;
 class InputBlockState;
 class TouchBlockState;
 class PanGestureBlockState;
@@ -193,17 +193,17 @@ public:
    */
   void NotifyScrollUpdated(uint32_t aScrollGeneration,
                            const CSSPoint& aScrollOffset);
 
   /**
    * The platform implementation must set the compositor parent so that we can
    * request composites.
    */
-  void SetCompositorParent(CompositorParent* aCompositorParent);
+  void SetCompositorBridgeParent(CompositorBridgeParent* aCompositorBridgeParent);
 
   /**
    * Inform this APZC that it will be sharing its FrameMetrics with a cross-process
    * compositor so that the associated content process can access it. This is only
    * relevant when progressive painting is enabled.
    */
   void ShareFrameMetricsAcrossProcesses();
 
@@ -510,17 +510,17 @@ protected:
    * the current scale, it doesn't set it to |aScale|). Also considers a focus
    * point so that the page zooms inward/outward from that point.
    */
   void ScaleWithFocus(float aScale,
                       const CSSPoint& aFocus);
 
   /**
    * Schedules a composite on the compositor thread. Wrapper for
-   * CompositorParent::ScheduleRenderOnCompositorThread().
+   * CompositorBridgeParent::ScheduleRenderOnCompositorThread().
    */
   void ScheduleComposite();
 
   /**
    * Schedules a composite, and if enough time has elapsed since the last
    * paint, a paint.
    */
   void ScheduleCompositeAndMaybeRepaint();
@@ -647,17 +647,17 @@ protected:
   // to a nearby snap position if appropriate. The current scroll position is
   // used as the final destination.
   void RequestSnap();
   // Same as above, but takes into account the current velocity to find a
   // predicted destination.
   void RequestSnapToDestination();
 
   uint64_t mLayersId;
-  RefPtr<CompositorParent> mCompositorParent;
+  RefPtr<CompositorBridgeParent> mCompositorBridgeParent;
 
   /* Access to the following two fields is protected by the mRefPtrMonitor,
      since they are accessed on the UI thread but can be cleared on the
      compositor thread. */
   RefPtr<GeckoContentController> mGeckoContentController;
   RefPtr<GestureEventListener> mGestureEventListener;
   mutable Monitor mRefPtrMonitor;
 
--- a/gfx/layers/apz/test/gtest/APZTestCommon.h
+++ b/gfx/layers/apz/test/gtest/APZTestCommon.h
@@ -13,17 +13,17 @@
  */
 
 #include "gtest/gtest.h"
 #include "gmock/gmock.h"
 
 #include "mozilla/Attributes.h"
 #include "mozilla/layers/AsyncCompositionManager.h" // for ViewTransform
 #include "mozilla/layers/GeckoContentController.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/layers/APZCTreeManager.h"
 #include "mozilla/layers/LayerMetricsWrapper.h"
 #include "mozilla/layers/APZThreadUtils.h"
 #include "mozilla/UniquePtr.h"
 #include "apz/src/AsyncPanZoomController.h"
 #include "apz/src/HitTestingTreeNode.h"
 #include "base/task.h"
 #include "Layers.h"
--- a/gfx/layers/apz/util/ChromeProcessController.cpp
+++ b/gfx/layers/apz/util/ChromeProcessController.cpp
@@ -3,17 +3,17 @@
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "ChromeProcessController.h"
 
 #include "MainThreadUtils.h"    // for NS_IsMainThread()
 #include "base/message_loop.h"  // for MessageLoop
 #include "mozilla/dom/Element.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/layers/APZCCallbackHelper.h"
 #include "mozilla/layers/APZEventState.h"
 #include "mozilla/layers/APZCTreeManager.h"
 #include "mozilla/layers/DoubleTapToZoom.h"
 #include "nsIDocument.h"
 #include "nsIInterfaceRequestorUtils.h"
 #include "nsIPresShell.h"
 #include "nsLayoutUtils.h"
--- a/gfx/layers/client/CanvasClient.cpp
+++ b/gfx/layers/client/CanvasClient.cpp
@@ -11,17 +11,17 @@
 #include "ScopedGLHelpers.h"
 #include "gfx2DGlue.h"                  // for ImageFormatToSurfaceFormat
 #include "gfxPlatform.h"                // for gfxPlatform
 #include "GLReadTexImageHelper.h"
 #include "mozilla/gfx/BaseSize.h"       // for BaseSize
 #include "mozilla/layers/BufferTexture.h"
 #include "mozilla/layers/AsyncCanvasRenderer.h"
 #include "mozilla/layers/CompositableForwarder.h"
-#include "mozilla/layers/CompositorChild.h" // for CompositorChild
+#include "mozilla/layers/CompositorBridgeChild.h" // for CompositorBridgeChild
 #include "mozilla/layers/GrallocTextureClient.h"
 #include "mozilla/layers/LayersTypes.h"
 #include "mozilla/layers/TextureClient.h"  // for TextureClient, etc
 #include "mozilla/layers/TextureClientOGL.h"
 #include "nsAutoPtr.h"                  // for nsRefPtr
 #include "nsDebug.h"                    // for printf_stderr, NS_ASSERTION
 #include "nsXULAppAPI.h"                // for XRE_GetProcessType, etc
 #include "TextureClientSharedSurface.h"
--- a/gfx/layers/client/ClientLayerManager.cpp
+++ b/gfx/layers/client/ClientLayerManager.cpp
@@ -7,17 +7,17 @@
 #include "GeckoProfiler.h"              // for PROFILER_LABEL
 #include "gfxPrefs.h"                   // for gfxPrefs::LayersTile...
 #include "mozilla/Assertions.h"         // for MOZ_ASSERT, etc
 #include "mozilla/Hal.h"
 #include "mozilla/dom/ScreenOrientation.h"  // for ScreenOrientation
 #include "mozilla/dom/TabChild.h"       // for TabChild
 #include "mozilla/hal_sandbox/PHal.h"   // for ScreenConfiguration
 #include "mozilla/layers/CompositableClient.h"
-#include "mozilla/layers/CompositorChild.h" // for CompositorChild
+#include "mozilla/layers/CompositorBridgeChild.h" // for CompositorBridgeChild
 #include "mozilla/layers/ContentClient.h"
 #include "mozilla/layers/FrameUniformityData.h"
 #include "mozilla/layers/ISurfaceAllocator.h"
 #include "mozilla/layers/LayersMessages.h"  // for EditReply, etc
 #include "mozilla/layers/LayersSurfaces.h"  // for SurfaceDescriptor
 #include "mozilla/layers/PLayerChild.h"  // for PLayerChild
 #include "mozilla/layers/LayerTransactionChild.h"
 #include "mozilla/layers/ShadowLayerChild.h"
@@ -115,17 +115,17 @@ ClientLayerManager::~ClientLayerManager(
     DidComposite(mLatestTransactionId, now, now);
   }
   mMemoryPressureObserver->Destroy();
   ClearCachedResources();
   // Stop receiveing AsyncParentMessage at Forwarder.
   // After the call, the message is directly handled by LayerTransactionChild. 
   // Basically this function should be called in ShadowLayerForwarder's
   // destructor. But when the destructor is triggered by 
-  // CompositorChild::Destroy(), the destructor can not handle it correctly.
+  // CompositorBridgeChild::Destroy(), the destructor can not handle it correctly.
   // See Bug 1000525.
   mForwarder->StopReceiveAsyncParentMessge();
   mRoot = nullptr;
 
   MOZ_COUNT_DTOR(ClientLayerManager);
 }
 
 int32_t
@@ -364,31 +364,31 @@ ClientLayerManager::EndEmptyTransaction(
   if (mWidget) {
     mWidget->PrepareWindowEffects();
   }
   ForwardTransaction(!(aFlags & END_NO_REMOTE_COMPOSITE));
   MakeSnapshotIfRequired();
   return true;
 }
 
-CompositorChild *
+CompositorBridgeChild *
 ClientLayerManager::GetRemoteRenderer()
 {
   if (!mWidget) {
     return nullptr;
   }
 
   return mWidget->GetRemoteRenderer();
 }
 
-CompositorChild*
-ClientLayerManager::GetCompositorChild()
+CompositorBridgeChild*
+ClientLayerManager::GetCompositorBridgeChild()
 {
   if (!XRE_IsParentProcess()) {
-    return CompositorChild::Get();
+    return CompositorBridgeChild::Get();
   }
   return GetRemoteRenderer();
 }
 
 void
 ClientLayerManager::Composite()
 {
   mForwarder->Composite();
@@ -453,33 +453,33 @@ ClientLayerManager::StartNewRepaintReque
 }
 
 void
 ClientLayerManager::GetFrameUniformity(FrameUniformityData* aOutData)
 {
   MOZ_ASSERT(XRE_IsParentProcess(), "Frame Uniformity only supported in parent process");
 
   if (HasShadowManager()) {
-    CompositorChild* child = GetRemoteRenderer();
+    CompositorBridgeChild* child = GetRemoteRenderer();
     child->SendGetFrameUniformity(aOutData);
     return;
   }
 
   return LayerManager::GetFrameUniformity(aOutData);
 }
 
 bool
 ClientLayerManager::RequestOverfill(mozilla::dom::OverfillCallback* aCallback)
 {
   MOZ_ASSERT(aCallback != nullptr);
   MOZ_ASSERT(HasShadowManager(), "Request Overfill only supported on b2g for now");
 
   if (HasShadowManager()) {
-    CompositorChild* child = GetRemoteRenderer();
-    NS_ASSERTION(child, "Could not get CompositorChild");
+    CompositorBridgeChild* child = GetRemoteRenderer();
+    NS_ASSERTION(child, "Could not get CompositorBridgeChild");
 
     child->AddOverfillObserver(this);
     child->SendRequestOverfill();
     mOverfillCallbacks.AppendElement(aCallback);
   }
 
   return true;
 }
@@ -497,17 +497,17 @@ ClientLayerManager::RunOverfillCallback(
 
 void
 ClientLayerManager::MakeSnapshotIfRequired()
 {
   if (!mShadowTarget) {
     return;
   }
   if (mWidget) {
-    if (CompositorChild* remoteRenderer = GetRemoteRenderer()) {
+    if (CompositorBridgeChild* remoteRenderer = GetRemoteRenderer()) {
       // The compositor doesn't draw to a different sized surface
       // when there's a rotation. Instead we rotate the result
       // when drawing into dt
       LayoutDeviceIntRect outerBounds;
       mWidget->GetBounds(outerBounds);
 
       IntRect bounds = ToOutsideIntRect(mShadowTarget->GetClipExtents());
       if (mTargetRotation) {
@@ -544,55 +544,55 @@ ClientLayerManager::MakeSnapshotIfRequir
   }
   mShadowTarget = nullptr;
 }
 
 void
 ClientLayerManager::FlushRendering()
 {
   if (mWidget) {
-    if (CompositorChild* remoteRenderer = mWidget->GetRemoteRenderer()) {
+    if (CompositorBridgeChild* remoteRenderer = mWidget->GetRemoteRenderer()) {
       remoteRenderer->SendFlushRendering();
     }
   }
 }
 
 void
 ClientLayerManager::UpdateTextureFactoryIdentifier(const TextureFactoryIdentifier& aNewIdentifier)
 {
   mForwarder->IdentifyTextureHost(aNewIdentifier);
 }
 
 void
 ClientLayerManager::SendInvalidRegion(const nsIntRegion& aRegion)
 {
   if (mWidget) {
-    if (CompositorChild* remoteRenderer = mWidget->GetRemoteRenderer()) {
+    if (CompositorBridgeChild* remoteRenderer = mWidget->GetRemoteRenderer()) {
       remoteRenderer->SendNotifyRegionInvalidated(aRegion);
     }
   }
 }
 
 uint32_t
 ClientLayerManager::StartFrameTimeRecording(int32_t aBufferSize)
 {
-  CompositorChild* renderer = GetRemoteRenderer();
+  CompositorBridgeChild* renderer = GetRemoteRenderer();
   if (renderer) {
     uint32_t startIndex;
     renderer->SendStartFrameTimeRecording(aBufferSize, &startIndex);
     return startIndex;
   }
   return -1;
 }
 
 void
 ClientLayerManager::StopFrameTimeRecording(uint32_t         aStartIndex,
                                            nsTArray<float>& aFrameIntervals)
 {
-  CompositorChild* renderer = GetRemoteRenderer();
+  CompositorBridgeChild* renderer = GetRemoteRenderer();
   if (renderer) {
     renderer->SendStopFrameTimeRecording(aStartIndex, &aFrameIntervals);
   }
 }
 
 void
 ClientLayerManager::ForwardTransaction(bool aScheduleComposite)
 {
@@ -787,17 +787,17 @@ ClientLayerManager::GetBackendName(nsASt
 bool
 ClientLayerManager::ProgressiveUpdateCallback(bool aHasPendingNewThebesContent,
                                               FrameMetrics& aMetrics,
                                               bool aDrawingCritical)
 {
 #ifdef MOZ_WIDGET_ANDROID
   MOZ_ASSERT(aMetrics.IsScrollable());
   // This is derived from the code in
-  // gfx/layers/ipc/CompositorParent.cpp::TransformShadowTree.
+  // gfx/layers/ipc/CompositorBridgeParent.cpp::TransformShadowTree.
   CSSToLayerScale paintScale = aMetrics.LayersPixelsPerCSSPixel().ToScaleFactor();
   const CSSRect& metricsDisplayPort =
     (aDrawingCritical && !aMetrics.GetCriticalDisplayPort().IsEmpty()) ?
       aMetrics.GetCriticalDisplayPort() : aMetrics.GetDisplayPort();
   LayerRect displayPort = (metricsDisplayPort + aMetrics.GetScrollOffset()) * paintScale;
 
   ParentLayerPoint scrollOffset;
   CSSToParentLayerScale zoom;
--- a/gfx/layers/client/ClientLayerManager.h
+++ b/gfx/layers/client/ClientLayerManager.h
@@ -26,17 +26,17 @@
 #include "nscore.h"                     // for nsAString
 #include "mozilla/layers/TransactionIdAllocator.h"
 #include "nsIWidget.h"                  // For plugin window configuration information structs
 
 namespace mozilla {
 namespace layers {
 
 class ClientPaintedLayer;
-class CompositorChild;
+class CompositorBridgeChild;
 class ImageLayer;
 class PLayerChild;
 class FrameUniformityData;
 class TextureClientPool;
 
 class ClientLayerManager final : public LayerManager
 {
   typedef nsTArray<RefPtr<Layer> > LayerRefArray;
@@ -153,19 +153,19 @@ public:
   bool CompositorMightResample() { return mCompositorMightResample; } 
   
   DrawPaintedLayerCallback GetPaintedLayerCallback() const
   { return mPaintedLayerCallback; }
 
   void* GetPaintedLayerCallbackData() const
   { return mPaintedLayerCallbackData; }
 
-  CompositorChild* GetRemoteRenderer();
+  CompositorBridgeChild* GetRemoteRenderer();
 
-  CompositorChild* GetCompositorChild();
+  CompositorBridgeChild* GetCompositorBridgeChild();
 
   // Disable component alpha layers with the software compositor.
   virtual bool ShouldAvoidComponentAlphaLayers() override { return !IsCompositingCheap(); }
 
   /**
    * Called for each iteration of a progressive tile update. Updates
    * aMetrics with the current scroll offset and scale being used to composite
    * the primary scrollable layer in this manager, to determine what area
--- a/gfx/layers/client/ClientTiledPaintedLayer.cpp
+++ b/gfx/layers/client/ClientTiledPaintedLayer.cpp
@@ -8,17 +8,17 @@
 #include "UnitTransforms.h"             // for TransformTo
 #include "ClientLayerManager.h"         // for ClientLayerManager, etc
 #include "gfxPlatform.h"                // for gfxPlatform
 #include "gfxPrefs.h"                   // for gfxPrefs
 #include "gfxRect.h"                    // for gfxRect
 #include "mozilla/Assertions.h"         // for MOZ_ASSERT, etc
 #include "mozilla/gfx/BaseSize.h"       // for BaseSize
 #include "mozilla/gfx/Rect.h"           // for Rect, RectTyped
-#include "mozilla/layers/CompositorChild.h"
+#include "mozilla/layers/CompositorBridgeChild.h"
 #include "mozilla/layers/LayerMetricsWrapper.h" // for LayerMetricsWrapper
 #include "mozilla/layers/LayersMessages.h"
 #include "mozilla/mozalloc.h"           // for operator delete, etc
 #include "nsISupportsImpl.h"            // for MOZ_COUNT_CTOR, etc
 #include "LayersLogging.h"
 #include "mozilla/layers/SingleTiledContentClient.h"
 
 namespace mozilla {
@@ -213,19 +213,19 @@ ClientTiledPaintedLayer::BeginPaint()
   // Calculate the scroll offset since the last transaction
   mPaintData.mScrollOffset = displayportMetrics.GetScrollOffset() * displayportMetrics.GetZoom();
   TILING_LOG("TILING %p: Scroll offset %s\n", this, Stringify(mPaintData.mScrollOffset).c_str());
 }
 
 bool
 ClientTiledPaintedLayer::IsScrollingOnCompositor(const FrameMetrics& aParentMetrics)
 {
-  CompositorChild* compositor = nullptr;
+  CompositorBridgeChild* compositor = nullptr;
   if (Manager() && Manager()->AsClientLayerManager()) {
-    compositor = Manager()->AsClientLayerManager()->GetCompositorChild();
+    compositor = Manager()->AsClientLayerManager()->GetCompositorBridgeChild();
   }
 
   if (!compositor) {
     return false;
   }
 
   FrameMetrics compositorMetrics;
   if (!compositor->LookupCompositorFrameMetrics(aParentMetrics.GetScrollId(),
--- a/gfx/layers/client/ContentClient.cpp
+++ b/gfx/layers/client/ContentClient.cpp
@@ -15,17 +15,17 @@
 #include "ipc/ShadowLayers.h"           // for ShadowLayerForwarder
 #include "mozilla/ArrayUtils.h"         // for ArrayLength
 #include "mozilla/Maybe.h"
 #include "mozilla/gfx/2D.h"             // for DrawTarget, Factory
 #include "mozilla/gfx/BasePoint.h"      // for BasePoint
 #include "mozilla/gfx/BaseSize.h"       // for BaseSize
 #include "mozilla/gfx/Rect.h"           // for Rect
 #include "mozilla/gfx/Types.h"
-#include "mozilla/layers/CompositorChild.h" // for CompositorChild
+#include "mozilla/layers/CompositorBridgeChild.h" // for CompositorBridgeChild
 #include "mozilla/layers/LayerManagerComposite.h"
 #include "mozilla/layers/LayersMessages.h"  // for ThebesBufferData
 #include "mozilla/layers/LayersTypes.h"
 #include "nsAutoPtr.h"                  // for nsRefPtr
 #include "nsDebug.h"                    // for NS_ASSERTION, NS_WARNING, etc
 #include "nsISupportsImpl.h"            // for gfxContext::Release, etc
 #include "nsIWidget.h"                  // for nsIWidget
 #include "nsLayoutUtils.h"
--- a/gfx/layers/client/TextureClient.cpp
+++ b/gfx/layers/client/TextureClient.cpp
@@ -974,17 +974,17 @@ TextureClient::RemoveFromCompositable(Co
     // remove old buffer from CompositableHost
     RefPtr<AsyncTransactionWaiter> waiter = aWaiter ? aWaiter
                                                     : new AsyncTransactionWaiter();
     RefPtr<AsyncTransactionTracker> tracker =
         new RemoveTextureFromCompositableTracker(waiter);
     // Hold TextureClient until transaction complete.
     tracker->SetTextureClient(this);
     mRemoveFromCompositableWaiter = waiter;
-    // RemoveTextureFromCompositableAsync() expects CompositorChild's presence.
+    // RemoveTextureFromCompositableAsync() expects CompositorBridgeChild's presence.
     mActor->GetForwarder()->RemoveTextureFromCompositableAsync(tracker, aCompositable, this);
   }
 #endif
 
 }
 
 void
 TextureClient::SetRemoveFromCompositableWaiter(AsyncTransactionWaiter* aWaiter) {
--- a/gfx/layers/client/TiledContentClient.cpp
+++ b/gfx/layers/client/TiledContentClient.cpp
@@ -13,17 +13,17 @@
 #include "gfxPlatform.h"                // for gfxPlatform
 #include "gfxPrefs.h"                   // for gfxPrefs
 #include "gfxRect.h"                    // for gfxRect
 #include "mozilla/MathAlgorithms.h"     // for Abs
 #include "mozilla/gfx/Point.h"          // for IntSize
 #include "mozilla/gfx/Rect.h"           // for Rect
 #include "mozilla/gfx/Tools.h"          // for BytesPerPixel
 #include "mozilla/layers/CompositableForwarder.h"
-#include "mozilla/layers/CompositorChild.h" // for CompositorChild
+#include "mozilla/layers/CompositorBridgeChild.h" // for CompositorBridgeChild
 #include "mozilla/layers/LayerMetricsWrapper.h"
 #include "mozilla/layers/ShadowLayers.h"  // for ShadowLayerForwarder
 #include "TextureClientPool.h"
 #include "nsDebug.h"                    // for NS_ASSERTION
 #include "nsISupportsImpl.h"            // for gfxContext::AddRef, etc
 #include "gfxReusableSharedImageSurfaceWrapper.h"
 #include "nsExpirationTracker.h"        // for nsExpirationTracker
 #include "nsMathUtils.h"               // for NS_lroundf
@@ -162,20 +162,20 @@ bool
 SharedFrameMetricsHelper::UpdateFromCompositorFrameMetrics(
     const LayerMetricsWrapper& aLayer,
     bool aHasPendingNewThebesContent,
     bool aLowPrecision,
     AsyncTransform& aViewTransform)
 {
   MOZ_ASSERT(aLayer);
 
-  CompositorChild* compositor = nullptr;
+  CompositorBridgeChild* compositor = nullptr;
   if (aLayer.Manager() &&
       aLayer.Manager()->AsClientLayerManager()) {
-    compositor = aLayer.Manager()->AsClientLayerManager()->GetCompositorChild();
+    compositor = aLayer.Manager()->AsClientLayerManager()->GetCompositorBridgeChild();
   }
 
   if (!compositor) {
     return false;
   }
 
   const FrameMetrics& contentMetrics = aLayer.Metrics();
   FrameMetrics compositorMetrics;
--- a/gfx/layers/composite/AsyncCompositionManager.cpp
+++ b/gfx/layers/composite/AsyncCompositionManager.cpp
@@ -17,17 +17,17 @@
 #include "mozilla/dom/KeyframeEffect.h" // for KeyframeEffectReadOnly
 #include "mozilla/dom/AnimationEffectReadOnlyBinding.h" // for dom::FillMode
 #include "mozilla/gfx/BaseRect.h"       // for BaseRect
 #include "mozilla/gfx/Point.h"          // for RoundedToInt, PointTyped
 #include "mozilla/gfx/Rect.h"           // for RoundedToInt, RectTyped
 #include "mozilla/gfx/ScaleFactor.h"    // for ScaleFactor
 #include "mozilla/layers/APZUtils.h"    // for CompleteAsyncTransform
 #include "mozilla/layers/Compositor.h"  // for Compositor
-#include "mozilla/layers/CompositorParent.h" // for CompositorParent, etc
+#include "mozilla/layers/CompositorBridgeParent.h" // for CompositorBridgeParent, etc
 #include "mozilla/layers/LayerAnimationUtils.h" // for TimingFunctionToComputedTimingFunction
 #include "mozilla/layers/LayerMetricsWrapper.h" // for LayerMetricsWrapper
 #include "nsCoord.h"                    // for NSAppUnitsToFloatPixels, etc
 #include "nsDebug.h"                    // for NS_ASSERTION, etc
 #include "nsDeviceContext.h"            // for nsDeviceContext
 #include "nsDisplayList.h"              // for nsDisplayTransform, etc
 #include "nsMathUtils.h"                // for NS_round
 #include "nsPoint.h"                    // for nsPoint
@@ -69,24 +69,24 @@ ContentMightReflowOnOrientationChange(co
   return rect.width != rect.height;
 }
 
 template<Op OP>
 static void
 WalkTheTree(Layer* aLayer,
             bool& aReady,
             const TargetConfig& aTargetConfig,
-            CompositorParent* aCompositor,
+            CompositorBridgeParent* aCompositor,
             bool& aHasRemote,
             bool aWillResolvePlugins,
             bool& aDidResolvePlugins)
 {
   if (RefLayer* ref = aLayer->AsRefLayer()) {
     aHasRemote = true;
-    if (const CompositorParent::LayerTreeState* state = CompositorParent::GetIndirectShadowTree(ref->GetReferentId())) {
+    if (const CompositorBridgeParent::LayerTreeState* state = CompositorBridgeParent::GetIndirectShadowTree(ref->GetReferentId())) {
       if (Layer* referent = state->mRoot) {
         if (!ref->GetLocalVisibleRegion().IsEmpty()) {
           dom::ScreenOrientationInternal chromeOrientation = aTargetConfig.orientation();
           dom::ScreenOrientationInternal contentOrientation = state->mTargetConfig.orientation();
           if (!IsSameDimension(chromeOrientation, contentOrientation) &&
               ContentMightReflowOnOrientationChange(aTargetConfig.naturalBounds())) {
             aReady = false;
           }
@@ -126,17 +126,17 @@ AsyncCompositionManager::AsyncCompositio
 {
 }
 
 AsyncCompositionManager::~AsyncCompositionManager()
 {
 }
 
 void
-AsyncCompositionManager::ResolveRefLayers(CompositorParent* aCompositor,
+AsyncCompositionManager::ResolveRefLayers(CompositorBridgeParent* aCompositor,
                                           bool* aHasRemoteContent,
                                           bool* aResolvePlugins)
 {
   if (aHasRemoteContent) {
     *aHasRemoteContent = false;
   }
 
   // If valid *aResolvePlugins indicates if we need to update plugin geometry
@@ -169,17 +169,17 @@ AsyncCompositionManager::ResolveRefLayer
 }
 
 void
 AsyncCompositionManager::DetachRefLayers()
 {
   if (!mLayerManager->GetRoot()) {
     return;
   }
-  CompositorParent* dummy = nullptr;
+  CompositorBridgeParent* dummy = nullptr;
   bool ignored = false;
   WalkTheTree<Detach>(mLayerManager->GetRoot(),
                       mReadyForCompose,
                       mTargetConfig,
                       dummy,
                       ignored, ignored, ignored);
 }
 
@@ -674,17 +674,17 @@ SampleAPZAnimations(const LayerMetricsWr
 
   return activeAnimations;
 }
 
 void
 AsyncCompositionManager::RecordShadowTransforms(Layer* aLayer)
 {
   MOZ_ASSERT(gfxPrefs::CollectScrollTransforms());
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
 
   for (Layer* child = aLayer->GetFirstChild();
       child; child = child->GetNextSibling()) {
       RecordShadowTransforms(child);
   }
 
   for (uint32_t i = 0; i < aLayer->GetFrameMetricsCount(); i++) {
     AsyncPanZoomController* apzc = aLayer->GetAsyncPanZoomController(i);
@@ -1358,17 +1358,17 @@ AsyncCompositionManager::TransformScroll
                             fixedLayerMargins, false);
 
   ExpandRootClipRect(aLayer, fixedLayerMargins);
 }
 
 void
 AsyncCompositionManager::GetFrameUniformity(FrameUniformityData* aOutData)
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   mLayerTransformRecorder.EndTest(aOutData);
 }
 
 bool
 AsyncCompositionManager::TransformShadowTree(TimeStamp aCurrentFrame,
                                              TransformsToSkip aSkip)
 {
   PROFILER_LABEL("AsyncCompositionManager", "TransformShadowTree",
--- a/gfx/layers/composite/AsyncCompositionManager.h
+++ b/gfx/layers/composite/AsyncCompositionManager.h
@@ -21,17 +21,17 @@
 
 namespace mozilla {
 namespace layers {
 
 class AsyncPanZoomController;
 class Layer;
 class LayerManagerComposite;
 class AutoResolveRefLayers;
-class CompositorParent;
+class CompositorBridgeParent;
 
 // Represents async transforms consisting of a scale and a translation.
 struct AsyncTransform {
   explicit AsyncTransform(LayerToParentLayerScale aScale = LayerToParentLayerScale(),
                           ParentLayerPoint aTranslation = ParentLayerPoint())
     : mScale(aScale)
     , mTranslation(aTranslation)
   {}
@@ -189,17 +189,17 @@ private:
    * to the layer tree, if found.
    * aHasRemoteContent - indicates if the layer tree contains a remote reflayer.
    *  May be null.
    * aResolvePlugins - incoming value indicates if plugin windows should be
    *  updated through a call on aCompositor's UpdatePluginWindowState. Applies
    *  to linux and windows only, may be null. On return value indicates
    *  if any updates occured.
    */
-  void ResolveRefLayers(CompositorParent* aCompositor, bool* aHasRemoteContent,
+  void ResolveRefLayers(CompositorBridgeParent* aCompositor, bool* aHasRemoteContent,
                         bool* aResolvePlugins);
 
   /**
    * Detaches all referents resolved by ResolveRefLayers.
    * Assumes that mLayerManager->GetRoot() and mTargetConfig have not changed
    * since ResolveRefLayers was called.
    */
   void DetachRefLayers();
@@ -238,17 +238,17 @@ private:
 #endif
 };
 
 MOZ_MAKE_ENUM_CLASS_BITWISE_OPERATORS(AsyncCompositionManager::TransformsToSkip)
 
 class MOZ_STACK_CLASS AutoResolveRefLayers {
 public:
   explicit AutoResolveRefLayers(AsyncCompositionManager* aManager,
-                                CompositorParent* aCompositor = nullptr,
+                                CompositorBridgeParent* aCompositor = nullptr,
                                 bool* aHasRemoteContent = nullptr,
                                 bool* aResolvePlugins = nullptr) :
     mManager(aManager)
   {
     if (mManager) {
       mManager->ResolveRefLayers(aCompositor, aHasRemoteContent, aResolvePlugins);
     }
   }
--- a/gfx/layers/composite/LayerManagerComposite.h
+++ b/gfx/layers/composite/LayerManagerComposite.h
@@ -244,17 +244,17 @@ public:
     return mVisibleRegions.Get(aGuid);
   }
 
   Compositor* GetCompositor() const
   {
     return mCompositor;
   }
 
-  // Called by CompositorParent when a new compositor has been created due
+  // Called by CompositorBridgeParent when a new compositor has been created due
   // to a device reset. The layer manager must clear any cached resources
   // attached to the old compositor, and make a best effort at ignoring
   // layer or texture updates against the old compositor.
   void ChangeCompositor(Compositor* aNewCompositor);
 
   /**
    * LayerManagerComposite provides sophisticated debug overlays
    * that can request a next frame.
--- a/gfx/layers/d3d9/CompositorD3D9.cpp
+++ b/gfx/layers/d3d9/CompositorD3D9.cpp
@@ -8,28 +8,27 @@
 #include "gfxWindowsPlatform.h"
 #include "nsIWidget.h"
 #include "mozilla/layers/ImageHost.h"
 #include "mozilla/layers/ContentHost.h"
 #include "mozilla/layers/Effects.h"
 #include "nsWindowsHelpers.h"
 #include "Nv3DVUtils.h"
 #include "gfxFailure.h"
-#include "mozilla/layers/PCompositorBridgeParent.h"
 #include "mozilla/layers/LayerManagerComposite.h"
 #include "gfxPrefs.h"
 #include "gfxCrashReporterUtils.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 
 namespace mozilla {
 namespace layers {
 
 using namespace mozilla::gfx;
 
-CompositorD3D9::CompositorD3D9(CompositorParent* aParent, nsIWidget *aWidget)
+CompositorD3D9::CompositorD3D9(CompositorBridgeParent* aParent, nsIWidget *aWidget)
   : Compositor(aParent)
   , mWidget(aWidget)
   , mDeviceResetCount(0)
   , mFailedResetAttempts(0)
 {
 }
 
 CompositorD3D9::~CompositorD3D9()
--- a/gfx/layers/d3d9/CompositorD3D9.h
+++ b/gfx/layers/d3d9/CompositorD3D9.h
@@ -16,17 +16,17 @@
 class nsWidget;
 
 namespace mozilla {
 namespace layers {
 
 class CompositorD3D9 : public Compositor
 {
 public:
-  CompositorD3D9(CompositorParent* aParent, nsIWidget *aWidget);
+  CompositorD3D9(CompositorBridgeParent* aParent, nsIWidget *aWidget);
   ~CompositorD3D9();
 
   virtual bool Initialize() override;
   virtual void Destroy() override {}
 
   virtual TextureFactoryIdentifier
     GetTextureFactoryIdentifier() override;
 
--- a/gfx/layers/ipc/CompositableTransactionParent.cpp
+++ b/gfx/layers/ipc/CompositableTransactionParent.cpp
@@ -2,17 +2,17 @@
  * vim: sw=2 ts=8 et :
  */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "CompositableTransactionParent.h"
 #include "CompositableHost.h"           // for CompositableParent, etc
-#include "CompositorParent.h"           // for CompositorParent
+#include "CompositorBridgeParent.h"     // for CompositorBridgeParent
 #include "GLContext.h"                  // for GLContext
 #include "Layers.h"                     // for Layer
 #include "RenderTrace.h"                // for RenderTraceInvalidateEnd, etc
 #include "mozilla/Assertions.h"         // for MOZ_ASSERT, etc
 #include "mozilla/RefPtr.h"             // for RefPtr
 #include "mozilla/layers/CompositorTypes.h"
 #include "mozilla/layers/ContentHost.h"  // for ContentHostBase
 #include "mozilla/layers/ImageBridgeParent.h" // for ImageBridgeParent
@@ -55,17 +55,17 @@ CompositableHost* AsCompositable(const O
 template<typename T>
 bool ScheduleComposition(const T& op)
 {
   CompositableHost* comp = AsCompositable(op);
   uint64_t id = comp->GetCompositorID();
   if (!comp || !id) {
     return false;
   }
-  CompositorParent* cp = CompositorParent::GetCompositor(id);
+  CompositorBridgeParent* cp = CompositorBridgeParent::GetCompositor(id);
   if (!cp) {
     return false;
   }
   cp->ScheduleComposition();
   return true;
 }
 
 #if defined(DEBUG) || defined(MOZ_WIDGET_GONK)
rename from gfx/layers/ipc/CompositorChild.cpp
rename to gfx/layers/ipc/CompositorBridgeChild.cpp
--- a/gfx/layers/ipc/CompositorChild.cpp
+++ b/gfx/layers/ipc/CompositorBridgeChild.cpp
@@ -1,16 +1,16 @@
 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set sw=2 ts=2 et tw=80 : */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
-#include "mozilla/layers/CompositorChild.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeChild.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include <stddef.h>                     // for size_t
 #include "ClientLayerManager.h"         // for ClientLayerManager
 #include "base/message_loop.h"          // for MessageLoop
 #include "base/task.h"                  // for NewRunnableMethod, etc
 #include "base/tracked.h"               // for FROM_HERE
 #include "mozilla/layers/LayerTransactionChild.h"
 #include "mozilla/layers/PLayerTransactionChild.h"
 #include "mozilla/mozalloc.h"           // for operator new, etc
@@ -29,68 +29,68 @@
 
 using mozilla::layers::LayerTransactionChild;
 using mozilla::dom::TabChildBase;
 using mozilla::Unused;
 
 namespace mozilla {
 namespace layers {
 
-/*static*/ CompositorChild* CompositorChild::sCompositor;
+/*static*/ CompositorBridgeChild* CompositorBridgeChild::sCompositor;
 
 Atomic<int32_t> CompositableForwarder::sSerialCounter(0);
 
-CompositorChild::CompositorChild(ClientLayerManager *aLayerManager)
+CompositorBridgeChild::CompositorBridgeChild(ClientLayerManager *aLayerManager)
   : mLayerManager(aLayerManager)
   , mCanSend(false)
 {
 }
 
-CompositorChild::~CompositorChild()
+CompositorBridgeChild::~CompositorBridgeChild()
 {
   XRE_GetIOMessageLoop()->PostTask(FROM_HERE,
                                    new DeleteTask<Transport>(GetTransport()));
 
   if (mCanSend) {
-    gfxCriticalError() << "CompositorChild was not deinitialized";
+    gfxCriticalError() << "CompositorBridgeChild was not deinitialized";
   }
 }
 
-static void DeferredDestroyCompositor(RefPtr<CompositorParent> aCompositorParent,
-                                      RefPtr<CompositorChild> aCompositorChild)
+static void DeferredDestroyCompositor(RefPtr<CompositorBridgeParent> aCompositorBridgeParent,
+                                      RefPtr<CompositorBridgeChild> aCompositorBridgeChild)
 {
     // Bug 848949 needs to be fixed before
     // we can close the channel properly
-    //aCompositorChild->Close();
+    //aCompositorBridgeChild->Close();
 }
 
 void
-CompositorChild::Destroy()
+CompositorBridgeChild::Destroy()
 {
   // This must not be called from the destructor!
   MOZ_ASSERT(mRefCnt != 0);
 
   if (!mCanSend) {
     return;
   }
 
   mCanSend = false;
 
   // Destroying the layer manager may cause all sorts of things to happen, so
   // let's make sure there is still a reference to keep this alive whatever
   // happens.
-  RefPtr<CompositorChild> selfRef = this;
+  RefPtr<CompositorBridgeChild> selfRef = this;
 
   SendWillStop();
   // The call just made to SendWillStop can result in IPC from the
-  // CompositorParent to the CompositorChild (e.g. caused by the destruction
+  // CompositorBridgeParent to the CompositorBridgeChild (e.g. caused by the destruction
   // of shared memory). We need to ensure this gets processed by the
-  // CompositorChild before it gets destroyed. It suffices to ensure that
+  // CompositorBridgeChild before it gets destroyed. It suffices to ensure that
   // events already in the MessageLoop get processed before the
-  // CompositorChild is destroyed, so we add a task to the MessageLoop to
+  // CompositorBridgeChild is destroyed, so we add a task to the MessageLoop to
   // handle compositor desctruction.
 
   // From now on the only message we can send is Stop.
 
   if (mLayerManager) {
     mLayerManager->Destroy();
     mLayerManager = nullptr;
   }
@@ -103,38 +103,38 @@ CompositorChild::Destroy()
     layers->Destroy();
   }
 
   SendStop();
 
   // The DeferredDestroyCompositor task takes ownership of compositorParent and
   // will release them when it runs.
   MessageLoop::current()->PostTask(FROM_HERE,
-             NewRunnableFunction(DeferredDestroyCompositor, mCompositorParent, selfRef));
+             NewRunnableFunction(DeferredDestroyCompositor, mCompositorBridgeParent, selfRef));
 }
 
 bool
-CompositorChild::LookupCompositorFrameMetrics(const FrameMetrics::ViewID aId,
-                                              FrameMetrics& aFrame)
+CompositorBridgeChild::LookupCompositorFrameMetrics(const FrameMetrics::ViewID aId,
+                                                    FrameMetrics& aFrame)
 {
   SharedFrameMetricsData* data = mFrameMetricsTable.Get(aId);
   if (data) {
     data->CopyFrameMetrics(&aFrame);
     return true;
   }
   return false;
 }
 
 /*static*/ PCompositorBridgeChild*
-CompositorChild::Create(Transport* aTransport, ProcessId aOtherPid)
+CompositorBridgeChild::Create(Transport* aTransport, ProcessId aOtherPid)
 {
   // There's only one compositor per child process.
   MOZ_ASSERT(!sCompositor);
 
-  RefPtr<CompositorChild> child(new CompositorChild(nullptr));
+  RefPtr<CompositorBridgeChild> child(new CompositorBridgeChild(nullptr));
   if (!child->Open(aTransport, aOtherPid, XRE_GetIOMessageLoop(), ipc::ChildSide)) {
     NS_RUNTIMEABORT("Couldn't Open() Compositor channel.");
     return nullptr;
   }
 
   child->mCanSend = true;
 
   // We release this ref in ActorDestroy().
@@ -145,78 +145,78 @@ CompositorChild::Create(Transport* aTran
   sCompositor->SendGetTileSize(&width, &height);
   gfxPlatform::GetPlatform()->SetTileSize(width, height);
 
   // We release this ref in ActorDestroy().
   return sCompositor;
 }
 
 bool
-CompositorChild::OpenSameProcess(CompositorParent* aParent)
+CompositorBridgeChild::OpenSameProcess(CompositorBridgeParent* aParent)
 {
   MOZ_ASSERT(aParent);
 
-  mCompositorParent = aParent;
-  mCanSend = Open(mCompositorParent->GetIPCChannel(),
-                  CompositorParent::CompositorLoop(),
+  mCompositorBridgeParent = aParent;
+  mCanSend = Open(mCompositorBridgeParent->GetIPCChannel(),
+                  CompositorBridgeParent::CompositorLoop(),
                   ipc::ChildSide);
   return mCanSend;
 }
 
-/*static*/ CompositorChild*
-CompositorChild::Get()
+/*static*/ CompositorBridgeChild*
+CompositorBridgeChild::Get()
 {
   // This is only expected to be used in child processes.
   MOZ_ASSERT(!XRE_IsParentProcess());
   return sCompositor;
 }
 
 PLayerTransactionChild*
-CompositorChild::AllocPLayerTransactionChild(const nsTArray<LayersBackend>& aBackendHints,
-                                             const uint64_t& aId,
-                                             TextureFactoryIdentifier*,
-                                             bool*)
+CompositorBridgeChild::AllocPLayerTransactionChild(const nsTArray<LayersBackend>& aBackendHints,
+                                                   const uint64_t& aId,
+                                                   TextureFactoryIdentifier*,
+                                                   bool*)
 {
   MOZ_ASSERT(mCanSend);
   LayerTransactionChild* c = new LayerTransactionChild(aId);
   c->AddIPDLReference();
   return c;
 }
 
 bool
-CompositorChild::DeallocPLayerTransactionChild(PLayerTransactionChild* actor)
+CompositorBridgeChild::DeallocPLayerTransactionChild(PLayerTransactionChild* actor)
 {
   uint64_t childId = static_cast<LayerTransactionChild*>(actor)->GetId();
 
   for (auto iter = mFrameMetricsTable.Iter(); !iter.Done(); iter.Next()) {
     nsAutoPtr<SharedFrameMetricsData>& data = iter.Data();
     if (data->GetLayersId() == childId) {
       iter.Remove();
     }
   }
   static_cast<LayerTransactionChild*>(actor)->ReleaseIPDLReference();
   return true;
 }
 
 bool
-CompositorChild::RecvInvalidateLayers(const uint64_t& aLayersId)
+CompositorBridgeChild::RecvInvalidateLayers(const uint64_t& aLayersId)
 {
   if (mLayerManager) {
     MOZ_ASSERT(aLayersId == 0);
     FrameLayerBuilder::InvalidateAllLayers(mLayerManager);
   } else if (aLayersId != 0) {
     if (dom::TabChild* child = dom::TabChild::GetFrom(aLayersId)) {
       child->InvalidateLayers();
     }
   }
   return true;
 }
 
 bool
-CompositorChild::RecvCompositorUpdated(const uint64_t& aLayersId,
+CompositorBridgeChild::RecvCompositorUpdated(const uint64_t& aLayersId,
                                       const TextureFactoryIdentifier& aNewIdentifier)
 {
   if (mLayerManager) {
     // This case is handled directly by nsBaseWidget.
     MOZ_ASSERT(aLayersId == 0);
   } else if (aLayersId != 0) {
     if (dom::TabChild* child = dom::TabChild::GetFrom(aLayersId)) {
       child->CompositorUpdated(aNewIdentifier);
@@ -258,22 +258,22 @@ static void CalculatePluginClip(const La
     const LayoutDeviceIntRect& rect = iter.Get();
     aResult.AppendElement(rect);
     aVisibleBounds.UnionRect(aVisibleBounds, rect);
   }
 }
 #endif
 
 bool
-CompositorChild::RecvUpdatePluginConfigurations(const LayoutDeviceIntPoint& aContentOffset,
-                                                const LayoutDeviceIntRegion& aParentLayerVisibleRegion,
-                                                nsTArray<PluginWindowData>&& aPlugins)
+CompositorBridgeChild::RecvUpdatePluginConfigurations(const LayoutDeviceIntPoint& aContentOffset,
+                                                      const LayoutDeviceIntRegion& aParentLayerVisibleRegion,
+                                                      nsTArray<PluginWindowData>&& aPlugins)
 {
 #if !defined(XP_WIN) && !defined(MOZ_WIDGET_GTK)
-  NS_NOTREACHED("CompositorChild::RecvUpdatePluginConfigurations calls "
+  NS_NOTREACHED("CompositorBridgeChild::RecvUpdatePluginConfigurations calls "
                 "unexpected on this platform.");
   return false;
 #else
   // Now that we are on the main thread, update plugin widget config.
   // This should happen a little before we paint to the screen assuming
   // the main thread is running freely.
   DebugOnly<nsresult> rv;
   MOZ_ASSERT(NS_IsMainThread());
@@ -346,384 +346,384 @@ CompositorChild::RecvUpdatePluginConfigu
 #if defined(XP_WIN) || defined(MOZ_WIDGET_GTK)
   SendRemotePluginsReady();
 #endif
   return true;
 #endif // !defined(XP_WIN) && !defined(MOZ_WIDGET_GTK)
 }
 
 bool
-CompositorChild::RecvHideAllPlugins(const uintptr_t& aParentWidget)
+CompositorBridgeChild::RecvHideAllPlugins(const uintptr_t& aParentWidget)
 {
 #if !defined(XP_WIN) && !defined(MOZ_WIDGET_GTK)
-  NS_NOTREACHED("CompositorChild::RecvHideAllPlugins calls "
+  NS_NOTREACHED("CompositorBridgeChild::RecvHideAllPlugins calls "
                 "unexpected on this platform.");
   return false;
 #else
   MOZ_ASSERT(NS_IsMainThread());
   nsTArray<uintptr_t> list;
   nsIWidget::UpdateRegisteredPluginWindowVisibility(aParentWidget, list);
 #if defined(XP_WIN) || defined(MOZ_WIDGET_GTK)
   SendRemotePluginsReady();
 #endif
   return true;
 #endif // !defined(XP_WIN) && !defined(MOZ_WIDGET_GTK)
 }
 
 bool
-CompositorChild::RecvDidComposite(const uint64_t& aId, const uint64_t& aTransactionId,
-                                  const TimeStamp& aCompositeStart,
-                                  const TimeStamp& aCompositeEnd)
+CompositorBridgeChild::RecvDidComposite(const uint64_t& aId, const uint64_t& aTransactionId,
+                                        const TimeStamp& aCompositeStart,
+                                        const TimeStamp& aCompositeEnd)
 {
   if (mLayerManager) {
     MOZ_ASSERT(aId == 0);
     mLayerManager->DidComposite(aTransactionId, aCompositeStart, aCompositeEnd);
   } else if (aId != 0) {
     dom::TabChild *child = dom::TabChild::GetFrom(aId);
     if (child) {
       child->DidComposite(aTransactionId, aCompositeStart, aCompositeEnd);
     }
   }
   return true;
 }
 
 bool
-CompositorChild::RecvOverfill(const uint32_t &aOverfill)
+CompositorBridgeChild::RecvOverfill(const uint32_t &aOverfill)
 {
   for (size_t i = 0; i < mOverfillObservers.Length(); i++) {
     mOverfillObservers[i]->RunOverfillCallback(aOverfill);
   }
   mOverfillObservers.Clear();
   return true;
 }
 
 void
-CompositorChild::AddOverfillObserver(ClientLayerManager* aLayerManager)
+CompositorBridgeChild::AddOverfillObserver(ClientLayerManager* aLayerManager)
 {
   MOZ_ASSERT(aLayerManager);
   mOverfillObservers.AppendElement(aLayerManager);
 }
 
 bool
-CompositorChild::RecvClearCachedResources(const uint64_t& aId)
+CompositorBridgeChild::RecvClearCachedResources(const uint64_t& aId)
 {
   dom::TabChild* child = dom::TabChild::GetFrom(aId);
   if (child) {
     child->ClearCachedResources();
   }
   return true;
 }
 
 void
-CompositorChild::ActorDestroy(ActorDestroyReason aWhy)
+CompositorBridgeChild::ActorDestroy(ActorDestroyReason aWhy)
 {
   MOZ_ASSERT(sCompositor == this);
 
   if (aWhy == AbnormalShutdown) {
 #ifdef MOZ_B2G
   // Due to poor lifetime management of gralloc (and possibly shmems) we will
   // crash at some point in the future when we get destroyed due to abnormal
   // shutdown. Its better just to crash here. On desktop though, we have a chance
   // of recovering.
-    NS_RUNTIMEABORT("ActorDestroy by IPC channel failure at CompositorChild");
+    NS_RUNTIMEABORT("ActorDestroy by IPC channel failure at CompositorBridgeChild");
 #endif
 
     // If the parent side runs into a problem then the actor will be destroyed.
     // There is nothing we can do in the child side, here sets mCanSend as false.
     mCanSend = false;
     gfxCriticalNote << "Receive IPC close with reason=" << aWhy;
   }
 
   MessageLoop::current()->PostTask(
     FROM_HERE,
-    NewRunnableMethod(this, &CompositorChild::Release));
+    NewRunnableMethod(this, &CompositorBridgeChild::Release));
 }
 
 bool
-CompositorChild::RecvSharedCompositorFrameMetrics(
+CompositorBridgeChild::RecvSharedCompositorFrameMetrics(
     const mozilla::ipc::SharedMemoryBasic::Handle& metrics,
     const CrossProcessMutexHandle& handle,
     const uint64_t& aLayersId,
     const uint32_t& aAPZCId)
 {
   SharedFrameMetricsData* data = new SharedFrameMetricsData(
     metrics, handle, aLayersId, aAPZCId);
   mFrameMetricsTable.Put(data->GetViewID(), data);
   return true;
 }
 
 bool
-CompositorChild::RecvReleaseSharedCompositorFrameMetrics(
+CompositorBridgeChild::RecvReleaseSharedCompositorFrameMetrics(
     const ViewID& aId,
     const uint32_t& aAPZCId)
 {
   SharedFrameMetricsData* data = mFrameMetricsTable.Get(aId);
   // The SharedFrameMetricsData may have been removed previously if
   // a SharedFrameMetricsData with the same ViewID but later APZCId had
   // been store and over wrote it.
   if (data && (data->GetAPZCId() == aAPZCId)) {
     mFrameMetricsTable.Remove(aId);
   }
   return true;
 }
 
-CompositorChild::SharedFrameMetricsData::SharedFrameMetricsData(
+CompositorBridgeChild::SharedFrameMetricsData::SharedFrameMetricsData(
     const ipc::SharedMemoryBasic::Handle& metrics,
     const CrossProcessMutexHandle& handle,
     const uint64_t& aLayersId,
     const uint32_t& aAPZCId)
   : mMutex(nullptr)
   , mLayersId(aLayersId)
   , mAPZCId(aAPZCId)
 {
   mBuffer = new ipc::SharedMemoryBasic;
   mBuffer->SetHandle(metrics);
   mBuffer->Map(sizeof(FrameMetrics));
   mMutex = new CrossProcessMutex(handle);
   MOZ_COUNT_CTOR(SharedFrameMetricsData);
 }
 
-CompositorChild::SharedFrameMetricsData::~SharedFrameMetricsData()
+CompositorBridgeChild::SharedFrameMetricsData::~SharedFrameMetricsData()
 {
   // When the hash table deletes the class, delete
   // the shared memory and mutex.
   delete mMutex;
   mBuffer = nullptr;
   MOZ_COUNT_DTOR(SharedFrameMetricsData);
 }
 
 void
-CompositorChild::SharedFrameMetricsData::CopyFrameMetrics(FrameMetrics* aFrame)
+CompositorBridgeChild::SharedFrameMetricsData::CopyFrameMetrics(FrameMetrics* aFrame)
 {
   FrameMetrics* frame = static_cast<FrameMetrics*>(mBuffer->memory());
   MOZ_ASSERT(frame);
   mMutex->Lock();
   *aFrame = *frame;
   mMutex->Unlock();
 }
 
 FrameMetrics::ViewID
-CompositorChild::SharedFrameMetricsData::GetViewID()
+CompositorBridgeChild::SharedFrameMetricsData::GetViewID()
 {
   FrameMetrics* frame = static_cast<FrameMetrics*>(mBuffer->memory());
   MOZ_ASSERT(frame);
   // Not locking to read of mScrollId since it should not change after being
   // initially set.
   return frame->GetScrollId();
 }
 
 uint64_t
-CompositorChild::SharedFrameMetricsData::GetLayersId() const
+CompositorBridgeChild::SharedFrameMetricsData::GetLayersId() const
 {
   return mLayersId;
 }
 
 uint32_t
-CompositorChild::SharedFrameMetricsData::GetAPZCId()
+CompositorBridgeChild::SharedFrameMetricsData::GetAPZCId()
 {
   return mAPZCId;
 }
 
 
 bool
-CompositorChild::RecvRemotePaintIsReady()
+CompositorBridgeChild::RecvRemotePaintIsReady()
 {
   // Used on the content thread, this bounces the message to the
   // TabParent (via the TabChild) if the notification was previously requested.
   // XPCOM gives a soup of compiler errors when trying to do_QueryReference
   // so I'm using static_cast<>
-  MOZ_LAYERS_LOG(("[RemoteGfx] CompositorChild received RemotePaintIsReady"));
+  MOZ_LAYERS_LOG(("[RemoteGfx] CompositorBridgeChild received RemotePaintIsReady"));
   RefPtr<nsISupports> iTabChildBase(do_QueryReferent(mWeakTabChild));
   if (!iTabChildBase) {
     MOZ_LAYERS_LOG(("[RemoteGfx] Note: TabChild was released before RemotePaintIsReady. "
         "MozAfterRemotePaint will not be sent to listener."));
     return true;
   }
   TabChildBase* tabChildBase = static_cast<TabChildBase*>(iTabChildBase.get());
   TabChild* tabChild = static_cast<TabChild*>(tabChildBase);
   MOZ_ASSERT(tabChild);
   Unused << tabChild->SendRemotePaintIsReady();
   mWeakTabChild = nullptr;
   return true;
 }
 
 
 void
-CompositorChild::RequestNotifyAfterRemotePaint(TabChild* aTabChild)
+CompositorBridgeChild::RequestNotifyAfterRemotePaint(TabChild* aTabChild)
 {
-  MOZ_ASSERT(aTabChild, "NULL TabChild not allowed in CompositorChild::RequestNotifyAfterRemotePaint");
+  MOZ_ASSERT(aTabChild, "NULL TabChild not allowed in CompositorBridgeChild::RequestNotifyAfterRemotePaint");
   mWeakTabChild = do_GetWeakReference( static_cast<dom::TabChildBase*>(aTabChild) );
   Unused << SendRequestNotifyAfterRemotePaint();
 }
 
 void
-CompositorChild::CancelNotifyAfterRemotePaint(TabChild* aTabChild)
+CompositorBridgeChild::CancelNotifyAfterRemotePaint(TabChild* aTabChild)
 {
   RefPtr<nsISupports> iTabChildBase(do_QueryReferent(mWeakTabChild));
   if (!iTabChildBase) {
     return;
   }
   TabChildBase* tabChildBase = static_cast<TabChildBase*>(iTabChildBase.get());
   TabChild* tabChild = static_cast<TabChild*>(tabChildBase);
   if (tabChild == aTabChild) {
     mWeakTabChild = nullptr;
   }
 }
 
 bool
-CompositorChild::SendWillStop()
+CompositorBridgeChild::SendWillStop()
 {
   return PCompositorBridgeChild::SendWillStop();
 }
 
 bool
-CompositorChild::SendPause()
+CompositorBridgeChild::SendPause()
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendPause();
 }
 
 bool
-CompositorChild::SendResume()
+CompositorBridgeChild::SendResume()
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendResume();
 }
 
 bool
-CompositorChild::SendNotifyHidden(const uint64_t& id)
+CompositorBridgeChild::SendNotifyHidden(const uint64_t& id)
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendNotifyHidden(id);
 }
 
 bool
-CompositorChild::SendNotifyVisible(const uint64_t& id)
+CompositorBridgeChild::SendNotifyVisible(const uint64_t& id)
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendNotifyVisible(id);
 }
 
 bool
-CompositorChild::SendNotifyChildCreated(const uint64_t& id)
+CompositorBridgeChild::SendNotifyChildCreated(const uint64_t& id)
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendNotifyChildCreated(id);
 }
 
 bool
-CompositorChild::SendAdoptChild(const uint64_t& id)
+CompositorBridgeChild::SendAdoptChild(const uint64_t& id)
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendAdoptChild(id);
 }
 
 bool
-CompositorChild::SendMakeSnapshot(const SurfaceDescriptor& inSnapshot, const gfx::IntRect& dirtyRect)
+CompositorBridgeChild::SendMakeSnapshot(const SurfaceDescriptor& inSnapshot, const gfx::IntRect& dirtyRect)
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendMakeSnapshot(inSnapshot, dirtyRect);
 }
 
 bool
-CompositorChild::SendFlushRendering()
+CompositorBridgeChild::SendFlushRendering()
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendFlushRendering();
 }
 
 bool
-CompositorChild::SendGetTileSize(int32_t* tileWidth, int32_t* tileHeight)
+CompositorBridgeChild::SendGetTileSize(int32_t* tileWidth, int32_t* tileHeight)
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendGetTileSize(tileWidth, tileHeight);
 }
 
 bool
-CompositorChild::SendStartFrameTimeRecording(const int32_t& bufferSize, uint32_t* startIndex)
+CompositorBridgeChild::SendStartFrameTimeRecording(const int32_t& bufferSize, uint32_t* startIndex)
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendStartFrameTimeRecording(bufferSize, startIndex);
 }
 
 bool
-CompositorChild::SendStopFrameTimeRecording(const uint32_t& startIndex, nsTArray<float>* intervals)
+CompositorBridgeChild::SendStopFrameTimeRecording(const uint32_t& startIndex, nsTArray<float>* intervals)
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendStopFrameTimeRecording(startIndex, intervals);
 }
 
 bool
-CompositorChild::SendNotifyRegionInvalidated(const nsIntRegion& region)
+CompositorBridgeChild::SendNotifyRegionInvalidated(const nsIntRegion& region)
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendNotifyRegionInvalidated(region);
 }
 
 bool
-CompositorChild::SendRequestNotifyAfterRemotePaint()
+CompositorBridgeChild::SendRequestNotifyAfterRemotePaint()
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendRequestNotifyAfterRemotePaint();
 }
 
 bool
-CompositorChild::SendClearApproximatelyVisibleRegions(uint64_t aLayersId,
-                                                      uint32_t aPresShellId)
+CompositorBridgeChild::SendClearApproximatelyVisibleRegions(uint64_t aLayersId,
+                                                            uint32_t aPresShellId)
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendClearApproximatelyVisibleRegions(aLayersId,
                                                                 aPresShellId);
 }
 
 bool
-CompositorChild::SendNotifyApproximatelyVisibleRegion(const ScrollableLayerGuid& aGuid,
-                                                      const CSSIntRegion& aRegion)
+CompositorBridgeChild::SendNotifyApproximatelyVisibleRegion(const ScrollableLayerGuid& aGuid,
+                                                            const CSSIntRegion& aRegion)
 {
   MOZ_ASSERT(mCanSend);
   if (!mCanSend) {
     return true;
   }
   return PCompositorBridgeChild::SendNotifyApproximatelyVisibleRegion(aGuid, aRegion);
 }
 
rename from gfx/layers/ipc/CompositorChild.h
rename to gfx/layers/ipc/CompositorBridgeChild.h
--- a/gfx/layers/ipc/CompositorChild.h
+++ b/gfx/layers/ipc/CompositorBridgeChild.h
@@ -1,16 +1,16 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set sw=2 ts=8 et tw=80 : */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
-#ifndef mozilla_layers_CompositorChild_h
-#define mozilla_layers_CompositorChild_h
+#ifndef mozilla_layers_CompositorBridgeChild_h
+#define mozilla_layers_CompositorBridgeChild_h
 
 #include "base/basictypes.h"            // for DISALLOW_EVIL_CONSTRUCTORS
 #include "mozilla/Assertions.h"         // for MOZ_ASSERT_HELPER2
 #include "mozilla/Attributes.h"         // for override
 #include "mozilla/ipc/ProtocolUtils.h"
 #include "mozilla/layers/PCompositorBridgeChild.h"
 #include "nsAutoPtr.h"                  // for nsRefPtr
 #include "nsClassHashtable.h"           // for nsClassHashtable
@@ -26,25 +26,25 @@ namespace dom {
   class TabChild;
 } // namespace dom
 
 namespace layers {
 
 using mozilla::dom::TabChild;
 
 class ClientLayerManager;
-class CompositorParent;
+class CompositorBridgeParent;
 struct FrameMetrics;
 
-class CompositorChild final : public PCompositorBridgeChild
+class CompositorBridgeChild final : public PCompositorBridgeChild
 {
-  NS_INLINE_DECL_THREADSAFE_REFCOUNTING_WITH_MAIN_THREAD_DESTRUCTION(CompositorChild)
+  NS_INLINE_DECL_THREADSAFE_REFCOUNTING_WITH_MAIN_THREAD_DESTRUCTION(CompositorBridgeChild)
 
 public:
-  explicit CompositorChild(ClientLayerManager *aLayerManager);
+  explicit CompositorBridgeChild(ClientLayerManager *aLayerManager);
 
   void Destroy();
 
   /**
    * Lookup the FrameMetrics shared by the compositor process with the
    * associated FrameMetrics::ViewID. The returned FrameMetrics is used
    * in progressive paint calculations.
    */
@@ -54,22 +54,22 @@ public:
    * We're asked to create a new Compositor in response to an Opens()
    * or Bridge() request from our parent process.  The Transport is to
    * the compositor's context.
    */
   static PCompositorBridgeChild*
   Create(Transport* aTransport, ProcessId aOtherProcess);
 
   /**
-   * Initialize the CompositorChild and open the connection in the non-multi-process
+   * Initialize the CompositorBridgeChild and open the connection in the non-multi-process
    * case.
    */
-  bool OpenSameProcess(CompositorParent* aParent);
+  bool OpenSameProcess(CompositorBridgeParent* aParent);
 
-  static CompositorChild* Get();
+  static CompositorBridgeChild* Get();
 
   static bool ChildProcessHasCompositor() { return sCompositor != nullptr; }
 
   void AddOverfillObserver(ClientLayerManager* aLayerManager);
 
   virtual bool
   RecvClearCachedResources(const uint64_t& id) override;
 
@@ -127,17 +127,17 @@ public:
   bool SendNotifyRegionInvalidated(const nsIntRegion& region);
   bool SendRequestNotifyAfterRemotePaint();
   bool SendClearApproximatelyVisibleRegions(uint64_t aLayersId, uint32_t aPresShellId);
   bool SendNotifyApproximatelyVisibleRegion(const ScrollableLayerGuid& aGuid,
                                             const mozilla::CSSIntRegion& aRegion);
 
 private:
   // Private destructor, to discourage deletion outside of Release():
-  virtual ~CompositorChild();
+  virtual ~CompositorBridgeChild();
 
   virtual PLayerTransactionChild*
     AllocPLayerTransactionChild(const nsTArray<LayersBackend>& aBackendHints,
                                 const uint64_t& aId,
                                 TextureFactoryIdentifier* aTextureFactoryIdentifier,
                                 bool* aSuccess) override;
 
   virtual bool DeallocPLayerTransactionChild(PLayerTransactionChild *aChild) override;
@@ -177,38 +177,38 @@ private:
     RefPtr<mozilla::ipc::SharedMemoryBasic> mBuffer;
     CrossProcessMutex* mMutex;
     uint64_t mLayersId;
     // Unique ID of the APZC that is sharing the FrameMetrics
     uint32_t mAPZCId;
   };
 
   RefPtr<ClientLayerManager> mLayerManager;
-  // When not multi-process, hold a reference to the CompositorParent to keep it
+  // When not multi-process, hold a reference to the CompositorBridgeParent to keep it
   // alive. This reference should be null in multi-process.
-  RefPtr<CompositorParent> mCompositorParent;
+  RefPtr<CompositorBridgeParent> mCompositorBridgeParent;
 
   // The ViewID of the FrameMetrics is used as the key for this hash table.
   // While this should be safe to use since the ViewID is unique
   nsClassHashtable<nsUint64HashKey, SharedFrameMetricsData> mFrameMetricsTable;
 
   // When we're in a child process, this is the process-global
   // compositor that we use to forward transactions directly to the
   // compositor context in another process.
-  static CompositorChild* sCompositor;
+  static CompositorBridgeChild* sCompositor;
 
   // Weakly hold the TabChild that made a request to be alerted when
   // the transaction has been received.
   nsWeakPtr mWeakTabChild;      // type is TabChild
 
-  DISALLOW_EVIL_CONSTRUCTORS(CompositorChild);
+  DISALLOW_EVIL_CONSTRUCTORS(CompositorBridgeChild);
 
   // When we receive overfill numbers, notify these client layer managers
   AutoTArray<ClientLayerManager*,0> mOverfillObservers;
 
   // True until the beginning of the two-step shutdown sequence of this actor.
   bool mCanSend;
 };
 
 } // namespace layers
 } // namespace mozilla
 
-#endif // mozilla_layers_CompositorChild_h
+#endif // mozilla_layers_CompositorBrigedChild_h
rename from gfx/layers/ipc/CompositorParent.cpp
rename to gfx/layers/ipc/CompositorBridgeParent.cpp
--- a/gfx/layers/ipc/CompositorParent.cpp
+++ b/gfx/layers/ipc/CompositorBridgeParent.cpp
@@ -1,15 +1,15 @@
 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set sw=2 ts=2 et tw=80 : */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include <stdio.h>                      // for fprintf, stdout
 #include <stdint.h>                     // for uint64_t
 #include <map>                          // for _Rb_tree_iterator, etc
 #include <utility>                      // for pair
 #include "LayerTransactionParent.h"     // for LayerTransactionParent
 #include "RenderTrace.h"                // for RenderTraceLayers
 #include "base/message_loop.h"          // for MessageLoop
 #include "base/process.h"               // for ProcessId
@@ -98,48 +98,48 @@ namespace layers {
 
 using namespace mozilla::ipc;
 using namespace mozilla::gfx;
 using namespace std;
 
 using base::ProcessId;
 using base::Thread;
 
-CompositorParent::LayerTreeState::LayerTreeState()
+CompositorBridgeParent::LayerTreeState::LayerTreeState()
   : mParent(nullptr)
   , mLayerManager(nullptr)
   , mCrossProcessParent(nullptr)
   , mLayerTree(nullptr)
   , mUpdatedPluginDataAvailable(false)
 {
 }
 
-CompositorParent::LayerTreeState::~LayerTreeState()
+CompositorBridgeParent::LayerTreeState::~LayerTreeState()
 {
   if (mController) {
     mController->Destroy();
   }
 }
 
-typedef map<uint64_t, CompositorParent::LayerTreeState> LayerTreeMap;
+typedef map<uint64_t, CompositorBridgeParent::LayerTreeState> LayerTreeMap;
 static LayerTreeMap sIndirectLayerTrees;
 static StaticAutoPtr<mozilla::Monitor> sIndirectLayerTreesLock;
 
 static void EnsureLayerTreeMapReady()
 {
   MOZ_ASSERT(NS_IsMainThread());
   if (!sIndirectLayerTreesLock) {
     sIndirectLayerTreesLock = new Monitor("IndirectLayerTree");
     mozilla::ClearOnShutdown(&sIndirectLayerTreesLock);
   }
 }
 
 template <typename Lambda>
 inline void
-CompositorParent::ForEachIndirectLayerTree(const Lambda& aCallback)
+CompositorBridgeParent::ForEachIndirectLayerTree(const Lambda& aCallback)
 {
   sIndirectLayerTreesLock->AssertCurrentThreadOwns();
   for (auto it = sIndirectLayerTrees.begin(); it != sIndirectLayerTrees.end(); it++) {
     LayerTreeState* state = &it->second;
     if (state->mParent == this) {
       aCallback(state, it->first);
     }
   }
@@ -147,17 +147,17 @@ CompositorParent::ForEachIndirectLayerTr
 
 /**
   * A global map referencing each compositor by ID.
   *
   * This map is used by the ImageBridge protocol to trigger
   * compositions without having to keep references to the
   * compositor
   */
-typedef map<uint64_t,CompositorParent*> CompositorMap;
+typedef map<uint64_t,CompositorBridgeParent*> CompositorMap;
 static CompositorMap* sCompositorMap;
 
 static void CreateCompositorMap()
 {
   MOZ_ASSERT(!sCompositorMap);
   sCompositorMap = new CompositorMap;
 }
 
@@ -299,18 +299,18 @@ CompositorVsyncScheduler::Observer::Noti
 
 void
 CompositorVsyncScheduler::Observer::Destroy()
 {
   MutexAutoLock lock(mMutex);
   mOwner = nullptr;
 }
 
-CompositorVsyncScheduler::CompositorVsyncScheduler(CompositorParent* aCompositorParent, nsIWidget* aWidget)
-  : mCompositorParent(aCompositorParent)
+CompositorVsyncScheduler::CompositorVsyncScheduler(CompositorBridgeParent* aCompositorBridgeParent, nsIWidget* aWidget)
+  : mCompositorBridgeParent(aCompositorBridgeParent)
   , mLastCompose(TimeStamp::Now())
   , mIsObservingVsync(false)
   , mNeedsComposite(0)
   , mVsyncNotificationsSkipped(0)
   , mCurrentCompositeTaskMonitor("CurrentCompositeTaskMonitor")
   , mCurrentCompositeTask(nullptr)
   , mSetNeedsCompositeMonitor("SetNeedsCompositeMonitor")
   , mSetNeedsCompositeTask(nullptr)
@@ -341,28 +341,28 @@ CompositorVsyncScheduler::CompositorVsyn
                     gfxPlatform::IsInLayoutAsapMode();
 }
 
 CompositorVsyncScheduler::~CompositorVsyncScheduler()
 {
   MOZ_ASSERT(!mIsObservingVsync);
   MOZ_ASSERT(!mVsyncObserver);
   // The CompositorVsyncDispatcher is cleaned up before this in the nsBaseWidget, which stops vsync listeners
-  mCompositorParent = nullptr;
+  mCompositorBridgeParent = nullptr;
   mCompositorVsyncDispatcher = nullptr;
 }
 
 #ifdef MOZ_WIDGET_GONK
 #if ANDROID_VERSION >= 19
 void
 CompositorVsyncScheduler::SetDisplay(bool aDisplayEnable)
 {
   // SetDisplay() is usually called from nsScreenManager at main thread. Post
   // to compositor thread if needs.
-  if (!CompositorParent::IsInCompositorThread()) {
+  if (!CompositorBridgeParent::IsInCompositorThread()) {
     MOZ_ASSERT(NS_IsMainThread());
     MonitorAutoLock lock(mSetDisplayMonitor);
     mSetDisplayTask = NewRunnableMethod(this,
                                         &CompositorVsyncScheduler::SetDisplay,
                                         aDisplayEnable);
     ScheduleTask(mSetDisplayTask, 0);
     return;
   } else {
@@ -379,34 +379,34 @@ CompositorVsyncScheduler::SetDisplay(boo
     CancelCurrentSetNeedsCompositeTask();
     CancelCurrentCompositeTask();
   }
 }
 
 void
 CompositorVsyncScheduler::CancelSetDisplayTask()
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   MonitorAutoLock lock(mSetDisplayMonitor);
   if (mSetDisplayTask) {
     mSetDisplayTask->Cancel();
     mSetDisplayTask = nullptr;
   }
 
   // CancelSetDisplayTask is only be called in clean-up process, so
   // mDisplayEnabled could be false there.
   mDisplayEnabled = false;
 }
 #endif //ANDROID_VERSION >= 19
 #endif //MOZ_WIDGET_GONK
 
 void
 CompositorVsyncScheduler::Destroy()
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   UnobserveVsync();
   mVsyncObserver->Destroy();
   mVsyncObserver = nullptr;
 
 #ifdef MOZ_WIDGET_GONK
 #if ANDROID_VERSION >= 19
   CancelSetDisplayTask();
 #endif
@@ -426,17 +426,17 @@ CompositorVsyncScheduler::PostCompositeT
                                               aCompositeTimestamp);
     ScheduleTask(mCurrentCompositeTask, 0);
   }
 }
 
 void
 CompositorVsyncScheduler::ScheduleComposition()
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   if (mAsapScheduling) {
     // Used only for performance testing purposes
     PostCompositeTask(TimeStamp::Now());
 #ifdef MOZ_WIDGET_ANDROID
   } else if (mNeedsComposite >= 2 && mIsObservingVsync) {
     // uh-oh, we already requested a composite at least twice so far, and a
     // composite hasn't happened yet. It is possible that the vsync observation
     // is blocked on the main thread, so let's just composite ASAP and not
@@ -448,17 +448,17 @@ CompositorVsyncScheduler::ScheduleCompos
   } else {
     SetNeedsComposite();
   }
 }
 
 void
 CompositorVsyncScheduler::CancelCurrentSetNeedsCompositeTask()
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   MonitorAutoLock lock(mSetNeedsCompositeMonitor);
   if (mSetNeedsCompositeTask) {
     mSetNeedsCompositeTask->Cancel();
     mSetNeedsCompositeTask = nullptr;
   }
   mNeedsComposite = 0;
 }
 
@@ -467,17 +467,17 @@ CompositorVsyncScheduler::CancelCurrentS
  * If a composite takes 17 ms, do we composite ASAP or wait until next vsync?
  * If a layer transaction comes after vsync, do we composite ASAP or wait until
  * next vsync?
  * How many skipped vsync events until we stop listening to vsync events?
  */
 void
 CompositorVsyncScheduler::SetNeedsComposite()
 {
-  if (!CompositorParent::IsInCompositorThread()) {
+  if (!CompositorBridgeParent::IsInCompositorThread()) {
     MonitorAutoLock lock(mSetNeedsCompositeMonitor);
     mSetNeedsCompositeTask = NewRunnableMethod(this,
                                               &CompositorVsyncScheduler::SetNeedsComposite);
     ScheduleTask(mSetNeedsCompositeTask, 0);
     return;
   } else {
     MonitorAutoLock lock(mSetNeedsCompositeMonitor);
     mSetNeedsCompositeTask = nullptr;
@@ -497,37 +497,37 @@ CompositorVsyncScheduler::SetNeedsCompos
     ObserveVsync();
   }
 }
 
 bool
 CompositorVsyncScheduler::NotifyVsync(TimeStamp aVsyncTimestamp)
 {
   // Called from the vsync dispatch thread
-  MOZ_ASSERT(!CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(!CompositorBridgeParent::IsInCompositorThread());
   MOZ_ASSERT(!NS_IsMainThread());
   PostCompositeTask(aVsyncTimestamp);
   return true;
 }
 
 void
 CompositorVsyncScheduler::CancelCurrentCompositeTask()
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread() || NS_IsMainThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread() || NS_IsMainThread());
   MonitorAutoLock lock(mCurrentCompositeTaskMonitor);
   if (mCurrentCompositeTask) {
     mCurrentCompositeTask->Cancel();
     mCurrentCompositeTask = nullptr;
   }
 }
 
 void
 CompositorVsyncScheduler::Composite(TimeStamp aVsyncTimestamp)
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   {
     MonitorAutoLock lock(mCurrentCompositeTaskMonitor);
     mCurrentCompositeTask = nullptr;
   }
 
   if ((aVsyncTimestamp < mLastCompose) && !mAsapScheduling) {
     // We can sometimes get vsync timestamps that are in the past
     // compared to the last compose with force composites.
@@ -560,78 +560,78 @@ CompositorVsyncScheduler::OnForceCompose
    * where we receive many sync RecvFlushComposites. We also get vsync notifications which
    * will increment mVsyncNotificationsSkipped because a composite just occurred. After
    * enough vsyncs and RecvFlushComposites occurred, we will disable vsync. Then at the next
    * ScheduleComposite, we will enable vsync, then get a RecvFlushComposite, which will
    * force us to unobserve vsync again. On some platforms, enabling/disabling vsync is not
    * free and this oscillating behavior causes a performance hit. In order to avoid this problem,
    * we reset the mVsyncNotificationsSkipped counter to keep vsync enabled.
    */
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   mVsyncNotificationsSkipped = 0;
 }
 
 void
 CompositorVsyncScheduler::ForceComposeToTarget(gfx::DrawTarget* aTarget, const IntRect* aRect)
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   OnForceComposeToTarget();
   mLastCompose = TimeStamp::Now();
   ComposeToTarget(aTarget, aRect);
 }
 
 bool
 CompositorVsyncScheduler::NeedsComposite()
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   return mNeedsComposite;
 }
 
 void
 CompositorVsyncScheduler::ObserveVsync()
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   mCompositorVsyncDispatcher->SetCompositorVsyncObserver(mVsyncObserver);
   mIsObservingVsync = true;
 }
 
 void
 CompositorVsyncScheduler::UnobserveVsync()
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   mCompositorVsyncDispatcher->SetCompositorVsyncObserver(nullptr);
   mIsObservingVsync = false;
 }
 
 void
 CompositorVsyncScheduler::DispatchTouchEvents(TimeStamp aVsyncTimestamp)
 {
 #ifdef MOZ_WIDGET_GONK
   GeckoTouchDispatcher::GetInstance()->NotifyVsync(aVsyncTimestamp);
 #endif
 }
 
 void
 CompositorVsyncScheduler::DispatchVREvents(TimeStamp aVsyncTimestamp)
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
 
   VRManager* vm = VRManager::Get();
   vm->NotifyVsync(aVsyncTimestamp);
 }
 
-void CompositorParent::StartUp()
+void CompositorBridgeParent::StartUp()
 {
   MOZ_ASSERT(NS_IsMainThread(), "Should be on the main Thread!");
   MOZ_ASSERT(!sCompositorThreadHolder, "The compositor thread has already been started!");
 
   sCompositorThreadHolder = new CompositorThreadHolder();
 }
 
-void CompositorParent::ShutDown()
+void CompositorBridgeParent::ShutDown()
 {
   MOZ_ASSERT(NS_IsMainThread(), "Should be on the main Thread!");
   MOZ_ASSERT(sCompositorThreadHolder, "The compositor thread has already been shut down!");
 
   ReleaseImageBridgeParentSingleton();
   ReleaseVRManagerParentSingleton();
   MediaSystemResourceService::Shutdown();
 
@@ -639,48 +639,48 @@ void CompositorParent::ShutDown()
 
   // No locking is needed around sFinishedCompositorShutDown because it is only
   // ever accessed on the main thread.
   while (!sFinishedCompositorShutDown) {
     NS_ProcessNextEvent(nullptr, true);
   }
 }
 
-MessageLoop* CompositorParent::CompositorLoop()
+MessageLoop* CompositorBridgeParent::CompositorLoop()
 {
   return CompositorThread() ? CompositorThread()->message_loop() : nullptr;
 }
 
 void
 CompositorVsyncScheduler::ScheduleTask(CancelableTask* aTask, int aTime)
 {
-  MOZ_ASSERT(CompositorParent::CompositorLoop());
+  MOZ_ASSERT(CompositorBridgeParent::CompositorLoop());
   MOZ_ASSERT(aTime >= 0);
-  CompositorParent::CompositorLoop()->PostDelayedTask(FROM_HERE, aTask, aTime);
+  CompositorBridgeParent::CompositorLoop()->PostDelayedTask(FROM_HERE, aTask, aTime);
 }
 
 void
 CompositorVsyncScheduler::ResumeComposition()
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   mLastCompose = TimeStamp::Now();
   ComposeToTarget(nullptr);
 }
 
 void
 CompositorVsyncScheduler::ComposeToTarget(gfx::DrawTarget* aTarget, const IntRect* aRect)
 {
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
-  MOZ_ASSERT(mCompositorParent);
-  mCompositorParent->CompositeToTarget(aTarget, aRect);
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
+  MOZ_ASSERT(mCompositorBridgeParent);
+  mCompositorBridgeParent->CompositeToTarget(aTarget, aRect);
 }
 
-CompositorParent::CompositorParent(nsIWidget* aWidget,
-                                   bool aUseExternalSurfaceSize,
-                                   int aSurfaceWidth, int aSurfaceHeight)
+CompositorBridgeParent::CompositorBridgeParent(nsIWidget* aWidget,
+                                               bool aUseExternalSurfaceSize,
+                                               int aSurfaceWidth, int aSurfaceHeight)
   : mWidget(aWidget)
   , mIsTesting(false)
   , mPendingTransaction(0)
   , mPaused(false)
   , mUseExternalSurfaceSize(aUseExternalSurfaceSize)
   , mEGLSurfaceSize(aSurfaceWidth, aSurfaceHeight)
   , mPauseCompositionMonitor("PauseCompositionMonitor")
   , mResumeCompositionMonitor("ResumeCompositionMonitor")
@@ -694,18 +694,18 @@ CompositorParent::CompositorParent(nsIWi
   , mLastPluginUpdateLayerTreeId(0)
   , mPluginUpdateResponsePending(false)
   , mDeferPluginWindows(false)
   , mPluginWindowsHidden(false)
 #endif
 {
   MOZ_ASSERT(NS_IsMainThread());
   MOZ_ASSERT(CompositorThread(),
-             "The compositor thread must be Initialized before instanciating a CompositorParent.");
-  MOZ_COUNT_CTOR(CompositorParent);
+             "The compositor thread must be Initialized before instanciating a CompositorBridgeParent.");
+  MOZ_COUNT_CTOR(CompositorBridgeParent);
   mCompositorID = 0;
   // FIXME: This holds on the the fact that right now the only thing that
   // can destroy this instance is initialized on the compositor thread after
   // this task has been processed.
   MOZ_ASSERT(CompositorLoop());
   CompositorLoop()->PostTask(FROM_HERE, NewRunnableFunction(&AddCompositor,
                                                           this, &mCompositorID));
 
@@ -724,38 +724,38 @@ CompositorParent::CompositorParent(nsIWi
     mApzcTreeManager = new APZCTreeManager();
   }
 
   mCompositorScheduler = new CompositorVsyncScheduler(this, aWidget);
   LayerScope::SetPixelScale(mWidget->GetDefaultScale().scale);
 }
 
 bool
-CompositorParent::IsInCompositorThread()
+CompositorBridgeParent::IsInCompositorThread()
 {
   return CompositorThread() && CompositorThread()->thread_id() == PlatformThread::CurrentId();
 }
 
 uint64_t
-CompositorParent::RootLayerTreeId()
+CompositorBridgeParent::RootLayerTreeId()
 {
   return mRootLayerTreeID;
 }
 
-CompositorParent::~CompositorParent()
+CompositorBridgeParent::~CompositorBridgeParent()
 {
   MOZ_ASSERT(NS_IsMainThread());
-  MOZ_COUNT_DTOR(CompositorParent);
+  MOZ_COUNT_DTOR(CompositorBridgeParent);
 }
 
 void
-CompositorParent::Destroy()
+CompositorBridgeParent::Destroy()
 {
   MOZ_ASSERT(ManagedPLayerTransactionParent().Count() == 0,
-             "CompositorParent destroyed before managed PLayerTransactionParent");
+             "CompositorBridgeParent destroyed before managed PLayerTransactionParent");
 
   MOZ_ASSERT(mPaused); // Ensure RecvWillStop was called
   // Ensure that the layer manager is destructed on the compositor thread.
   mLayerManager = nullptr;
   if (mCompositor) {
     mCompositor->Destroy();
   }
   mCompositor = nullptr;
@@ -769,215 +769,215 @@ CompositorParent::Destroy()
     MonitorAutoLock lock(*sIndirectLayerTreesLock);
     sIndirectLayerTrees.erase(mRootLayerTreeID);
   }
 
   mCompositorScheduler->Destroy();
 }
 
 void
-CompositorParent::ForceIsFirstPaint()
+CompositorBridgeParent::ForceIsFirstPaint()
 {
   mCompositionManager->ForceIsFirstPaint();
 }
 
 bool
-CompositorParent::RecvWillStop()
+CompositorBridgeParent::RecvWillStop()
 {
   mPaused = true;
   RemoveCompositor(mCompositorID);
 
-  // Ensure that the layer manager is destroyed before CompositorChild.
+  // Ensure that the layer manager is destroyed before CompositorBridgeChild.
   if (mLayerManager) {
     MonitorAutoLock lock(*sIndirectLayerTreesLock);
     ForEachIndirectLayerTree([this] (LayerTreeState* lts, uint64_t) -> void {
       mLayerManager->ClearCachedResources(lts->mRoot);
       lts->mLayerManager = nullptr;
       lts->mParent = nullptr;
     });
     mLayerManager->Destroy();
     mLayerManager = nullptr;
     mCompositionManager = nullptr;
   }
 
   return true;
 }
 
-void CompositorParent::DeferredDestroy()
+void CompositorBridgeParent::DeferredDestroy()
 {
   MOZ_ASSERT(!NS_IsMainThread());
   MOZ_ASSERT(mCompositorThreadHolder);
   mCompositorThreadHolder = nullptr;
   Release();
 }
 
 bool
-CompositorParent::RecvStop()
+CompositorBridgeParent::RecvStop()
 {
   Destroy();
   // There are chances that the ref count reaches zero on the main thread shortly
   // after this function returns while some ipdl code still needs to run on
   // this thread.
   // We must keep the compositor parent alive untill the code handling message
   // reception is finished on this thread.
   this->AddRef(); // Corresponds to DeferredDestroy's Release
   MessageLoop::current()->PostTask(FROM_HERE,
-                                   NewRunnableMethod(this,&CompositorParent::DeferredDestroy));
+                                   NewRunnableMethod(this,&CompositorBridgeParent::DeferredDestroy));
   return true;
 }
 
 bool
-CompositorParent::RecvPause()
+CompositorBridgeParent::RecvPause()
 {
   PauseComposition();
   return true;
 }
 
 bool
-CompositorParent::RecvResume()
+CompositorBridgeParent::RecvResume()
 {
   ResumeComposition();
   return true;
 }
 
 bool
-CompositorParent::RecvMakeSnapshot(const SurfaceDescriptor& aInSnapshot,
-                                   const gfx::IntRect& aRect)
+CompositorBridgeParent::RecvMakeSnapshot(const SurfaceDescriptor& aInSnapshot,
+                                         const gfx::IntRect& aRect)
 {
   RefPtr<DrawTarget> target = GetDrawTargetForDescriptor(aInSnapshot, gfx::BackendType::CAIRO);
   MOZ_ASSERT(target);
   if (!target) {
     // We kill the content process rather than have it continue with an invalid
     // snapshot, that may be too harsh and we could decide to return some sort
     // of error to the child process and let it deal with it...
     return false;
   }
   ForceComposeToTarget(target, &aRect);
   return true;
 }
 
 bool
-CompositorParent::RecvMakeWidgetSnapshot(const SurfaceDescriptor& aInSnapshot)
+CompositorBridgeParent::RecvMakeWidgetSnapshot(const SurfaceDescriptor& aInSnapshot)
 {
   if (!mCompositor || !mCompositor->GetWidget()) {
     return false;
   }
 
   RefPtr<DrawTarget> target = GetDrawTargetForDescriptor(aInSnapshot, gfx::BackendType::CAIRO);
   MOZ_ASSERT(target);
   if (!target) {
     return false;
   }
   mCompositor->GetWidget()->CaptureWidgetOnScreen(target);
   return true;
 }
 
 bool
-CompositorParent::RecvFlushRendering()
+CompositorBridgeParent::RecvFlushRendering()
 {
   if (mCompositorScheduler->NeedsComposite())
   {
     CancelCurrentCompositeTask();
     ForceComposeToTarget(nullptr);
   }
   return true;
 }
 
 bool
-CompositorParent::RecvForcePresent()
+CompositorBridgeParent::RecvForcePresent()
 {
   // During the shutdown sequence mLayerManager may be null
   if (mLayerManager) {
     mLayerManager->ForcePresent();
   }
   return true;
 }
 
 bool
-CompositorParent::RecvGetTileSize(int32_t* aWidth, int32_t* aHeight)
+CompositorBridgeParent::RecvGetTileSize(int32_t* aWidth, int32_t* aHeight)
 {
   *aWidth = gfxPlatform::GetPlatform()->GetTileWidth();
   *aHeight = gfxPlatform::GetPlatform()->GetTileHeight();
   return true;
 }
 
 bool
-CompositorParent::RecvNotifyRegionInvalidated(const nsIntRegion& aRegion)
+CompositorBridgeParent::RecvNotifyRegionInvalidated(const nsIntRegion& aRegion)
 {
   if (mLayerManager) {
     mLayerManager->AddInvalidRegion(aRegion);
   }
   return true;
 }
 
 void
-CompositorParent::Invalidate()
+CompositorBridgeParent::Invalidate()
 {
   if (mLayerManager && mLayerManager->GetRoot()) {
     mLayerManager->AddInvalidRegion(
                                     mLayerManager->GetRoot()->GetLocalVisibleRegion().ToUnknownRegion().GetBounds());
   }
 }
 
 bool
-CompositorParent::RecvStartFrameTimeRecording(const int32_t& aBufferSize, uint32_t* aOutStartIndex)
+CompositorBridgeParent::RecvStartFrameTimeRecording(const int32_t& aBufferSize, uint32_t* aOutStartIndex)
 {
   if (mLayerManager) {
     *aOutStartIndex = mLayerManager->StartFrameTimeRecording(aBufferSize);
   } else {
     *aOutStartIndex = 0;
   }
   return true;
 }
 
 bool
-CompositorParent::RecvStopFrameTimeRecording(const uint32_t& aStartIndex,
-                                             InfallibleTArray<float>* intervals)
+CompositorBridgeParent::RecvStopFrameTimeRecording(const uint32_t& aStartIndex,
+                                                   InfallibleTArray<float>* intervals)
 {
   if (mLayerManager) {
     mLayerManager->StopFrameTimeRecording(aStartIndex, *intervals);
   }
   return true;
 }
 
 bool
-CompositorParent::RecvClearApproximatelyVisibleRegions(const uint64_t& aLayersId,
-                                                       const uint32_t& aPresShellId)
+CompositorBridgeParent::RecvClearApproximatelyVisibleRegions(const uint64_t& aLayersId,
+                                                            const uint32_t& aPresShellId)
 {
   ClearApproximatelyVisibleRegions(aLayersId, Some(aPresShellId));
   return true;
 }
 
 void
-CompositorParent::ClearApproximatelyVisibleRegions(const uint64_t& aLayersId,
-                                                   const Maybe<uint32_t>& aPresShellId)
+CompositorBridgeParent::ClearApproximatelyVisibleRegions(const uint64_t& aLayersId,
+                                                         const Maybe<uint32_t>& aPresShellId)
 {
   if (mLayerManager) {
     mLayerManager->ClearApproximatelyVisibleRegions(aLayersId, aPresShellId);
 
     // We need to recomposite to update the minimap.
     ScheduleComposition();
   }
 }
 
 bool
-CompositorParent::RecvNotifyApproximatelyVisibleRegion(const ScrollableLayerGuid& aGuid,
-                                                       const CSSIntRegion& aRegion)
+CompositorBridgeParent::RecvNotifyApproximatelyVisibleRegion(const ScrollableLayerGuid& aGuid,
+                                                             const CSSIntRegion& aRegion)
 {
   if (mLayerManager) {
     mLayerManager->UpdateApproximatelyVisibleRegion(aGuid, aRegion);
 
     // We need to recomposite to update the minimap.
     ScheduleComposition();
   }
   return true;
 }
 
 void
-CompositorParent::ActorDestroy(ActorDestroyReason why)
+CompositorBridgeParent::ActorDestroy(ActorDestroyReason why)
 {
   CancelCurrentCompositeTask();
   if (mForceCompositionTask) {
     mForceCompositionTask->Cancel();
     mForceCompositionTask = nullptr;
   }
   mPaused = true;
   RemoveCompositor(mCompositorID);
@@ -991,33 +991,33 @@ CompositorParent::ActorDestroy(ActorDest
     }
     mCompositionManager = nullptr;
     mCompositor = nullptr;
   }
 }
 
 
 void
-CompositorParent::ScheduleRenderOnCompositorThread()
+CompositorBridgeParent::ScheduleRenderOnCompositorThread()
 {
-  CancelableTask *renderTask = NewRunnableMethod(this, &CompositorParent::ScheduleComposition);
+  CancelableTask *renderTask = NewRunnableMethod(this, &CompositorBridgeParent::ScheduleComposition);
   MOZ_ASSERT(CompositorLoop());
   CompositorLoop()->PostTask(FROM_HERE, renderTask);
 }
 
 void
-CompositorParent::InvalidateOnCompositorThread()
+CompositorBridgeParent::InvalidateOnCompositorThread()
 {
-  CancelableTask *renderTask = NewRunnableMethod(this, &CompositorParent::Invalidate);
+  CancelableTask *renderTask = NewRunnableMethod(this, &CompositorBridgeParent::Invalidate);
   MOZ_ASSERT(CompositorLoop());
   CompositorLoop()->PostTask(FROM_HERE, renderTask);
 }
 
 void
-CompositorParent::PauseComposition()
+CompositorBridgeParent::PauseComposition()
 {
   MOZ_ASSERT(IsInCompositorThread(),
              "PauseComposition() can only be called on the compositor thread");
 
   MonitorAutoLock lock(mPauseCompositionMonitor);
 
   if (!mPaused) {
     mPaused = true;
@@ -1028,134 +1028,134 @@ CompositorParent::PauseComposition()
     DidComposite(now, now);
   }
 
   // if anyone's waiting to make sure that composition really got paused, tell them
   lock.NotifyAll();
 }
 
 void
-CompositorParent::ResumeComposition()
+CompositorBridgeParent::ResumeComposition()
 {
   MOZ_ASSERT(IsInCompositorThread(),
              "ResumeComposition() can only be called on the compositor thread");
 
   MonitorAutoLock lock(mResumeCompositionMonitor);
 
   if (!mCompositor->Resume()) {
 #ifdef MOZ_WIDGET_ANDROID
     // We can't get a surface. This could be because the activity changed between
     // the time resume was scheduled and now.
-    __android_log_print(ANDROID_LOG_INFO, "CompositorParent", "Unable to renew compositor surface; remaining in paused state");
+    __android_log_print(ANDROID_LOG_INFO, "CompositorBridgeParent", "Unable to renew compositor surface; remaining in paused state");
 #endif
     lock.NotifyAll();
     return;
   }
 
   mPaused = false;
 
   mCompositorScheduler->ResumeComposition();
 
   // if anyone's waiting to make sure that composition really got resumed, tell them
   lock.NotifyAll();
 }
 
 void
-CompositorParent::ForceComposition()
+CompositorBridgeParent::ForceComposition()
 {
   // Cancel the orientation changed state to force composition
   mForceCompositionTask = nullptr;
   ScheduleRenderOnCompositorThread();
 }
 
 void
-CompositorParent::CancelCurrentCompositeTask()
+CompositorBridgeParent::CancelCurrentCompositeTask()
 {
   mCompositorScheduler->CancelCurrentCompositeTask();
 }
 
 void
-CompositorParent::SetEGLSurfaceSize(int width, int height)
+CompositorBridgeParent::SetEGLSurfaceSize(int width, int height)
 {
   NS_ASSERTION(mUseExternalSurfaceSize, "Compositor created without UseExternalSurfaceSize provided");
   mEGLSurfaceSize.SizeTo(width, height);
   if (mCompositor) {
     mCompositor->SetDestinationSurfaceSize(gfx::IntSize(mEGLSurfaceSize.width, mEGLSurfaceSize.height));
   }
 }
 
 void
-CompositorParent::ResumeCompositionAndResize(int width, int height)
+CompositorBridgeParent::ResumeCompositionAndResize(int width, int height)
 {
   SetEGLSurfaceSize(width, height);
   ResumeComposition();
 }
 
 /*
  * This will execute a pause synchronously, waiting to make sure that the compositor
  * really is paused.
  */
 void
-CompositorParent::SchedulePauseOnCompositorThread()
+CompositorBridgeParent::SchedulePauseOnCompositorThread()
 {
   MonitorAutoLock lock(mPauseCompositionMonitor);
 
   CancelableTask *pauseTask = NewRunnableMethod(this,
-                                                &CompositorParent::PauseComposition);
+                                                &CompositorBridgeParent::PauseComposition);
   MOZ_ASSERT(CompositorLoop());
   CompositorLoop()->PostTask(FROM_HERE, pauseTask);
 
   // Wait until the pause has actually been processed by the compositor thread
   lock.Wait();
 }
 
 bool
-CompositorParent::ScheduleResumeOnCompositorThread()
+CompositorBridgeParent::ScheduleResumeOnCompositorThread()
 {
   MonitorAutoLock lock(mResumeCompositionMonitor);
 
   CancelableTask *resumeTask =
-    NewRunnableMethod(this, &CompositorParent::ResumeComposition);
+    NewRunnableMethod(this, &CompositorBridgeParent::ResumeComposition);
   MOZ_ASSERT(CompositorLoop());
   CompositorLoop()->PostTask(FROM_HERE, resumeTask);
 
   // Wait until the resume has actually been processed by the compositor thread
   lock.Wait();
 
   return !mPaused;
 }
 
 bool
-CompositorParent::ScheduleResumeOnCompositorThread(int width, int height)
+CompositorBridgeParent::ScheduleResumeOnCompositorThread(int width, int height)
 {
   MonitorAutoLock lock(mResumeCompositionMonitor);
 
   CancelableTask *resumeTask =
-    NewRunnableMethod(this, &CompositorParent::ResumeCompositionAndResize, width, height);
+    NewRunnableMethod(this, &CompositorBridgeParent::ResumeCompositionAndResize, width, height);
   MOZ_ASSERT(CompositorLoop());
   CompositorLoop()->PostTask(FROM_HERE, resumeTask);
 
   // Wait until the resume has actually been processed by the compositor thread
   lock.Wait();
 
   return !mPaused;
 }
 
 void
-CompositorParent::ScheduleTask(CancelableTask* task, int time)
+CompositorBridgeParent::ScheduleTask(CancelableTask* task, int time)
 {
   if (time == 0) {
     MessageLoop::current()->PostTask(FROM_HERE, task);
   } else {
     MessageLoop::current()->PostDelayedTask(FROM_HERE, task, time);
   }
 }
 
 void
-CompositorParent::NotifyShadowTreeTransaction(uint64_t aId, bool aIsFirstPaint,
+CompositorBridgeParent::NotifyShadowTreeTransaction(uint64_t aId, bool aIsFirstPaint,
     bool aScheduleComposite, uint32_t aPaintSequenceNumber,
     bool aIsRepeatTransaction)
 {
   if (mApzcTreeManager &&
       !aIsRepeatTransaction &&
       mLayerManager &&
       mLayerManager->GetRoot()) {
     AutoResolveRefLayers resolve(mCompositionManager);
@@ -1165,30 +1165,30 @@ CompositorParent::NotifyShadowTreeTransa
     mLayerManager->NotifyShadowTreeTransaction();
   }
   if (aScheduleComposite) {
     ScheduleComposition();
   }
 }
 
 void
-CompositorParent::ScheduleComposition()
+CompositorBridgeParent::ScheduleComposition()
 {
   MOZ_ASSERT(IsInCompositorThread());
   if (mPaused) {
     return;
   }
 
   mCompositorScheduler->ScheduleComposition();
 }
 
 // Go down the composite layer tree, setting properties to match their
 // content-side counterparts.
 /* static */ void
-CompositorParent::SetShadowProperties(Layer* aLayer)
+CompositorBridgeParent::SetShadowProperties(Layer* aLayer)
 {
   if (Layer* maskLayer = aLayer->GetMaskLayer()) {
     SetShadowProperties(maskLayer);
   }
   for (size_t i = 0; i < aLayer->GetAncestorMaskLayerCount(); i++) {
     SetShadowProperties(aLayer->GetAncestorMaskLayerAt(i));
   }
 
@@ -1203,20 +1203,20 @@ CompositorParent::SetShadowProperties(La
 
   for (Layer* child = aLayer->GetFirstChild();
       child; child = child->GetNextSibling()) {
     SetShadowProperties(child);
   }
 }
 
 void
-CompositorParent::CompositeToTarget(DrawTarget* aTarget, const gfx::IntRect* aRect)
+CompositorBridgeParent::CompositeToTarget(DrawTarget* aTarget, const gfx::IntRect* aRect)
 {
   profiler_tracing("Paint", "Composite", TRACING_INTERVAL_START);
-  PROFILER_LABEL("CompositorParent", "Composite",
+  PROFILER_LABEL("CompositorBridgeParent", "Composite",
     js::ProfileEntry::Category::GRAPHICS);
 
   MOZ_ASSERT(IsInCompositorThread(),
              "Composite can only be called on the compositor thread");
   TimeStamp start = TimeStamp::Now();
 
 #ifdef COMPOSITOR_PERFORMANCE_WARNING
   TimeDuration scheduleDelta = TimeStamp::Now() - mCompositorScheduler->GetExpectedComposeStartTime();
@@ -1246,17 +1246,17 @@ CompositorParent::CompositeToTarget(Draw
                                &hasRemoteContent,
                                &pluginsUpdatedFlag);
 
 #if defined(XP_WIN) || defined(MOZ_WIDGET_GTK)
   /*
    * AutoResolveRefLayers handles two tasks related to Windows and Linux
    * plugin window management:
    * 1) calculating if we have remote content in the view. If we do not have
-   * remote content, all plugin windows for this CompositorParent (window)
+   * remote content, all plugin windows for this CompositorBridgeParent (window)
    * can be hidden since we do not support plugins in chrome when running
    * under e10s.
    * 2) Updating plugin position, size, and clip. We do this here while the
    * remote layer tree is hooked up to to chrome layer tree. This is needed
    * since plugin clipping can depend on chrome (for example, due to tab modal
    * prompts). Updates in step 2 are applied via an async ipc message sent
    * to the main thread.
    * Windows specific: The compositor will wait for confirmation that plugin
@@ -1355,75 +1355,75 @@ CompositorParent::CompositeToTarget(Draw
   }
   mCompositor->SetCompositionTime(TimeStamp());
 
   mozilla::Telemetry::AccumulateTimeDelta(mozilla::Telemetry::COMPOSITE_TIME, start);
   profiler_tracing("Paint", "Composite", TRACING_INTERVAL_END);
 }
 
 bool
-CompositorParent::RecvRemotePluginsReady()
+CompositorBridgeParent::RecvRemotePluginsReady()
 {
 #if defined(XP_WIN) || defined(MOZ_WIDGET_GTK)
   mPluginUpdateResponsePending = false;
   ScheduleComposition();
   return true;
 #else
-  NS_NOTREACHED("CompositorParent::RecvRemotePluginsReady calls "
+  NS_NOTREACHED("CompositorBridgeParent::RecvRemotePluginsReady calls "
                 "unexpected on this platform.");
   return false;
 #endif
 }
 
 void
-CompositorParent::ForceComposeToTarget(DrawTarget* aTarget, const gfx::IntRect* aRect)
+CompositorBridgeParent::ForceComposeToTarget(DrawTarget* aTarget, const gfx::IntRect* aRect)
 {
-  PROFILER_LABEL("CompositorParent", "ForceComposeToTarget",
+  PROFILER_LABEL("CompositorBridgeParent", "ForceComposeToTarget",
     js::ProfileEntry::Category::GRAPHICS);
 
   AutoRestore<bool> override(mOverrideComposeReadiness);
   mOverrideComposeReadiness = true;
   mCompositorScheduler->ForceComposeToTarget(aTarget, aRect);
 }
 
 bool
-CompositorParent::CanComposite()
+CompositorBridgeParent::CanComposite()
 {
   return mLayerManager &&
          mLayerManager->GetRoot() &&
          !mPaused;
 }
 
 void
-CompositorParent::ScheduleRotationOnCompositorThread(const TargetConfig& aTargetConfig,
+CompositorBridgeParent::ScheduleRotationOnCompositorThread(const TargetConfig& aTargetConfig,
                                                      bool aIsFirstPaint)
 {
   MOZ_ASSERT(IsInCompositorThread());
 
   if (!aIsFirstPaint &&
       !mCompositionManager->IsFirstPaint() &&
       mCompositionManager->RequiresReorientation(aTargetConfig.orientation())) {
     if (mForceCompositionTask != nullptr) {
       mForceCompositionTask->Cancel();
     }
-    mForceCompositionTask = NewRunnableMethod(this, &CompositorParent::ForceComposition);
+    mForceCompositionTask = NewRunnableMethod(this, &CompositorBridgeParent::ForceComposition);
     ScheduleTask(mForceCompositionTask, gfxPrefs::OrientationSyncMillis());
   }
 }
 
 void
-CompositorParent::ShadowLayersUpdated(LayerTransactionParent* aLayerTree,
-                                      const uint64_t& aTransactionId,
-                                      const TargetConfig& aTargetConfig,
-                                      const InfallibleTArray<PluginWindowData>& aUnused,
-                                      bool aIsFirstPaint,
-                                      bool aScheduleComposite,
-                                      uint32_t aPaintSequenceNumber,
-                                      bool aIsRepeatTransaction,
-                                      int32_t aPaintSyncId)
+CompositorBridgeParent::ShadowLayersUpdated(LayerTransactionParent* aLayerTree,
+                                            const uint64_t& aTransactionId,
+                                            const TargetConfig& aTargetConfig,
+                                            const InfallibleTArray<PluginWindowData>& aUnused,
+                                            bool aIsFirstPaint,
+                                            bool aScheduleComposite,
+                                            uint32_t aPaintSequenceNumber,
+                                            bool aIsRepeatTransaction,
+                                            int32_t aPaintSyncId)
 {
   ScheduleRotationOnCompositorThread(aTargetConfig, aIsFirstPaint);
 
   // Instruct the LayerManager to update its render bounds now. Since all the orientation
   // change, dimension change would be done at the stage, update the size here is free of
   // race condition.
   mLayerManager->UpdateRenderBounds(aTargetConfig.naturalBounds());
   mLayerManager->SetRegionToClear(aTargetConfig.clearRegion());
@@ -1454,24 +1454,24 @@ CompositorParent::ShadowLayersUpdated(La
       TimeStamp now = TimeStamp::Now();
       DidComposite(now, now);
     }
   }
   mLayerManager->NotifyShadowTreeTransaction();
 }
 
 void
-CompositorParent::ForceComposite(LayerTransactionParent* aLayerTree)
+CompositorBridgeParent::ForceComposite(LayerTransactionParent* aLayerTree)
 {
   ScheduleComposition();
 }
 
 bool
-CompositorParent::SetTestSampleTime(LayerTransactionParent* aLayerTree,
-                                    const TimeStamp& aTime)
+CompositorBridgeParent::SetTestSampleTime(LayerTransactionParent* aLayerTree,
+                                          const TimeStamp& aTime)
 {
   if (aTime.IsNull()) {
     return false;
   }
 
   mIsTesting = true;
   mTestTime = aTime;
 
@@ -1489,23 +1489,23 @@ CompositorParent::SetTestSampleTime(Laye
       DidComposite(now, now);
     }
   }
 
   return true;
 }
 
 void
-CompositorParent::LeaveTestMode(LayerTransactionParent* aLayerTree)
+CompositorBridgeParent::LeaveTestMode(LayerTransactionParent* aLayerTree)
 {
   mIsTesting = false;
 }
 
 void
-CompositorParent::ApplyAsyncProperties(LayerTransactionParent* aLayerTree)
+CompositorBridgeParent::ApplyAsyncProperties(LayerTransactionParent* aLayerTree)
 {
   // NOTE: This should only be used for testing. For example, when mIsTesting is
   // true or when called from test-only methods like
   // LayerTransactionParent::RecvGetAnimationTransform.
 
   // Synchronously update the layer tree
   if (aLayerTree->GetRoot()) {
     AutoResolveRefLayers resolve(mCompositionManager);
@@ -1520,46 +1520,46 @@ CompositorParent::ApplyAsyncProperties(L
       // Pretend we composited in case someone is waiting for this event.
       TimeStamp now = TimeStamp::Now();
       DidComposite(now, now);
     }
   }
 }
 
 bool
-CompositorParent::RecvGetFrameUniformity(FrameUniformityData* aOutData)
+CompositorBridgeParent::RecvGetFrameUniformity(FrameUniformityData* aOutData)
 {
   mCompositionManager->GetFrameUniformity(aOutData);
   return true;
 }
 
 bool
-CompositorParent::RecvRequestOverfill()
+CompositorBridgeParent::RecvRequestOverfill()
 {
   uint32_t overfillRatio = mCompositor->GetFillRatio();
   Unused << SendOverfill(overfillRatio);
   return true;
 }
 
 void
-CompositorParent::FlushApzRepaints(const LayerTransactionParent* aLayerTree)
+CompositorBridgeParent::FlushApzRepaints(const LayerTransactionParent* aLayerTree)
 {
   MOZ_ASSERT(mApzcTreeManager);
   uint64_t layersId = aLayerTree->GetId();
   if (layersId == 0) {
     // The request is coming from the parent-process layer tree, so we should
     // use the compositor's root layer tree id.
     layersId = mRootLayerTreeID;
   }
   mApzcTreeManager->FlushApzRepaints(layersId);
 }
 
 void
-CompositorParent::GetAPZTestData(const LayerTransactionParent* aLayerTree,
-                                 APZTestData* aOutData)
+CompositorBridgeParent::GetAPZTestData(const LayerTransactionParent* aLayerTree,
+                                       APZTestData* aOutData)
 {
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   *aOutData = sIndirectLayerTrees[mRootLayerTreeID].mApzTestData;
 }
 
 class NotifyAPZConfirmedTargetTask : public Task
 {
 public:
@@ -1578,46 +1578,46 @@ public:
 
 private:
   RefPtr<APZCTreeManager> mAPZCTM;
   uint64_t mInputBlockId;
   nsTArray<ScrollableLayerGuid> mTargets;
 };
 
 void
-CompositorParent::SetConfirmedTargetAPZC(const LayerTransactionParent* aLayerTree,
+CompositorBridgeParent::SetConfirmedTargetAPZC(const LayerTransactionParent* aLayerTree,
                                          const uint64_t& aInputBlockId,
                                          const nsTArray<ScrollableLayerGuid>& aTargets)
 {
   if (!mApzcTreeManager) {
     return;
   }
   APZThreadUtils::RunOnControllerThread(new NotifyAPZConfirmedTargetTask(
     mApzcTreeManager, aInputBlockId, aTargets));
 }
 
 void
-CompositorParent::InitializeLayerManager(const nsTArray<LayersBackend>& aBackendHints)
+CompositorBridgeParent::InitializeLayerManager(const nsTArray<LayersBackend>& aBackendHints)
 {
   NS_ASSERTION(!mLayerManager, "Already initialised mLayerManager");
   NS_ASSERTION(!mCompositor,   "Already initialised mCompositor");
 
   mCompositor = NewCompositor(aBackendHints);
   if (!mCompositor) {
     return;
   }
 
   mLayerManager = new LayerManagerComposite(mCompositor);
 
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   sIndirectLayerTrees[mRootLayerTreeID].mLayerManager = mLayerManager;
 }
 
 RefPtr<Compositor>
-CompositorParent::NewCompositor(const nsTArray<LayersBackend>& aBackendHints)
+CompositorBridgeParent::NewCompositor(const nsTArray<LayersBackend>& aBackendHints)
 {
   for (size_t i = 0; i < aBackendHints.Length(); ++i) {
     RefPtr<Compositor> compositor;
     if (aBackendHints[i] == LayersBackend::LAYERS_OPENGL) {
       compositor = new CompositorOGL(mWidget,
                                      mEGLSurfaceSize.width,
                                      mEGLSurfaceSize.height,
                                      mUseExternalSurfaceSize);
@@ -1643,19 +1643,19 @@ CompositorParent::NewCompositor(const ns
       return compositor;
     }
   }
 
   return nullptr;
 }
 
 PLayerTransactionParent*
-CompositorParent::AllocPLayerTransactionParent(const nsTArray<LayersBackend>& aBackendHints,
-                                               const uint64_t& aId,
-                                               TextureFactoryIdentifier* aTextureFactoryIdentifier,
+CompositorBridgeParent::AllocPLayerTransactionParent(const nsTArray<LayersBackend>& aBackendHints,
+                                                     const uint64_t& aId,
+                                                     TextureFactoryIdentifier* aTextureFactoryIdentifier,
                                                bool *aSuccess)
 {
   MOZ_ASSERT(aId == 0);
 
   InitializeLayerManager(aBackendHints);
 
   if (!mLayerManager) {
     NS_WARNING("Failed to initialise Compositor");
@@ -1670,69 +1670,69 @@ CompositorParent::AllocPLayerTransaction
 
   *aTextureFactoryIdentifier = mCompositor->GetTextureFactoryIdentifier();
   LayerTransactionParent* p = new LayerTransactionParent(mLayerManager, this, 0);
   p->AddIPDLReference();
   return p;
 }
 
 bool
-CompositorParent::DeallocPLayerTransactionParent(PLayerTransactionParent* actor)
+CompositorBridgeParent::DeallocPLayerTransactionParent(PLayerTransactionParent* actor)
 {
   static_cast<LayerTransactionParent*>(actor)->ReleaseIPDLReference();
   return true;
 }
 
-CompositorParent* CompositorParent::GetCompositor(uint64_t id)
+CompositorBridgeParent* CompositorBridgeParent::GetCompositor(uint64_t id)
 {
   CompositorMap::iterator it = sCompositorMap->find(id);
   return it != sCompositorMap->end() ? it->second : nullptr;
 }
 
-void CompositorParent::AddCompositor(CompositorParent* compositor, uint64_t* outID)
+void CompositorBridgeParent::AddCompositor(CompositorBridgeParent* compositor, uint64_t* outID)
 {
   static uint64_t sNextID = 1;
 
   ++sNextID;
   (*sCompositorMap)[sNextID] = compositor;
   *outID = sNextID;
 }
 
-CompositorParent* CompositorParent::RemoveCompositor(uint64_t id)
+CompositorBridgeParent* CompositorBridgeParent::RemoveCompositor(uint64_t id)
 {
   CompositorMap::iterator it = sCompositorMap->find(id);
   if (it == sCompositorMap->end()) {
     return nullptr;
   }
-  CompositorParent *retval = it->second;
+  CompositorBridgeParent *retval = it->second;
   sCompositorMap->erase(it);
   return retval;
 }
 
 bool
-CompositorParent::RecvNotifyChildCreated(const uint64_t& child)
+CompositorBridgeParent::RecvNotifyChildCreated(const uint64_t& child)
 {
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   NotifyChildCreated(child);
   return true;
 }
 
 void
-CompositorParent::NotifyChildCreated(uint64_t aChild)
+CompositorBridgeParent::NotifyChildCreated(uint64_t aChild)
 {
   sIndirectLayerTreesLock->AssertCurrentThreadOwns();
   sIndirectLayerTrees[aChild].mParent = this;
   sIndirectLayerTrees[aChild].mLayerManager = mLayerManager;
 }
 
 /* static */ bool
-CompositorParent::UpdateRemoteContentController(uint64_t aLayersId,
-                                                dom::ContentParent* aContent,
-                                                const dom::TabId& aTabId,
-                                                dom::TabParent* aTopLevel)
+CompositorBridgeParent::UpdateRemoteContentController(uint64_t aLayersId,
+                                                      dom::ContentParent* aContent,
+                                                      const dom::TabId& aTabId,
+                                                      dom::TabParent* aTopLevel)
 {
   MOZ_ASSERT(NS_IsMainThread());
 
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   LayerTreeState& state = sIndirectLayerTrees[aLayersId];
   // RemoteContentController needs to know the layers id and the top level
   // TabParent, so we pass that to its constructor here and then set up the
   // PAPZ protocol by calling SendPAPZConstructor (and pass in the tab id for
@@ -1742,17 +1742,17 @@ CompositorParent::UpdateRemoteContentCon
   if (!aContent->SendPAPZConstructor(controller, aTabId)) {
     return false;
   }
   state.mController = controller;
   return true;
 }
 
 bool
-CompositorParent::RecvAdoptChild(const uint64_t& child)
+CompositorBridgeParent::RecvAdoptChild(const uint64_t& child)
 {
   RefPtr<GeckoContentController> controller;
   {
     MonitorAutoLock lock(*sIndirectLayerTreesLock);
     NotifyChildCreated(child);
     if (sIndirectLayerTrees[child].mLayerTree) {
       sIndirectLayerTrees[child].mLayerTree->mLayerManager = mLayerManager;
     }
@@ -1767,57 +1767,57 @@ CompositorParent::RecvAdoptChild(const u
   // release sIndirectLayerTreesLock first before calling ChildAdopted.
   if (mApzcTreeManager && controller) {
     controller->ChildAdopted();
   }
   return true;
 }
 
 /*static*/ uint64_t
-CompositorParent::AllocateLayerTreeId()
+CompositorBridgeParent::AllocateLayerTreeId()
 {
   MOZ_ASSERT(CompositorLoop());
   MOZ_ASSERT(NS_IsMainThread());
   static uint64_t ids = 0;
   return ++ids;
 }
 
 static void
 EraseLayerState(uint64_t aId)
 {
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
 
   auto iter = sIndirectLayerTrees.find(aId);
   if (iter != sIndirectLayerTrees.end()) {
-    CompositorParent* parent = iter->second.mParent;
+    CompositorBridgeParent* parent = iter->second.mParent;
     if (parent) {
       parent->ClearApproximatelyVisibleRegions(aId, Nothing());
     }
 
     sIndirectLayerTrees.erase(iter);
   }
 }
 
 /*static*/ void
-CompositorParent::DeallocateLayerTreeId(uint64_t aId)
+CompositorBridgeParent::DeallocateLayerTreeId(uint64_t aId)
 {
   MOZ_ASSERT(NS_IsMainThread());
   // Here main thread notifies compositor to remove an element from
   // sIndirectLayerTrees. This removed element might be queried soon.
   // Checking the elements of sIndirectLayerTrees exist or not before using.
   if (!CompositorLoop()) {
     gfxCriticalError() << "Attempting to post to a invalid Compositor Loop";
     return;
   }
   CompositorLoop()->PostTask(FROM_HERE,
                              NewRunnableFunction(&EraseLayerState, aId));
 }
 
 /* static */ void
-CompositorParent::SwapLayerTreeObservers(uint64_t aLayerId, uint64_t aOtherLayerId)
+CompositorBridgeParent::SwapLayerTreeObservers(uint64_t aLayerId, uint64_t aOtherLayerId)
 {
   EnsureLayerTreeMapReady();
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   NS_ASSERTION(sIndirectLayerTrees.find(aLayerId) != sIndirectLayerTrees.end(),
     "SwapLayerTrees missing layer 1");
   NS_ASSERTION(sIndirectLayerTrees.find(aOtherLayerId) != sIndirectLayerTrees.end(),
     "SwapLayerTrees missing layer 2");
   std::swap(sIndirectLayerTrees[aLayerId].mLayerTreeReadyObserver,
@@ -1848,101 +1848,101 @@ ScopedLayerTreeRegistration::ScopedLayer
 
 ScopedLayerTreeRegistration::~ScopedLayerTreeRegistration()
 {
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   sIndirectLayerTrees.erase(mLayersId);
 }
 
 /*static*/ void
-CompositorParent::SetControllerForLayerTree(uint64_t aLayersId,
-                                            GeckoContentController* aController)
+CompositorBridgeParent::SetControllerForLayerTree(uint64_t aLayersId,
+                                                  GeckoContentController* aController)
 {
   // This ref is adopted by UpdateControllerForLayersId().
   aController->AddRef();
   CompositorLoop()->PostTask(FROM_HERE,
                              NewRunnableFunction(&UpdateControllerForLayersId,
                                                  aLayersId,
                                                  aController));
 }
 
 /*static*/ APZCTreeManager*
-CompositorParent::GetAPZCTreeManager(uint64_t aLayersId)
+CompositorBridgeParent::GetAPZCTreeManager(uint64_t aLayersId)
 {
   EnsureLayerTreeMapReady();
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   LayerTreeMap::iterator cit = sIndirectLayerTrees.find(aLayersId);
   if (sIndirectLayerTrees.end() == cit) {
     return nullptr;
   }
   LayerTreeState* lts = &cit->second;
   return (lts->mParent ? lts->mParent->mApzcTreeManager.get() : nullptr);
 }
 
 float
-CompositorParent::ComputeRenderIntegrity()
+CompositorBridgeParent::ComputeRenderIntegrity()
 {
   if (mLayerManager) {
     return mLayerManager->ComputeRenderIntegrity();
   }
 
   return 1.0f;
 }
 
 static void
 InsertVsyncProfilerMarker(TimeStamp aVsyncTimestamp)
 {
 #ifdef MOZ_ENABLE_PROFILER_SPS
-  MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+  MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
   VsyncPayload* payload = new VsyncPayload(aVsyncTimestamp);
   PROFILER_MARKER_PAYLOAD("VsyncTimestamp", payload);
 #endif
 }
 
 /*static */ void
-CompositorParent::PostInsertVsyncProfilerMarker(TimeStamp aVsyncTimestamp)
+CompositorBridgeParent::PostInsertVsyncProfilerMarker(TimeStamp aVsyncTimestamp)
 {
   // Called in the vsync thread
   if (profiler_is_active() && sCompositorThreadHolder) {
     CompositorLoop()->PostTask(FROM_HERE,
       NewRunnableFunction(InsertVsyncProfilerMarker, aVsyncTimestamp));
   }
 }
 
 /* static */ void
-CompositorParent::RequestNotifyLayerTreeReady(uint64_t aLayersId, CompositorUpdateObserver* aObserver)
+CompositorBridgeParent::RequestNotifyLayerTreeReady(uint64_t aLayersId, CompositorUpdateObserver* aObserver)
 {
   EnsureLayerTreeMapReady();
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   sIndirectLayerTrees[aLayersId].mLayerTreeReadyObserver = aObserver;
 }
 
 /* static */ void
-CompositorParent::RequestNotifyLayerTreeCleared(uint64_t aLayersId, CompositorUpdateObserver* aObserver)
+CompositorBridgeParent::RequestNotifyLayerTreeCleared(uint64_t aLayersId, CompositorUpdateObserver* aObserver)
 {
   EnsureLayerTreeMapReady();
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   sIndirectLayerTrees[aLayersId].mLayerTreeClearedObserver = aObserver;
 }
 
 /**
  * This class handles layer updates pushed directly from child processes to
- * the compositor thread. It's associated with a CompositorParent on the
+ * the compositor thread. It's associated with a CompositorBridgeParent on the
  * compositor thread. While it uses the PCompositorBridge protocol to manage
  * these updates, it doesn't actually drive compositing itself. For that it
- * hands off work to the CompositorParent it's associated with.
+ * hands off work to the CompositorBridgeParent it's associated with.
  */
-class CrossProcessCompositorParent final : public PCompositorBridgeParent,
-                                           public ShadowLayersManager
+class CrossProcessCompositorBridgeParent final : public PCompositorBridgeParent,
+                                                 public ShadowLayersManager
 {
-  friend class CompositorParent;
+  friend class CompositorBridgeParent;
 
-  NS_INLINE_DECL_THREADSAFE_REFCOUNTING_WITH_MAIN_THREAD_DESTRUCTION(CrossProcessCompositorParent)
+  NS_INLINE_DECL_THREADSAFE_REFCOUNTING_WITH_MAIN_THREAD_DESTRUCTION(CrossProcessCompositorBridgeParent)
 public:
-  explicit CrossProcessCompositorParent(Transport* aTransport)
+  explicit CrossProcessCompositorBridgeParent(Transport* aTransport)
     : mTransport(aTransport)
     , mNotifyAfterRemotePaint(false)
   {
     MOZ_ASSERT(NS_IsMainThread());
   }
 
   // IToplevelProtocol::CloneToplevel()
   virtual IToplevelProtocol*
@@ -1971,31 +1971,31 @@ public:
   virtual bool RecvForcePresent() override { return true; }
   virtual bool RecvNotifyRegionInvalidated(const nsIntRegion& aRegion) override { return true; }
   virtual bool RecvStartFrameTimeRecording(const int32_t& aBufferSize, uint32_t* aOutStartIndex) override { return true; }
   virtual bool RecvStopFrameTimeRecording(const uint32_t& aStartIndex, InfallibleTArray<float>* intervals) override  { return true; }
 
   virtual bool RecvClearApproximatelyVisibleRegions(const uint64_t& aLayersId,
                                                     const uint32_t& aPresShellId) override
   {
-    CompositorParent* parent;
+    CompositorBridgeParent* parent;
     { // scope lock
       MonitorAutoLock lock(*sIndirectLayerTreesLock);
       parent = sIndirectLayerTrees[aLayersId].mParent;
     }
     if (parent) {
       parent->ClearApproximatelyVisibleRegions(aLayersId, Some(aPresShellId));
     }
     return true;
   }
 
   virtual bool RecvNotifyApproximatelyVisibleRegion(const ScrollableLayerGuid& aGuid,
                                                     const CSSIntRegion& aRegion) override
   {
-    CompositorParent* parent;
+    CompositorBridgeParent* parent;
     { // scope lock
       MonitorAutoLock lock(*sIndirectLayerTreesLock);
       parent = sIndirectLayerTrees[aGuid.mLayersId].mParent;
     }
     if (parent) {
       return parent->RecvNotifyApproximatelyVisibleRegion(aGuid, aRegion);
     }
     return true;
@@ -2012,17 +2012,17 @@ public:
   {
     // Don't support calculating frame uniformity on the child process and
     // this is just a stub for now.
     MOZ_ASSERT(false);
     return true;
   }
 
   /**
-   * Tells this CompositorParent to send a message when the compositor has received the transaction.
+   * Tells this CompositorBridgeParent to send a message when the compositor has received the transaction.
    */
   virtual bool RecvRequestNotifyAfterRemotePaint() override;
 
   virtual PLayerTransactionParent*
     AllocPLayerTransactionParent(const nsTArray<LayersBackend>& aBackendHints,
                                  const uint64_t& aId,
                                  TextureFactoryIdentifier* aTextureFactoryIdentifier,
                                  bool *aSuccess) override;
@@ -2058,89 +2058,89 @@ public:
   void DidComposite(uint64_t aId,
                     TimeStamp& aCompositeStart,
                     TimeStamp& aCompositeEnd);
 
 protected:
   void OnChannelConnected(int32_t pid) override { mCompositorThreadHolder = sCompositorThreadHolder; }
 private:
   // Private destructor, to discourage deletion outside of Release():
-  virtual ~CrossProcessCompositorParent();
+  virtual ~CrossProcessCompositorBridgeParent();
 
   void DeferredDestroy();
 
   // There can be many CPCPs, and IPDL-generated code doesn't hold a
   // reference to top-level actors.  So we hold a reference to
   // ourself.  This is released (deferred) in ActorDestroy().
-  RefPtr<CrossProcessCompositorParent> mSelfRef;
+  RefPtr<CrossProcessCompositorBridgeParent> mSelfRef;
   Transport* mTransport;
 
   RefPtr<CompositorThreadHolder> mCompositorThreadHolder;
   // If true, we should send a RemotePaintIsReady message when the layer transaction
   // is received
   bool mNotifyAfterRemotePaint;
 };
 
 PCompositorBridgeParent*
-CompositorParent::LayerTreeState::CrossProcessPCompositorBridge() const
+CompositorBridgeParent::LayerTreeState::CrossProcessPCompositorBridge() const
 {
   return mCrossProcessParent;
 }
 
 void
-CompositorParent::DidComposite(TimeStamp& aCompositeStart,
-                               TimeStamp& aCompositeEnd)
+CompositorBridgeParent::DidComposite(TimeStamp& aCompositeStart,
+                                     TimeStamp& aCompositeEnd)
 {
   Unused << SendDidComposite(0, mPendingTransaction, aCompositeStart, aCompositeEnd);
   mPendingTransaction = 0;
 
   if (mLayerManager) {
     nsTArray<ImageCompositeNotification> notifications;
     mLayerManager->ExtractImageCompositeNotifications(&notifications);
     if (!notifications.IsEmpty()) {
       Unused << ImageBridgeParent::NotifyImageComposites(notifications);
     }
   }
 
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   ForEachIndirectLayerTree([&] (LayerTreeState* lts, const uint64_t& aLayersId) -> void {
     if (lts->mCrossProcessParent) {
-      CrossProcessCompositorParent* cpcp = lts->mCrossProcessParent;
+      CrossProcessCompositorBridgeParent* cpcp = lts->mCrossProcessParent;
       cpcp->DidComposite(aLayersId, aCompositeStart, aCompositeEnd);
     }
   });
 }
 
 void
-CompositorParent::InvalidateRemoteLayers()
+CompositorBridgeParent::InvalidateRemoteLayers()
 {
   MOZ_ASSERT(CompositorLoop() == MessageLoop::current());
 
   Unused << PCompositorBridgeParent::SendInvalidateLayers(0);
 
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   ForEachIndirectLayerTree([] (LayerTreeState* lts, const uint64_t& aLayersId) -> void {
     if (lts->mCrossProcessParent) {
-      CrossProcessCompositorParent* cpcp = lts->mCrossProcessParent;
+      CrossProcessCompositorBridgeParent* cpcp = lts->mCrossProcessParent;
       Unused << cpcp->SendInvalidateLayers(aLayersId);
     }
   });
 }
 
 bool
-CompositorParent::ResetCompositor(const nsTArray<LayersBackend>& aBackendHints,
-                                  TextureFactoryIdentifier* aOutIdentifier)
+CompositorBridgeParent::ResetCompositor(const nsTArray<LayersBackend>& aBackendHints,
+                                        TextureFactoryIdentifier* aOutIdentifier)
 {
   Maybe<TextureFactoryIdentifier> newIdentifier;
   {
     MonitorAutoLock lock(mResetCompositorMonitor);
 
     CompositorLoop()->PostTask(FROM_HERE,
       NewRunnableMethod(this,
-                        &CompositorParent::ResetCompositorTask,
+                        &CompositorBridgeParent::ResetCompositorTask,
                         aBackendHints,
                         &newIdentifier));
 
     mResetCompositorMonitor.Wait();
   }
 
   if (!newIdentifier) {
     return false;
@@ -2148,18 +2148,18 @@ CompositorParent::ResetCompositor(const 
 
   *aOutIdentifier = newIdentifier.value();
   return true;
 }
 
 // Invoked on the compositor thread. The main thread is waiting on the given
 // monitor.
 void
-CompositorParent::ResetCompositorTask(const nsTArray<LayersBackend>& aBackendHints,
-                                      Maybe<TextureFactoryIdentifier>* aOutNewIdentifier)
+CompositorBridgeParent::ResetCompositorTask(const nsTArray<LayersBackend>& aBackendHints,
+                                            Maybe<TextureFactoryIdentifier>* aOutNewIdentifier)
 {
   // Perform the reset inside a lock, so the main thread can wake up as soon as
   // possible. We notify child processes (if necessary) outside the lock.
   Maybe<TextureFactoryIdentifier> newIdentifier;
   {
     MonitorAutoLock lock(mResetCompositorMonitor);
 
     newIdentifier = ResetCompositorImpl(aBackendHints);
@@ -2174,24 +2174,24 @@ CompositorParent::ResetCompositorTask(co
 
   if (!newIdentifier) {
     // No compositor change; nothing to do.
     return;
   }
 
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   ForEachIndirectLayerTree([&] (LayerTreeState* lts, uint64_t layersId) -> void {
-    if (CrossProcessCompositorParent* cpcp = lts->mCrossProcessParent) {
+    if (CrossProcessCompositorBridgeParent* cpcp = lts->mCrossProcessParent) {
       Unused << cpcp->SendCompositorUpdated(layersId, newIdentifier.value());
     }
   });
 }
 
 Maybe<TextureFactoryIdentifier>
-CompositorParent::ResetCompositorImpl(const nsTArray<LayersBackend>& aBackendHints)
+CompositorBridgeParent::ResetCompositorImpl(const nsTArray<LayersBackend>& aBackendHints)
 {
   if (!mLayerManager) {
     return Nothing();
   }
 
   RefPtr<Compositor> compositor = NewCompositor(aBackendHints);
   if (!compositor) {
     return Nothing();
@@ -2207,31 +2207,31 @@ CompositorParent::ResetCompositorImpl(co
 
   mCompositor = compositor;
   mLayerManager->ChangeCompositor(compositor);
 
   return Some(compositor->GetTextureFactoryIdentifier());
 }
 
 static void
-OpenCompositor(CrossProcessCompositorParent* aCompositor,
+OpenCompositor(CrossProcessCompositorBridgeParent* aCompositor,
                Transport* aTransport, ProcessId aOtherPid,
                MessageLoop* aIOLoop)
 {
   DebugOnly<bool> ok = aCompositor->Open(aTransport, aOtherPid, aIOLoop);
   MOZ_ASSERT(ok);
 }
 
 /*static*/ PCompositorBridgeParent*
-CompositorParent::Create(Transport* aTransport, ProcessId aOtherPid)
+CompositorBridgeParent::Create(Transport* aTransport, ProcessId aOtherPid)
 {
   gfxPlatform::InitLayersIPC();
 
-  RefPtr<CrossProcessCompositorParent> cpcp =
-    new CrossProcessCompositorParent(aTransport);
+  RefPtr<CrossProcessCompositorBridgeParent> cpcp =
+    new CrossProcessCompositorBridgeParent(aTransport);
 
   cpcp->mSelfRef = cpcp;
   CompositorLoop()->PostTask(
     FROM_HERE,
     NewRunnableFunction(OpenCompositor, cpcp.get(),
                         aTransport, aOtherPid, XRE_GetIOMessageLoop()));
   // The return value is just compared to null for success checking,
   // we're not sharing a ref.
@@ -2241,72 +2241,73 @@ CompositorParent::Create(Transport* aTra
 static void
 UpdateIndirectTree(uint64_t aId, Layer* aRoot, const TargetConfig& aTargetConfig)
 {
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   sIndirectLayerTrees[aId].mRoot = aRoot;
   sIndirectLayerTrees[aId].mTargetConfig = aTargetConfig;
 }
 
-/* static */ CompositorParent::LayerTreeState*
-CompositorParent::GetIndirectShadowTree(uint64_t aId)
+/* static */ CompositorBridgeParent::LayerTreeState*
+CompositorBridgeParent::GetIndirectShadowTree(uint64_t aId)
 {
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   LayerTreeMap::iterator cit = sIndirectLayerTrees.find(aId);
   if (sIndirectLayerTrees.end() == cit) {
     return nullptr;
   }
   return &cit->second;
 }
 
 bool
-CrossProcessCompositorParent::RecvNotifyHidden(const uint64_t& id)
+CrossProcessCompositorBridgeParent::RecvNotifyHidden(const uint64_t& id)
 {
   RefPtr<CompositorLRU> lru = CompositorLRU::GetSingleton();
   lru->Add(this, id);
   return true;
 }
 
 bool
-CrossProcessCompositorParent::RecvNotifyVisible(const uint64_t& id)
+CrossProcessCompositorBridgeParent::RecvNotifyVisible(const uint64_t& id)
 {
   RefPtr<CompositorLRU> lru = CompositorLRU::GetSingleton();
   lru->Remove(this, id);
   return true;
 }
 
 bool
-CrossProcessCompositorParent::RecvRequestNotifyAfterRemotePaint()
+CrossProcessCompositorBridgeParent::RecvRequestNotifyAfterRemotePaint()
 {
   mNotifyAfterRemotePaint = true;
   return true;
 }
 
 void
-CrossProcessCompositorParent::ActorDestroy(ActorDestroyReason aWhy)
+CrossProcessCompositorBridgeParent::ActorDestroy(ActorDestroyReason aWhy)
 {
   RefPtr<CompositorLRU> lru = CompositorLRU::GetSingleton();
   lru->Remove(this);
 
   MessageLoop::current()->PostTask(
     FROM_HERE,
-    NewRunnableMethod(this, &CrossProcessCompositorParent::DeferredDestroy));
+    NewRunnableMethod(this, &CrossProcessCompositorBridgeParent::DeferredDestroy));
 }
 
 PLayerTransactionParent*
-CrossProcessCompositorParent::AllocPLayerTransactionParent(const nsTArray<LayersBackend>&,
-                                                           const uint64_t& aId,
-                                                           TextureFactoryIdentifier* aTextureFactoryIdentifier,
-                                                           bool *aSuccess)
+CrossProcessCompositorBridgeParent::AllocPLayerTransactionParent(
+  const nsTArray<LayersBackend>&,
+  const uint64_t& aId,
+  TextureFactoryIdentifier* aTextureFactoryIdentifier,
+  bool *aSuccess)
 {
   MOZ_ASSERT(aId != 0);
 
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
 
-  CompositorParent::LayerTreeState* state = nullptr;
+  CompositorBridgeParent::LayerTreeState* state = nullptr;
   LayerTreeMap::iterator itr = sIndirectLayerTrees.find(aId);
   if (sIndirectLayerTrees.end() != itr) {
     state = &itr->second;
   }
 
   if (state && state->mLayerManager) {
     state->mCrossProcessParent = this;
     LayerManagerComposite* lm = state->mLayerManager;
@@ -2323,65 +2324,66 @@ CrossProcessCompositorParent::AllocPLaye
   // Bug 900745. change *aSuccess to false to see test failures.
   *aSuccess = true;
   LayerTransactionParent* p = new LayerTransactionParent(nullptr, this, aId);
   p->AddIPDLReference();
   return p;
 }
 
 bool
-CrossProcessCompositorParent::DeallocPLayerTransactionParent(PLayerTransactionParent* aLayers)
+CrossProcessCompositorBridgeParent::DeallocPLayerTransactionParent(PLayerTransactionParent* aLayers)
 {
   LayerTransactionParent* slp = static_cast<LayerTransactionParent*>(aLayers);
   EraseLayerState(slp->GetId());
   static_cast<LayerTransactionParent*>(aLayers)->ReleaseIPDLReference();
   return true;
 }
 
 bool
-CrossProcessCompositorParent::RecvNotifyChildCreated(const uint64_t& child)
+CrossProcessCompositorBridgeParent::RecvNotifyChildCreated(const uint64_t& child)
 {
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   for (LayerTreeMap::iterator it = sIndirectLayerTrees.begin();
        it != sIndirectLayerTrees.end(); it++) {
-    CompositorParent::LayerTreeState* lts = &it->second;
+    CompositorBridgeParent::LayerTreeState* lts = &it->second;
     if (lts->mParent && lts->mCrossProcessParent == this) {
       lts->mParent->NotifyChildCreated(child);
       return true;
     }
   }
   return false;
 }
 
 void
-CrossProcessCompositorParent::ShadowLayersUpdated(
+CrossProcessCompositorBridgeParent::ShadowLayersUpdated(
   LayerTransactionParent* aLayerTree,
   const uint64_t& aTransactionId,
   const TargetConfig& aTargetConfig,
   const InfallibleTArray<PluginWindowData>& aPlugins,
   bool aIsFirstPaint,
   bool aScheduleComposite,
   uint32_t aPaintSequenceNumber,
   bool aIsRepeatTransaction,
   int32_t /*aPaintSyncId: unused*/)
 {
   uint64_t id = aLayerTree->GetId();
 
   MOZ_ASSERT(id != 0);
 
-  CompositorParent::LayerTreeState* state = CompositorParent::GetIndirectShadowTree(id);
+  CompositorBridgeParent::LayerTreeState* state =
+    CompositorBridgeParent::GetIndirectShadowTree(id);
   if (!state) {
     return;
   }
   MOZ_ASSERT(state->mParent);
   state->mParent->ScheduleRotationOnCompositorThread(aTargetConfig, aIsFirstPaint);
 
   Layer* shadowRoot = aLayerTree->GetRoot();
   if (shadowRoot) {
-    CompositorParent::SetShadowProperties(shadowRoot);
+    CompositorBridgeParent::SetShadowProperties(shadowRoot);
   }
   UpdateIndirectTree(id, shadowRoot, aTargetConfig);
 
   // Cache the plugin data for this remote layer tree
   state->mPluginData = aPlugins;
   state->mUpdatedPluginDataAvailable = true;
 
   state->mParent->NotifyShadowTreeTransaction(id, aIsFirstPaint, aScheduleComposite,
@@ -2404,20 +2406,20 @@ CrossProcessCompositorParent::ShadowLaye
 
 #if defined(XP_WIN) || defined(MOZ_WIDGET_GTK)
 //#define PLUGINS_LOG(...) printf_stderr("CP [%s]: ", __FUNCTION__);
 //                         printf_stderr(__VA_ARGS__);
 //                         printf_stderr("\n");
 #define PLUGINS_LOG(...)
 
 bool
-CompositorParent::UpdatePluginWindowState(uint64_t aId)
+CompositorBridgeParent::UpdatePluginWindowState(uint64_t aId)
 {
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
-  CompositorParent::LayerTreeState& lts = sIndirectLayerTrees[aId];
+  CompositorBridgeParent::LayerTreeState& lts = sIndirectLayerTrees[aId];
   if (!lts.mParent) {
     PLUGINS_LOG("[%" PRIu64 "] layer tree compositor parent pointer is null", aId);
     return false;
   }
 
   // Check if this layer tree has received any shadow layer updates
   if (!lts.mUpdatedPluginDataAvailable) {
     PLUGINS_LOG("[%" PRIu64 "] no plugin data", aId);
@@ -2476,17 +2478,17 @@ CompositorParent::UpdatePluginWindowStat
     mPluginsLayerOffset = nsIntPoint(0,0);
     mPluginsLayerVisibleRegion.SetEmpty();
     uintptr_t parentWidget = (uintptr_t)lts.mParent->GetWidget();
     Unused << lts.mParent->SendHideAllPlugins(parentWidget);
     lts.mUpdatedPluginDataAvailable = false;
     PLUGINS_LOG("[%" PRIu64 "] hide all", aId);
   } else {
     // Retrieve the offset and visible region of the layer that hosts
-    // the plugins, CompositorChild needs these in calculating proper
+    // the plugins, CompositorBridgeChild needs these in calculating proper
     // plugin clipping.
     LayerTransactionParent* layerTree = lts.mLayerTree;
     Layer* contentRoot = layerTree->GetRoot();
     if (contentRoot) {
       nsIntPoint offset;
       nsIntRegion visibleRegion;
       if (contentRoot->GetVisibleRegionRelativeToRootLayer(visibleRegion,
                                                             &offset)) {
@@ -2517,227 +2519,235 @@ CompositorParent::UpdatePluginWindowStat
   }
 
   mLastPluginUpdateLayerTreeId = aId;
   mCachedPluginData = lts.mPluginData;
   return true;
 }
 
 void
-CompositorParent::ScheduleShowAllPluginWindows()
+CompositorBridgeParent::ScheduleShowAllPluginWindows()
 {
   CancelableTask *pluginTask =
-    NewRunnableMethod(this, &CompositorParent::ShowAllPluginWindows);
+    NewRunnableMethod(this, &CompositorBridgeParent::ShowAllPluginWindows);
   MOZ_ASSERT(CompositorLoop());
   CompositorLoop()->PostTask(FROM_HERE, pluginTask);
 }
 
 void
-CompositorParent::ShowAllPluginWindows()
+CompositorBridgeParent::ShowAllPluginWindows()
 {
   MOZ_ASSERT(!NS_IsMainThread());
   mDeferPluginWindows = false;
   ScheduleComposition();
 }
 
 void
-CompositorParent::ScheduleHideAllPluginWindows()
+CompositorBridgeParent::ScheduleHideAllPluginWindows()
 {
   CancelableTask *pluginTask =
-    NewRunnableMethod(this, &CompositorParent::HideAllPluginWindows);
+    NewRunnableMethod(this, &CompositorBridgeParent::HideAllPluginWindows);
   MOZ_ASSERT(CompositorLoop());
   CompositorLoop()->PostTask(FROM_HERE, pluginTask);
 }
 
 void
-CompositorParent::HideAllPluginWindows()
+CompositorBridgeParent::HideAllPluginWindows()
 {
   MOZ_ASSERT(!NS_IsMainThread());
   // No plugins in the cache implies no plugins to manage
   // in this content.
   if (!mCachedPluginData.Length() || mDeferPluginWindows) {
     return;
   }
   mDeferPluginWindows = true;
   mPluginUpdateResponsePending = true;
   mPluginWindowsHidden = true;
   Unused << SendHideAllPlugins((uintptr_t)GetWidget());
   ScheduleComposition();
 }
 #endif // #if defined(XP_WIN) || defined(MOZ_WIDGET_GTK)
 
 void
-CrossProcessCompositorParent::DidComposite(uint64_t aId,
-                                           TimeStamp& aCompositeStart,
-                                           TimeStamp& aCompositeEnd)
+CrossProcessCompositorBridgeParent::DidComposite(
+  uint64_t aId,
+  TimeStamp& aCompositeStart,
+  TimeStamp& aCompositeEnd)
 {
   sIndirectLayerTreesLock->AssertCurrentThreadOwns();
   if (LayerTransactionParent *layerTree = sIndirectLayerTrees[aId].mLayerTree) {
     Unused << SendDidComposite(aId, layerTree->GetPendingTransactionId(), aCompositeStart, aCompositeEnd);
     layerTree->SetPendingTransactionId(0);
   }
 }
 
 void
-CrossProcessCompositorParent::ForceComposite(LayerTransactionParent* aLayerTree)
+CrossProcessCompositorBridgeParent::ForceComposite(LayerTransactionParent* aLayerTree)
 {
   uint64_t id = aLayerTree->GetId();
   MOZ_ASSERT(id != 0);
-  CompositorParent* parent;
+  CompositorBridgeParent* parent;
   { // scope lock
     MonitorAutoLock lock(*sIndirectLayerTreesLock);
     parent = sIndirectLayerTrees[id].mParent;
   }
   if (parent) {
     parent->ForceComposite(aLayerTree);
   }
 }
 
 void
-CrossProcessCompositorParent::NotifyClearCachedResources(LayerTransactionParent* aLayerTree)
+CrossProcessCompositorBridgeParent::NotifyClearCachedResources(LayerTransactionParent* aLayerTree)
 {
   uint64_t id = aLayerTree->GetId();
   MOZ_ASSERT(id != 0);
 
   RefPtr<CompositorUpdateObserver> observer;
   { // scope lock
     MonitorAutoLock lock(*sIndirectLayerTreesLock);
     observer = sIndirectLayerTrees[id].mLayerTreeClearedObserver;
     sIndirectLayerTrees[id].mLayerTreeClearedObserver = nullptr;
   }
   if (observer) {
     observer->ObserveUpdate(id, false);
   }
 }
 
 bool
-CrossProcessCompositorParent::SetTestSampleTime(
+CrossProcessCompositorBridgeParent::SetTestSampleTime(
   LayerTransactionParent* aLayerTree, const TimeStamp& aTime)
 {
   uint64_t id = aLayerTree->GetId();
   MOZ_ASSERT(id != 0);
-  const CompositorParent::LayerTreeState* state = CompositorParent::GetIndirectShadowTree(id);
+  const CompositorBridgeParent::LayerTreeState* state =
+    CompositorBridgeParent::GetIndirectShadowTree(id);
   if (!state) {
     return false;
   }
 
   MOZ_ASSERT(state->mParent);
   return state->mParent->SetTestSampleTime(aLayerTree, aTime);
 }
 
 void
-CrossProcessCompositorParent::LeaveTestMode(LayerTransactionParent* aLayerTree)
+CrossProcessCompositorBridgeParent::LeaveTestMode(LayerTransactionParent* aLayerTree)
 {
   uint64_t id = aLayerTree->GetId();
   MOZ_ASSERT(id != 0);
-  const CompositorParent::LayerTreeState* state = CompositorParent::GetIndirectShadowTree(id);
+  const CompositorBridgeParent::LayerTreeState* state =
+    CompositorBridgeParent::GetIndirectShadowTree(id);
   if (!state) {
     return;
   }
 
   MOZ_ASSERT(state->mParent);
   state->mParent->LeaveTestMode(aLayerTree);
 }
 
 void
-CrossProcessCompositorParent::ApplyAsyncProperties(
+CrossProcessCompositorBridgeParent::ApplyAsyncProperties(
     LayerTransactionParent* aLayerTree)
 {
   uint64_t id = aLayerTree->GetId();
   MOZ_ASSERT(id != 0);
-  const CompositorParent::LayerTreeState* state =
-    CompositorParent::GetIndirectShadowTree(id);
+  const CompositorBridgeParent::LayerTreeState* state =
+    CompositorBridgeParent::GetIndirectShadowTree(id);
   if (!state) {
     return;
   }
 
   MOZ_ASSERT(state->mParent);
   state->mParent->ApplyAsyncProperties(aLayerTree);
 }
 
 void
-CrossProcessCompositorParent::FlushApzRepaints(const LayerTransactionParent* aLayerTree)
+CrossProcessCompositorBridgeParent::FlushApzRepaints(const LayerTransactionParent* aLayerTree)
 {
   uint64_t id = aLayerTree->GetId();
   MOZ_ASSERT(id != 0);
-  const CompositorParent::LayerTreeState* state =
-    CompositorParent::GetIndirectShadowTree(id);
+  const CompositorBridgeParent::LayerTreeState* state =
+    CompositorBridgeParent::GetIndirectShadowTree(id);
   if (!state) {
     return;
   }
 
   MOZ_ASSERT(state->mParent);
   state->mParent->FlushApzRepaints(aLayerTree);
 }
 
 void
-CrossProcessCompositorParent::GetAPZTestData(const LayerTransactionParent* aLayerTree,
-                                             APZTestData* aOutData)
+CrossProcessCompositorBridgeParent::GetAPZTestData(
+  const LayerTransactionParent* aLayerTree,
+  APZTestData* aOutData)
 {
   uint64_t id = aLayerTree->GetId();
   MOZ_ASSERT(id != 0);
   MonitorAutoLock lock(*sIndirectLayerTreesLock);
   *aOutData = sIndirectLayerTrees[id].mApzTestData;
 }
 
 void
-CrossProcessCompositorParent::SetConfirmedTargetAPZC(const LayerTransactionParent* aLayerTree,
-                                                     const uint64_t& aInputBlockId,
-                                                     const nsTArray<ScrollableLayerGuid>& aTargets)
+CrossProcessCompositorBridgeParent::SetConfirmedTargetAPZC(
+  const LayerTransactionParent* aLayerTree,
+  const uint64_t& aInputBlockId,
+  const nsTArray<ScrollableLayerGuid>& aTargets)
 {
   uint64_t id = aLayerTree->GetId();
   MOZ_ASSERT(id != 0);
-  const CompositorParent::LayerTreeState* state = CompositorParent::GetIndirectShadowTree(id);
+  const CompositorBridgeParent::LayerTreeState* state =
+    CompositorBridgeParent::GetIndirectShadowTree(id);
   if (!state || !state->mParent) {
     return;
   }
 
   state->mParent->SetConfirmedTargetAPZC(aLayerTree, aInputBlockId, aTargets);
 }
 
 AsyncCompositionManager*
-CrossProcessCompositorParent::GetCompositionManager(LayerTransactionParent* aLayerTree)
+CrossProcessCompositorBridgeParent::GetCompositionManager(LayerTransactionParent* aLayerTree)
 {
   uint64_t id = aLayerTree->GetId();
-  const CompositorParent::LayerTreeState* state = CompositorParent::GetIndirectShadowTree(id);
+  const CompositorBridgeParent::LayerTreeState* state =
+    CompositorBridgeParent::GetIndirectShadowTree(id);
   if (!state) {
     return nullptr;
   }
 
   MOZ_ASSERT(state->mParent);
   return state->mParent->GetCompositionManager(aLayerTree);
 }
 
 void
-CrossProcessCompositorParent::DeferredDestroy()
+CrossProcessCompositorBridgeParent::DeferredDestroy()
 {
   MOZ_ASSERT(mCompositorThreadHolder);
   mCompositorThreadHolder = nullptr;
   mSelfRef = nullptr;
 }
 
-CrossProcessCompositorParent::~CrossProcessCompositorParent()
+CrossProcessCompositorBridgeParent::~CrossProcessCompositorBridgeParent()
 {
   MOZ_ASSERT(NS_IsMainThread());
   MOZ_ASSERT(XRE_GetIOMessageLoop());
   XRE_GetIOMessageLoop()->PostTask(FROM_HERE,
                                    new DeleteTask<Transport>(mTransport));
 }
 
 IToplevelProtocol*
-CrossProcessCompositorParent::CloneToplevel(const InfallibleTArray<mozilla::ipc::ProtocolFdMapping>& aFds,
-                                            base::ProcessHandle aPeerProcess,
-                                            mozilla::ipc::ProtocolCloneContext* aCtx)
+CrossProcessCompositorBridgeParent::CloneToplevel(
+  const InfallibleTArray<mozilla::ipc::ProtocolFdMapping>& aFds,
+  base::ProcessHandle aPeerProcess,
+  mozilla::ipc::ProtocolCloneContext* aCtx)
 {
   for (unsigned int i = 0; i < aFds.Length(); i++) {
     if (aFds[i].protocolId() == (unsigned)GetProtocolId()) {
       Transport* transport = OpenDescriptor(aFds[i].fd(),
                                             Transport::MODE_SERVER);
       PCompositorBridgeParent* compositor =
-        CompositorParent::Create(transport, base::GetProcId(aPeerProcess));
+        CompositorBridgeParent::Create(transport, base::GetProcId(aPeerProcess));
       compositor->CloneManagees(this, aCtx);
       compositor->IToplevelProtocol::SetTransport(transport);
       // The reference to the compositor thread is held in OnChannelConnected().
       // We need to do this for cloned actors, too.
       compositor->OnChannelConnected(base::GetProcId(aPeerProcess));
       return compositor;
     }
   }
rename from gfx/layers/ipc/CompositorParent.h
rename to gfx/layers/ipc/CompositorBridgeParent.h
--- a/gfx/layers/ipc/CompositorParent.h
+++ b/gfx/layers/ipc/CompositorBridgeParent.h
@@ -1,16 +1,16 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set sw=4 ts=8 et tw=80 : */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
-#ifndef mozilla_layers_CompositorParent_h
-#define mozilla_layers_CompositorParent_h
+#ifndef mozilla_layers_CompositorBridgeParent_h
+#define mozilla_layers_CompositorBridgeParent_h
 
 // Enable this pref to turn on compositor performance warning.
 // This will print warnings if the compositor isn't meeting
 // its responsiveness objectives:
 //    1) Compose a frame within 15ms of receiving a ScheduleCompositeCall
 //    2) Unless a frame was composited within the throttle threshold in
 //       which the deadline will be 15ms + throttle threshold
 //#define COMPOSITOR_PERFORMANCE_WARNING
@@ -48,21 +48,21 @@ namespace gfx {
 class DrawTarget;
 } // namespace gfx
 
 namespace layers {
 
 class APZCTreeManager;
 class AsyncCompositionManager;
 class Compositor;
-class CompositorParent;
+class CompositorBridgeParent;
 class LayerManagerComposite;
 class LayerTransactionParent;
 class PAPZParent;
-class CrossProcessCompositorParent;
+class CrossProcessCompositorBridgeParent;
 
 struct ScopedLayerTreeRegistration
 {
   ScopedLayerTreeRegistration(APZCTreeManager* aApzctm,
                               uint64_t aLayersId,
                               Layer* aRoot,
                               GeckoContentController* aController);
   ~ScopedLayerTreeRegistration();
@@ -85,30 +85,30 @@ public:
 private:
   ~CompositorThreadHolder();
 
   base::Thread* const mCompositorThread;
 
   static base::Thread* CreateCompositorThread();
   static void DestroyCompositorThread(base::Thread* aCompositorThread);
 
-  friend class CompositorParent;
+  friend class CompositorBridgeParent;
 };
 
 /**
  * Manages the vsync (de)registration and tracking on behalf of the
  * compositor when it need to paint.
  * Turns vsync notifications into scheduled composites.
  **/
 class CompositorVsyncScheduler
 {
   NS_INLINE_DECL_THREADSAFE_REFCOUNTING(CompositorVsyncScheduler)
 
 public:
-  explicit CompositorVsyncScheduler(CompositorParent* aCompositorParent, nsIWidget* aWidget);
+  explicit CompositorVsyncScheduler(CompositorBridgeParent* aCompositorBridgeParent, nsIWidget* aWidget);
 
 #ifdef MOZ_WIDGET_GONK
   // emulator-ics never trigger the display on/off, so compositor will always
   // skip composition request at that device. Only check the display status
   // with kk device and upon.
 #if ANDROID_VERSION >= 19
   // SetDisplay() and CancelSetDisplayTask() are used for the display on/off.
   // It will clear all composition related task and flag, and skip another
@@ -169,17 +169,17 @@ private:
   private:
     virtual ~Observer();
 
     Mutex mMutex;
     // Hold raw pointer to avoid mutual reference.
     CompositorVsyncScheduler* mOwner;
   };
 
-  CompositorParent* mCompositorParent;
+  CompositorBridgeParent* mCompositorBridgeParent;
   TimeStamp mLastCompose;
 
 #ifdef COMPOSITOR_PERFORMANCE_WARNING
   TimeStamp mExpectedComposeStartTime;
 #endif
 
   bool mAsapScheduling;
   bool mIsObservingVsync;
@@ -209,24 +209,24 @@ public:
   NS_INLINE_DECL_THREADSAFE_REFCOUNTING(CompositorUpdateObserver);
 
   virtual void ObserveUpdate(uint64_t aLayersId, bool aActive) = 0;
 
 protected:
   virtual ~CompositorUpdateObserver() {}
 };
 
-class CompositorParent final : public PCompositorBridgeParent,
+class CompositorBridgeParent final : public PCompositorBridgeParent,
                                public ShadowLayersManager
 {
-  NS_INLINE_DECL_THREADSAFE_REFCOUNTING_WITH_MAIN_THREAD_DESTRUCTION(CompositorParent)
+  NS_INLINE_DECL_THREADSAFE_REFCOUNTING_WITH_MAIN_THREAD_DESTRUCTION(CompositorBridgeParent)
   friend class CompositorVsyncScheduler;
 
 public:
-  explicit CompositorParent(nsIWidget* aWidget,
+  explicit CompositorBridgeParent(nsIWidget* aWidget,
                             bool aUseExternalSurfaceSize = false,
                             int aSurfaceWidth = -1, int aSurfaceHeight = -1);
 
   virtual bool RecvGetFrameUniformity(FrameUniformityData* aOutData) override;
   virtual bool RecvRequestOverfill() override;
   virtual bool RecvWillStop() override;
   virtual bool RecvStop() override;
   virtual bool RecvPause() override;
@@ -243,17 +243,17 @@ public:
 
   virtual bool RecvGetTileSize(int32_t* aWidth, int32_t* aHeight) override;
 
   virtual bool RecvNotifyRegionInvalidated(const nsIntRegion& aRegion) override;
   virtual bool RecvStartFrameTimeRecording(const int32_t& aBufferSize, uint32_t* aOutStartIndex) override;
   virtual bool RecvStopFrameTimeRecording(const uint32_t& aStartIndex, InfallibleTArray<float>* intervals) override;
 
   // Unused for chrome <-> compositor communication (which this class does).
-  // @see CrossProcessCompositorParent::RecvRequestNotifyAfterRemotePaint
+  // @see CrossProcessCompositorBridgeParent::RecvRequestNotifyAfterRemotePaint
   virtual bool RecvRequestNotifyAfterRemotePaint() override { return true; };
 
   virtual bool RecvClearApproximatelyVisibleRegions(const uint64_t& aLayersId,
                                                     const uint32_t& aPresShellId) override;
   void ClearApproximatelyVisibleRegions(const uint64_t& aLayersId,
                                         const Maybe<uint32_t>& aPresShellId);
   virtual bool RecvNotifyApproximatelyVisibleRegion(const ScrollableLayerGuid& aGuid,
                                                     const CSSIntRegion& aRegion) override;
@@ -348,33 +348,33 @@ public:
    *
    * This must be called on the compositor thread.
    */
   void InvalidateRemoteLayers();
 
   /**
    * Returns a pointer to the compositor corresponding to the given ID.
    */
-  static CompositorParent* GetCompositor(uint64_t id);
+  static CompositorBridgeParent* GetCompositor(uint64_t id);
 
   /**
    * Returns the compositor thread's message loop.
    *
-   * This message loop is used by CompositorParent, ImageBridgeParent,
+   * This message loop is used by CompositorBridgeParent, ImageBridgeParent,
    * and VRManagerParent
    */
   static MessageLoop* CompositorLoop();
 
   /**
    * Creates the compositor thread and the global compositor map.
    */
   static void StartUp();
 
   /**
-   * Waits for all [CrossProcess]CompositorParent's to be gone,
+   * Waits for all [CrossProcess]CompositorBridgeParent's to be gone,
    * and destroys the compositor thread and global compositor map.
    *
    * Does not return until all of that has completed.
    */
   static void ShutDown();
 
   /**
    * Allocate an ID that can be used to refer to a layer tree and
@@ -412,22 +412,22 @@ public:
   static PCompositorBridgeParent*
   Create(Transport* aTransport, ProcessId aOtherProcess);
 
   struct LayerTreeState {
     LayerTreeState();
     ~LayerTreeState();
     RefPtr<Layer> mRoot;
     RefPtr<GeckoContentController> mController;
-    CompositorParent* mParent;
+    CompositorBridgeParent* mParent;
     LayerManagerComposite* mLayerManager;
-    // Pointer to the CrossProcessCompositorParent. Used by APZCs to share
+    // Pointer to the CrossProcessCompositorBridgeParent. Used by APZCs to share
     // their FrameMetrics with the corresponding child process that holds
     // the PCompositorBridgeChild
-    CrossProcessCompositorParent* mCrossProcessParent;
+    CrossProcessCompositorBridgeParent* mCrossProcessParent;
     TargetConfig mTargetConfig;
     APZTestData mApzTestData;
     LayerTransactionParent* mLayerTree;
     nsTArray<PluginWindowData> mPluginData;
     bool mUpdatedPluginDataAvailable;
     RefPtr<CompositorUpdateObserver> mLayerTreeReadyObserver;
     RefPtr<CompositorUpdateObserver> mLayerTreeClearedObserver;
 
@@ -495,17 +495,17 @@ public:
    */
   static bool UpdateRemoteContentController(uint64_t aLayersId,
                                             dom::ContentParent* aContentParent,
                                             const dom::TabId& aTabId,
                                             dom::TabParent* aBrowserParent);
 
 protected:
   // Protected destructor, to discourage deletion outside of Release():
-  virtual ~CompositorParent();
+  virtual ~CompositorBridgeParent();
 
   void DeferredDestroy();
 
   virtual PLayerTransactionParent*
     AllocPLayerTransactionParent(const nsTArray<LayersBackend>& aBackendHints,
                                  const uint64_t& aId,
                                  TextureFactoryIdentifier* aTextureFactoryIdentifier,
                                  bool* aSuccess) override;
@@ -526,21 +526,21 @@ protected:
   RefPtr<Compositor> NewCompositor(const nsTArray<LayersBackend>& aBackendHints);
   void ResetCompositorTask(const nsTArray<LayersBackend>& aBackendHints,
                            Maybe<TextureFactoryIdentifier>* aOutNewIdentifier);
   Maybe<TextureFactoryIdentifier> ResetCompositorImpl(const nsTArray<LayersBackend>& aBackendHints);
 
   /**
    * Add a compositor to the global compositor map.
    */
-  static void AddCompositor(CompositorParent* compositor, uint64_t* id);
+  static void AddCompositor(CompositorBridgeParent* compositor, uint64_t* id);
   /**
    * Remove a compositor from the global compositor map.
    */
-  static CompositorParent* RemoveCompositor(uint64_t id);
+  static CompositorBridgeParent* RemoveCompositor(uint64_t id);
 
    /**
    * Return true if current state allows compositing, that is
    * finishing a layers transaction.
    */
   bool CanComposite();
 
   void DidComposite(TimeStamp& aCompositeStart, TimeStamp& aCompositeEnd);
@@ -591,15 +591,15 @@ protected:
   // indicates if plugin window visibility and metric updates are currently
   // being defered due to a scroll operation.
   bool mDeferPluginWindows;
   // indicates if the plugin windows were hidden, and need to be made
   // visible again even if their geometry has not changed.
   bool mPluginWindowsHidden;
 #endif
 
-  DISALLOW_EVIL_CONSTRUCTORS(CompositorParent);
+  DISALLOW_EVIL_CONSTRUCTORS(CompositorBridgeParent);
 };
 
 } // namespace layers
 } // namespace mozilla
 
-#endif // mozilla_layers_CompositorParent_h
+#endif // mozilla_layers_CompositorBridgeParent_h
--- a/gfx/layers/ipc/CompositorLRU.cpp
+++ b/gfx/layers/ipc/CompositorLRU.cpp
@@ -7,17 +7,17 @@
 
 #include "CompositorLRU.h"
 
 #include "mozilla/ClearOnShutdown.h"
 #include "mozilla/DebugOnly.h"
 #include "mozilla/Preferences.h"
 #include "mozilla/unused.h"
 
-#include "CompositorParent.h"
+#include "CompositorBridgeParent.h"
 
 namespace mozilla {
 namespace layers {
 
 mozilla::StaticRefPtr<CompositorLRU> CompositorLRU::sSingleton;
 
 void
 CompositorLRU::Init()
--- a/gfx/layers/ipc/ImageBridgeChild.cpp
+++ b/gfx/layers/ipc/ImageBridgeChild.cpp
@@ -20,17 +20,17 @@
 #include "mozilla/ReentrantMonitor.h"   // for ReentrantMonitor, etc
 #include "mozilla/ipc/MessageChannel.h" // for MessageChannel, etc
 #include "mozilla/ipc/Transport.h"      // for Transport
 #include "mozilla/gfx/Point.h"          // for IntSize
 #include "mozilla/layers/AsyncCanvasRenderer.h"
 #include "mozilla/media/MediaSystemResourceManager.h" // for MediaSystemResourceManager
 #include "mozilla/media/MediaSystemResourceManagerChild.h" // for MediaSystemResourceManagerChild
 #include "mozilla/layers/CompositableClient.h"  // for CompositableChild, etc
-#include "mozilla/layers/CompositorParent.h" // for CompositorParent
+#include "mozilla/layers/CompositorBridgeParent.h" // for CompositorBridgeParent
 #include "mozilla/layers/ISurfaceAllocator.h"  // for ISurfaceAllocator
 #include "mozilla/layers/ImageClient.h"  // for ImageClient
 #include "mozilla/layers/LayersMessages.h"  // for CompositableOperation
 #include "mozilla/layers/PCompositableChild.h"  // for PCompositableChild
 #include "mozilla/layers/PImageContainerChild.h"
 #include "mozilla/layers/TextureClient.h"  // for TextureClient
 #include "mozilla/mozalloc.h"           // for operator new, etc
 #include "nsAutoPtr.h"                  // for nsRefPtr
@@ -803,17 +803,17 @@ bool ImageBridgeChild::StartUpOnThread(T
   MOZ_ASSERT(aThread, "ImageBridge needs a thread.");
   if (sImageBridgeChildSingleton == nullptr) {
     sImageBridgeChildThread = aThread;
     if (!aThread->IsRunning()) {
       aThread->Start();
     }
     sImageBridgeChildSingleton = new ImageBridgeChild();
     sImageBridgeParentSingleton = new ImageBridgeParent(
-      CompositorParent::CompositorLoop(), nullptr, base::GetCurrentProcId());
+      CompositorBridgeParent::CompositorLoop(), nullptr, base::GetCurrentProcId());
     sImageBridgeChildSingleton->ConnectAsync(sImageBridgeParentSingleton);
     sImageBridgeChildSingleton->GetMessageLoop()->PostTask(
       FROM_HERE,
       NewRunnableFunction(CallSendImageBridgeThreadId,
                           sImageBridgeChildSingleton.get()));
     return true;
   } else {
     return false;
--- a/gfx/layers/ipc/ImageBridgeParent.cpp
+++ b/gfx/layers/ipc/ImageBridgeParent.cpp
@@ -14,17 +14,17 @@
 #include "mozilla/gfx/Point.h"                   // for IntSize
 #include "mozilla/Hal.h"                // for hal::SetCurrentThreadPriority()
 #include "mozilla/HalTypes.h"           // for hal::THREAD_PRIORITY_COMPOSITOR
 #include "mozilla/ipc/MessageChannel.h" // for MessageChannel, etc
 #include "mozilla/ipc/ProtocolUtils.h"
 #include "mozilla/ipc/Transport.h"      // for Transport
 #include "mozilla/media/MediaSystemResourceManagerParent.h" // for MediaSystemResourceManagerParent
 #include "mozilla/layers/CompositableTransactionParent.h"
-#include "mozilla/layers/CompositorParent.h"  // for CompositorParent
+#include "mozilla/layers/CompositorBridgeParent.h"  // for CompositorBridgeParent
 #include "mozilla/layers/LayerManagerComposite.h"
 #include "mozilla/layers/LayersMessages.h"  // for EditReply
 #include "mozilla/layers/LayersSurfaces.h"  // for PGrallocBufferParent
 #include "mozilla/layers/PCompositableParent.h"
 #include "mozilla/layers/PImageBridgeParent.h"
 #include "mozilla/layers/TextureHostOGL.h"  // for TextureHostOGL
 #include "mozilla/layers/Compositor.h"
 #include "mozilla/mozalloc.h"           // for operator new, etc
@@ -44,17 +44,17 @@ namespace layers {
 using namespace mozilla::ipc;
 using namespace mozilla::gfx;
 using namespace mozilla::media;
 
 std::map<base::ProcessId, ImageBridgeParent*> ImageBridgeParent::sImageBridges;
 
 MessageLoop* ImageBridgeParent::sMainLoop = nullptr;
 
-// defined in CompositorParent.cpp
+// defined in CompositorBridgeParent.cpp
 CompositorThreadHolder* GetCompositorThreadHolder();
 
 ImageBridgeParent::ImageBridgeParent(MessageLoop* aLoop,
                                      Transport* aTransport,
                                      ProcessId aChildProcessId)
   : mMessageLoop(aLoop)
   , mTransport(aTransport)
   , mSetChildThreadPriority(false)
@@ -179,17 +179,17 @@ ConnectImageBridgeInParentProcess(ImageB
                                   base::ProcessId aOtherPid)
 {
   aBridge->Open(aTransport, aOtherPid, XRE_GetIOMessageLoop(), ipc::ParentSide);
 }
 
 /*static*/ PImageBridgeParent*
 ImageBridgeParent::Create(Transport* aTransport, ProcessId aChildProcessId)
 {
-  MessageLoop* loop = CompositorParent::CompositorLoop();
+  MessageLoop* loop = CompositorBridgeParent::CompositorLoop();
   RefPtr<ImageBridgeParent> bridge = new ImageBridgeParent(loop, aTransport, aChildProcessId);
   bridge->mSelfRef = bridge;
   loop->PostTask(FROM_HERE,
                  NewRunnableFunction(ConnectImageBridgeInParentProcess,
                                      bridge.get(), aTransport, aChildProcessId));
   return bridge.get();
 }
 
--- a/gfx/layers/ipc/ImageBridgeParent.h
+++ b/gfx/layers/ipc/ImageBridgeParent.h
@@ -9,17 +9,17 @@
 #include <stddef.h>                     // for size_t
 #include <stdint.h>                     // for uint32_t, uint64_t
 #include "CompositableTransactionParent.h"
 #include "ImageContainerParent.h"
 #include "mozilla/Assertions.h"         // for MOZ_ASSERT_HELPER2
 #include "mozilla/Attributes.h"         // for override
 #include "mozilla/ipc/ProtocolUtils.h"
 #include "mozilla/ipc/SharedMemory.h"   // for SharedMemory, etc
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/layers/PImageBridgeParent.h"
 #include "nsAutoPtr.h"                  // for nsRefPtr
 #include "nsISupportsImpl.h"
 #include "nsTArrayForwardDeclare.h"     // for InfallibleTArray
 
 class MessageLoop;
 
 namespace base {
--- a/gfx/layers/ipc/LayerTransactionChild.cpp
+++ b/gfx/layers/ipc/LayerTransactionChild.cpp
@@ -22,17 +22,17 @@ namespace layers {
 
 void
 LayerTransactionChild::Destroy()
 {
   if (!IPCOpen()) {
     return;
   }
   // mDestroyed is used to prevent calling Send__delete__() twice.
-  // When this function is called from CompositorChild::Destroy(),
+  // When this function is called from CompositorBridgeChild::Destroy(),
   // under Send__delete__() call, this function is called from
   // ShadowLayerForwarder's destructor.
   // When it happens, IPCOpen() is still true.
   // See bug 1004191.
   mDestroyed = true;
   MOZ_ASSERT(0 == ManagedPLayerChild().Count(),
              "layers should have been cleaned up by now");
 
--- a/gfx/layers/ipc/LayerTransactionChild.h
+++ b/gfx/layers/ipc/LayerTransactionChild.h
@@ -80,17 +80,17 @@ protected:
     mIPCOpen = true;
     AddRef();
   }
   void ReleaseIPDLReference() {
     MOZ_ASSERT(mIPCOpen == true);
     mIPCOpen = false;
     Release();
   }
-  friend class CompositorChild;
+  friend class CompositorBridgeChild;
   friend class layout::RenderFrameChild;
 
   ShadowLayerForwarder* mForwarder;
   bool mIPCOpen;
   bool mDestroyed;
   uint64_t mId;
 };
 
--- a/gfx/layers/ipc/LayerTransactionParent.cpp
+++ b/gfx/layers/ipc/LayerTransactionParent.cpp
@@ -707,17 +707,17 @@ LayerTransactionParent::RecvGetAnimation
 
   Layer* layer = cast(aParent)->AsLayer();
   if (!layer) {
     return false;
   }
 
   // Make sure we apply the latest animation style or else we can end up with
   // a race between when we temporarily clear the animation transform (in
-  // CompositorParent::SetShadowProperties) and when animation recalculates
+  // CompositorBridgeParent::SetShadowProperties) and when animation recalculates
   // the value.
   mShadowLayersManager->ApplyAsyncProperties(this);
 
   // This method is specific to transforms applied by animation.
   // This is because this method uses the information stored with an animation
   // such as the origin of the reference frame corresponding to the layer, to
   // recover the untranslated transform from the shadow transform. For
   // transforms that are not set by animation we don't have this information
--- a/gfx/layers/ipc/LayerTransactionParent.h
+++ b/gfx/layers/ipc/LayerTransactionParent.h
@@ -168,18 +168,18 @@ protected:
     mIPCOpen = true;
     ADDREF_MANUALLY(this);
   }
   void ReleaseIPDLReference() {
     MOZ_ASSERT(mIPCOpen == true);
     mIPCOpen = false;
     RELEASE_MANUALLY(this);
   }
-  friend class CompositorParent;
-  friend class CrossProcessCompositorParent;
+  friend class CompositorBridgeParent;
+  friend class CrossProcessCompositorBridgeParent;
   friend class layout::RenderFrameParent;
 
 private:
   RefPtr<LayerManagerComposite> mLayerManager;
   ShadowLayersManager* mShadowLayersManager;
   // Hold the root because it might be grafted under various
   // containers in the "real" layer tree
   RefPtr<Layer> mRoot;
--- a/gfx/layers/ipc/RemoteContentController.cpp
+++ b/gfx/layers/ipc/RemoteContentController.cpp
@@ -9,17 +9,17 @@
 
 #include "base/message_loop.h"
 #include "base/task.h"
 #include "MainThreadUtils.h"
 #include "mozilla/dom/ContentParent.h"
 #include "mozilla/dom/TabParent.h"
 #include "mozilla/layers/APZCTreeManager.h"
 #include "mozilla/layers/APZThreadUtils.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/layout/RenderFrameParent.h"
 #include "mozilla/unused.h"
 #include "Units.h"
 #ifdef MOZ_WIDGET_ANDROID
 #include "AndroidBridge.h"
 #endif
 
 namespace mozilla {
@@ -366,21 +366,21 @@ RemoteContentController::ChildAdopted()
   MutexAutoLock lock(mMutex);
   mApzcTreeManager = nullptr;
 }
 
 already_AddRefed<APZCTreeManager>
 RemoteContentController::GetApzcTreeManager()
 {
   // We can't get a ref to the APZCTreeManager until after the child is
-  // created and the static getter knows which CompositorParent is
+  // created and the static getter knows which CompositorBridgeParent is
   // instantiated with this layers ID. That's why try to fetch it when
   // we first need it and cache the result.
   MutexAutoLock lock(mMutex);
   if (!mApzcTreeManager) {
-    mApzcTreeManager = CompositorParent::GetAPZCTreeManager(mLayersId);
+    mApzcTreeManager = CompositorBridgeParent::GetAPZCTreeManager(mLayersId);
   }
   RefPtr<APZCTreeManager> apzcTreeManager(mApzcTreeManager);
   return apzcTreeManager.forget();
 }
 
 } // namespace layers
 } // namespace mozilla
--- a/gfx/layers/moz.build
+++ b/gfx/layers/moz.build
@@ -150,19 +150,19 @@ EXPORTS.mozilla.layers += [
     'D3D11ShareHandleImage.h',
     'D3D9SurfaceImage.h',
     'Effects.h',
     'ImageDataSerializer.h',
     'ipc/APZChild.h',
     'ipc/AsyncTransactionTracker.h',
     'ipc/CompositableForwarder.h',
     'ipc/CompositableTransactionParent.h',
-    'ipc/CompositorChild.h',
+    'ipc/CompositorBridgeChild.h',
+    'ipc/CompositorBridgeParent.h',
     'ipc/CompositorLRU.h',
-    'ipc/CompositorParent.h',
     'ipc/FenceUtils.h',
     'ipc/GonkNativeHandle.h',
     'ipc/GonkNativeHandleUtils.h',
     'ipc/ImageBridgeChild.h',
     'ipc/ImageBridgeParent.h',
     'ipc/ImageContainerParent.h',
     'ipc/ISurfaceAllocator.h',
     'ipc/LayerAnimationUtils.h',
@@ -330,19 +330,19 @@ UNIFIED_SOURCES += [
     'FrameMetrics.cpp',
     'GLImages.cpp',
     'ImageDataSerializer.cpp',
     'ImageLayers.cpp',
     'ipc/APZChild.cpp',
     'ipc/AsyncTransactionTracker.cpp',
     'ipc/CompositableTransactionParent.cpp',
     'ipc/CompositorBench.cpp',
-    'ipc/CompositorChild.cpp',
+    'ipc/CompositorBridgeChild.cpp',
+    'ipc/CompositorBridgeParent.cpp',
     'ipc/CompositorLRU.cpp',
-    'ipc/CompositorParent.cpp',
     'ipc/FenceUtils.cpp',
     'ipc/ImageBridgeChild.cpp',
     'ipc/ImageBridgeParent.cpp',
     'ipc/ImageContainerParent.cpp',
     'ipc/ISurfaceAllocator.cpp',
     'ipc/LayerAnimationUtils.cpp',
     'ipc/LayerTransactionChild.cpp',
     'ipc/LayerTransactionParent.cpp',
--- a/gfx/tests/gtest/TestLayers.cpp
+++ b/gfx/tests/gtest/TestLayers.cpp
@@ -3,17 +3,17 @@
  * http://creativecommons.org/publicdomain/zero/1.0/
  */
 
 #include "TestLayers.h"
 #include "gtest/gtest.h"
 #include "gmock/gmock.h"
 #include "LayerUserData.h"
 #include "mozilla/layers/LayerMetricsWrapper.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 
 using namespace mozilla;
 using namespace mozilla::gfx;
 using namespace mozilla::layers;
 
 class TestContainerLayer: public ContainerLayer {
 public:
   explicit TestContainerLayer(LayerManager* aManager)
@@ -235,17 +235,17 @@ already_AddRefed<Layer> CreateLayerTree(
       lastLayer = layer;
     }
   }
   if (rootLayer) {
     rootLayer->ComputeEffectiveTransforms(Matrix4x4());
     manager->SetRoot(rootLayer);
     if (rootLayer->AsLayerComposite()) {
       // Only perform this for LayerManagerComposite
-      CompositorParent::SetShadowProperties(rootLayer);
+      CompositorBridgeParent::SetShadowProperties(rootLayer);
     }
   }
   return rootLayer.forget();
 }
 
 TEST(Layers, LayerTree) {
   const char* layerTreeSyntax = "c(c(tt))";
   nsIntRegion layerVisibleRegion[] = {
--- a/gfx/thebes/gfxAndroidPlatform.cpp
+++ b/gfx/thebes/gfxAndroidPlatform.cpp
@@ -26,17 +26,17 @@
 #include "VsyncSource.h"
 
 #ifdef MOZ_WIDGET_ANDROID
 #include "AndroidBridge.h"
 #endif
 
 #ifdef MOZ_WIDGET_GONK
 #include <cutils/properties.h>
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "HwcComposer2D.h"
 #endif
 
 #include "ft2build.h"
 #include FT_FREETYPE_H
 #include FT_MODULE_H
 
 using namespace mozilla;
--- a/gfx/thebes/gfxPlatform.cpp
+++ b/gfx/thebes/gfxPlatform.cpp
@@ -1,16 +1,16 @@
 /* -*- Mode: C++; tab-width: 20; indent-tabs-mode: nil; c-basic-offset: 2 -*-
  * This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "mozilla/layers/AsyncTransactionTracker.h" // for AsyncTransactionTracker
-#include "mozilla/layers/CompositorChild.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeChild.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/layers/ImageBridgeChild.h"
 #include "mozilla/layers/SharedBufferManagerChild.h"
 #include "mozilla/layers/ISurfaceAllocator.h"     // for GfxMemoryImageReporter
 #include "mozilla/Telemetry.h"
 #include "mozilla/TimeStamp.h"
 
 #include "mozilla/Logging.h"
 #include "mozilla/Services.h"
@@ -847,17 +847,17 @@ gfxPlatform::InitLayersIPC()
       return;
     }
     sLayersIPCIsUp = true;
 
     AsyncTransactionTrackersHolder::Initialize();
 
     if (XRE_IsParentProcess())
     {
-        mozilla::layers::CompositorParent::StartUp();
+        mozilla::layers::CompositorBridgeParent::StartUp();
 #ifdef MOZ_WIDGET_GONK
         SharedBufferManagerChild::StartUp();
 #endif
         mozilla::layers::ImageBridgeChild::StartUp();
         gfx::VRManagerChild::StartUpSameProcess();
     }
 }
 
@@ -866,25 +866,25 @@ gfxPlatform::ShutdownLayersIPC()
 {
     if (!sLayersIPCIsUp) {
       return;
     }
     sLayersIPCIsUp = false;
 
     if (XRE_IsParentProcess())
     {
-        // This must happen after the shutdown of media and widgets, which
-        // are triggered by the NS_XPCOM_SHUTDOWN_OBSERVER_ID notification.
-        gfx::VRManagerChild::ShutDown();
-        layers::ImageBridgeChild::ShutDown();
+      // This must happen after the shutdown of media and widgets, which
+      // are triggered by the NS_XPCOM_SHUTDOWN_OBSERVER_ID notification.
+      gfx::VRManagerChild::ShutDown();
+      layers::ImageBridgeChild::ShutDown();
 #ifdef MOZ_WIDGET_GONK
-        layers::SharedBufferManagerChild::ShutDown();
+      layers::SharedBufferManagerChild::ShutDown();
 #endif
 
-        layers::CompositorParent::ShutDown();
+      layers::CompositorBridgeParent::ShutDown();
 	} else if (XRE_GetProcessType() == GeckoProcessType_Content) {
 		gfx::VRManagerChild::ShutDown();
 	}
 }
 
 gfxPlatform::~gfxPlatform()
 {
     mScreenReferenceSurface = nullptr;
--- a/gfx/thebes/gfxPlatformMac.cpp
+++ b/gfx/thebes/gfxPlatformMac.cpp
@@ -21,17 +21,17 @@
 #include "mozilla/VsyncDispatcher.h"
 #include "qcms.h"
 #include "gfx2DGlue.h"
 
 #include <dlfcn.h>
 #include <CoreVideo/CoreVideo.h>
 
 #include "nsCocoaFeatures.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "VsyncSource.h"
 
 using namespace mozilla;
 using namespace mozilla::gfx;
 
 // cribbed from CTFontManager.h
 enum {
    kAutoActivationDisabled = 1
--- a/gfx/thebes/gfxWindowsPlatform.cpp
+++ b/gfx/thebes/gfxWindowsPlatform.cpp
@@ -32,17 +32,17 @@
 #include "nsIGfxInfo.h"
 #include "GfxDriverInfo.h"
 
 #include "gfxCrashReporterUtils.h"
 
 #include "gfxGDIFontList.h"
 #include "gfxGDIFont.h"
 
-#include "mozilla/layers/CompositorParent.h"   // for CompositorParent::IsInCompositorThread
+#include "mozilla/layers/CompositorBridgeParent.h"   // for CompositorBridgeParent::IsInCompositorThread
 #include "DeviceManagerD3D9.h"
 #include "mozilla/layers/ReadbackManagerD3D11.h"
 
 #include "WinUtils.h"
 
 #include "gfxDWriteFontList.h"
 #include "gfxDWriteFonts.h"
 #include "gfxDWriteCommon.h"
@@ -1384,17 +1384,17 @@ gfxWindowsPlatform::GetD3D9Device()
 
 DeviceManagerD3D9*
 gfxWindowsPlatform::GetD3D9DeviceManager()
 {
   // We should only create the d3d9 device on the compositor thread
   // or we don't have a compositor thread.
   if (!mDeviceManager &&
       (!gfxPlatform::UsesOffMainThreadCompositing() ||
-       CompositorParent::IsInCompositorThread())) {
+       CompositorBridgeParent::IsInCompositorThread())) {
     mDeviceManager = new DeviceManagerD3D9();
     if (!mDeviceManager->Init()) {
       gfxCriticalError() << "[D3D9] Could not Initialize the DeviceManagerD3D9";
       mDeviceManager = nullptr;
     }
   }
 
   return mDeviceManager;
--- a/gfx/vr/ipc/VRManagerChild.cpp
+++ b/gfx/vr/ipc/VRManagerChild.cpp
@@ -5,17 +5,17 @@
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "VRManagerChild.h"
 #include "VRManagerParent.h"
 #include "VRDeviceProxy.h"
 #include "VRDeviceProxyOrientationFallBack.h"
 #include "mozilla/StaticPtr.h"
-#include "mozilla/layers/CompositorParent.h" // for CompositorParent
+#include "mozilla/layers/CompositorBridgeParent.h" // for CompositorBridgeParent
 #include "mozilla/dom/Navigator.h"
 
 namespace mozilla {
 namespace gfx {
 
 static StaticRefPtr<VRManagerChild> sVRManagerChildSingleton;
 static StaticRefPtr<VRManagerParent> sVRManagerParentSingleton;
 
@@ -72,17 +72,17 @@ VRManagerChild::StartUpInChildProcess(Tr
 /*static*/ void
 VRManagerChild::StartUpSameProcess()
 {
   NS_ASSERTION(NS_IsMainThread(), "Should be on the main Thread!");
   if (sVRManagerChildSingleton == nullptr) {
     sVRManagerChildSingleton = new VRManagerChild();
     sVRManagerParentSingleton = VRManagerParent::CreateSameProcess();
     sVRManagerChildSingleton->Open(sVRManagerParentSingleton->GetIPCChannel(),
-                                   mozilla::layers::CompositorParent::CompositorLoop(),
+                                   mozilla::layers::CompositorBridgeParent::CompositorLoop(),
                                    mozilla::ipc::ChildSide);
   }
 }
 
 /*static*/ void
 VRManagerChild::ShutDown()
 {
   MOZ_ASSERT(NS_IsMainThread());
--- a/gfx/vr/ipc/VRManagerChild.h
+++ b/gfx/vr/ipc/VRManagerChild.h
@@ -41,22 +41,22 @@ protected:
   explicit VRManagerChild();
   ~VRManagerChild();
   void Destroy();
   static void DeferredDestroy(RefPtr<VRManagerChild> aVRManagerChild);
 
   virtual bool RecvUpdateDeviceInfo(nsTArray<VRDeviceUpdate>&& aDeviceUpdates) override;
   virtual bool RecvUpdateDeviceSensors(nsTArray<VRSensorUpdate>&& aDeviceSensorUpdates) override;
 
-  friend class layers::CompositorChild;
+  friend class layers::CompositorBridgeChild;
 
 private:
 
   nsTArray<RefPtr<VRDeviceProxy> > mDevices;
   nsTArray<dom::Navigator*> mNavigatorCallbacks;
 
   int32_t mInputFrameID;
 };
 
 } // namespace mozilla
 } // namespace gfx
 
-#endif // MOZILLA_GFX_VR_VRMANAGERCHILD_H
\ No newline at end of file
+#endif // MOZILLA_GFX_VR_VRMANAGERCHILD_H
--- a/gfx/vr/ipc/VRManagerParent.cpp
+++ b/gfx/vr/ipc/VRManagerParent.cpp
@@ -5,24 +5,24 @@
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "VRManagerParent.h"
 #include "mozilla/gfx/PVRManagerParent.h"
 #include "mozilla/ipc/ProtocolTypes.h"
 #include "mozilla/ipc/ProtocolUtils.h"       // for IToplevelProtocol
 #include "mozilla/TimeStamp.h"               // for TimeStamp
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/unused.h"
 #include "VRManager.h"
 
 namespace mozilla {
 namespace layers {
 
-// defined in CompositorParent.cpp
+// defined in CompositorBridgeParent.cpp
 CompositorThreadHolder* GetCompositorThreadHolder();
 
 } // namespace layers
 
 namespace gfx {
 
 VRManagerParent::VRManagerParent(MessageLoop* aLoop,
                                  Transport* aTransport,
@@ -71,17 +71,17 @@ VRManagerParent::ConnectVRManagerInParen
 {
   aVRManager->Open(aTransport, aOtherPid, XRE_GetIOMessageLoop(), ipc::ParentSide);
   aVRManager->RegisterWithManager();
 }
 
 /*static*/ VRManagerParent*
 VRManagerParent::CreateCrossProcess(Transport* aTransport, ProcessId aChildProcessId)
 {
-  MessageLoop* loop = mozilla::layers::CompositorParent::CompositorLoop();
+  MessageLoop* loop = mozilla::layers::CompositorBridgeParent::CompositorLoop();
   RefPtr<VRManagerParent> vmp = new VRManagerParent(loop, aTransport, aChildProcessId);
   vmp->mSelfRef = vmp;
   loop->PostTask(FROM_HERE,
                  NewRunnableFunction(ConnectVRManagerInParentProcess,
                                      vmp.get(), aTransport, aChildProcessId));
   return vmp.get();
 }
 
@@ -89,17 +89,17 @@ VRManagerParent::CreateCrossProcess(Tran
 VRManagerParent::RegisterVRManagerInCompositorThread(VRManagerParent* aVRManager)
 {
   aVRManager->RegisterWithManager();
 }
 
 /*static*/ VRManagerParent*
 VRManagerParent::CreateSameProcess()
 {
-  MessageLoop* loop = mozilla::layers::CompositorParent::CompositorLoop();
+  MessageLoop* loop = mozilla::layers::CompositorBridgeParent::CompositorLoop();
   RefPtr<VRManagerParent> vmp = new VRManagerParent(loop, nullptr, base::GetCurrentProcId());
   vmp->mCompositorThreadHolder = layers::GetCompositorThreadHolder();
   vmp->mSelfRef = vmp;
   loop->PostTask(FROM_HERE,
                  NewRunnableFunction(RegisterVRManagerInCompositorThread, vmp.get()));
   return vmp.get();
 }
 
--- a/gfx/vr/ipc/VRManagerParent.h
+++ b/gfx/vr/ipc/VRManagerParent.h
@@ -3,17 +3,17 @@
  */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef MOZILLA_GFX_VR_VRMANAGERPARENT_H
 #define MOZILLA_GFX_VR_VRMANAGERPARENT_H
 
-#include "mozilla/layers/CompositorParent.h" // for CompositorThreadHolder
+#include "mozilla/layers/CompositorBridgeParent.h" // for CompositorThreadHolder
 #include "mozilla/gfx/PVRManagerParent.h" // for PVRManagerParent
 #include "mozilla/ipc/ProtocolUtils.h"    // for IToplevelProtocol
 #include "mozilla/TimeStamp.h"            // for TimeStamp
 #include "gfxVR.h"                        // for VRFieldOfView
 
 namespace mozilla {
 namespace gfx {
 
--- a/layout/base/nsPresShell.cpp
+++ b/layout/base/nsPresShell.cpp
@@ -154,17 +154,17 @@
 #include "nsMenuPopupFrame.h"
 #include "nsITreeColumns.h"
 #include "nsIDOMXULMultSelectCntrlEl.h"
 #include "nsIDOMXULSelectCntrlItemEl.h"
 #include "nsIDOMXULMenuListElement.h"
 
 #endif
 
-#include "mozilla/layers/CompositorChild.h"
+#include "mozilla/layers/CompositorBridgeChild.h"
 #include "GeckoProfiler.h"
 #include "gfxPlatform.h"
 #include "Layers.h"
 #include "LayerTreeInvalidation.h"
 #include "mozilla/css/ImageLoader.h"
 #include "mozilla/dom/DocumentTimeline.h"
 #include "mozilla/Preferences.h"
 #include "mozilla/Telemetry.h"
@@ -5680,28 +5680,28 @@ NotifyCompositorOfVisibleRegionsChange(P
   TabChild* tabChild = TabChild::GetFrom(aPresShell);
   if (!tabChild) {
     return;
   }
 
   const uint64_t layersId = tabChild->LayersId();
   const uint32_t presShellId = aPresShell->GetPresShellId();
 
-  // Retrieve the CompositorChild.
+  // Retrieve the CompositorBridgeChild.
   LayerManager* layerManager = aPresShell->GetLayerManager();
   if (!layerManager) {
     return;
   }
 
   ClientLayerManager* clientLayerManager = layerManager->AsClientLayerManager();
   if (!clientLayerManager) {
     return;
   }
 
-  CompositorChild* compositorChild = clientLayerManager->GetCompositorChild();
+  CompositorBridgeChild* compositorChild = clientLayerManager->GetCompositorBridgeChild();
   if (!compositorChild) {
     return;
   }
 
   // Clear the old approximately visible regions associated with this document.
   compositorChild->SendClearApproximatelyVisibleRegions(layersId, presShellId);
 
   // Send the new approximately visible regions to the compositor.
--- a/layout/ipc/RenderFrameParent.cpp
+++ b/layout/ipc/RenderFrameParent.cpp
@@ -15,29 +15,29 @@
 #include "mozilla/BrowserElementParent.h"
 #include "mozilla/EventForwards.h"  // for Modifiers
 #include "mozilla/dom/ContentChild.h"
 #include "mozilla/dom/ContentParent.h"
 #include "mozilla/dom/TabChild.h"
 #include "mozilla/dom/TabParent.h"
 #include "mozilla/layers/APZCTreeManager.h"
 #include "mozilla/layers/APZThreadUtils.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/layers/LayerTransactionParent.h"
 #include "nsContentUtils.h"
 #include "nsFocusManager.h"
 #include "nsFrameLoader.h"
 #include "nsIObserver.h"
 #include "nsStyleStructInlines.h"
 #include "nsSubDocumentFrame.h"
 #include "nsView.h"
 #include "nsViewportFrame.h"
 #include "RenderFrameParent.h"
 #include "mozilla/layers/LayerManagerComposite.h"
-#include "mozilla/layers/CompositorChild.h"
+#include "mozilla/layers/CompositorBridgeChild.h"
 #include "ClientLayerManager.h"
 #include "FrameLayerBuilder.h"
 
 using namespace mozilla::dom;
 using namespace mozilla::gfx;
 using namespace mozilla::layers;
 
 namespace mozilla {
@@ -119,17 +119,17 @@ RenderFrameParent::RenderFrameParent(nsF
     browser->Manager()->AsContentParent()->AllocateLayerTreeId(browser, aId);
     mLayersId = *aId;
     if (lm && lm->AsClientLayerManager()) {
       lm->AsClientLayerManager()->GetRemoteRenderer()->SendNotifyChildCreated(mLayersId);
     }
   } else if (XRE_IsContentProcess()) {
     ContentChild::GetSingleton()->SendAllocateLayerTreeId(browser->Manager()->ChildID(), browser->GetTabId(), aId);
     mLayersId = *aId;
-    CompositorChild::Get()->SendNotifyChildCreated(mLayersId);
+    CompositorBridgeChild::Get()->SendNotifyChildCreated(mLayersId);
   }
   *aSuccess = true;
 }
 
 RenderFrameParent::~RenderFrameParent()
 {}
 
 void
@@ -212,17 +212,17 @@ RenderFrameParent::OwnerContentChanged(n
 
 void
 RenderFrameParent::ActorDestroy(ActorDestroyReason why)
 {
   if (mLayersId != 0) {
     if (XRE_IsContentProcess()) {
       ContentChild::GetSingleton()->SendDeallocateLayerTreeId(mLayersId);
     } else {
-      CompositorParent::DeallocateLayerTreeId(mLayersId);
+      CompositorBridgeParent::DeallocateLayerTreeId(mLayersId);
     }
   }
 
   mFrameLoader = nullptr;
 }
 
 bool
 RenderFrameParent::RecvNotifyCompositorTransaction()
--- a/testing/mozbase/mozleak/mozleak/leaklog.py
+++ b/testing/mozbase/mozleak/mozleak/leaklog.py
@@ -47,33 +47,33 @@ def expectedTabProcessLeakCounts():
         'WaitableEventKernel': 1,
         'WeakReference<MessageListener>': 1,
         'base::Thread': 1,
         'ipc::MessageChannel': 1,
         'nsTArray_base': 7,
         'nsThread': 1,
     })
 
-    # Bug 1215265 - CompositorChild is not shut down.
+    # Bug 1215265 - CompositorBridgeChild is not shut down.
     appendExpectedLeakCounts({
-        'CompositorChild': 1,
+        'CompositorBridgeChild': 1,
         'CondVar': 1,
         'IPC::Channel': 1,
         'Mutex': 1,
-        'PCompositorChild': 1,
+        'PCompositorBridgeChild': 1,
         'RefCountedMonitor': 1,
         'RefCountedTask': 2,
         'StoreRef': 1,
         'WeakReference<MessageListener>': 1,
         'ipc::MessageChannel': 1,
         'nsTArray_base': 2,
     })
 
     # Bug 1215265 - Windows-specific graphics leaks, maybe related to
-    # CompositorChild and/or ImageBridgeChild not being shut down.
+    # CompositorBridgeChild and/or ImageBridgeChild not being shut down.
     if mozinfo.isWin:
         # Windows leaks comment to all content processes.
         # 2696 bytes leaked total on Win7.
         appendExpectedLeakCounts({
             'AsyncTransactionTrackersHolder': 1,
             'CompositableChild': 1,
             'Mutex': 1,
             'PCompositableChild': 1,
--- a/widget/VsyncDispatcher.cpp
+++ b/widget/VsyncDispatcher.cpp
@@ -3,17 +3,17 @@
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "MainThreadUtils.h"
 #include "VsyncDispatcher.h"
 #include "VsyncSource.h"
 #include "gfxPlatform.h"
 #include "mozilla/layers/Compositor.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 
 #ifdef MOZ_ENABLE_PROFILER_SPS
 #include "GeckoProfiler.h"
 #include "ProfilerMarkers.h"
 #endif
 
 namespace mozilla {
 static bool sThreadAssertionsEnabled = true;
@@ -39,17 +39,17 @@ CompositorVsyncDispatcher::~CompositorVs
   // We auto remove this vsync dispatcher from the vsync source in the nsBaseWidget
 }
 
 void
 CompositorVsyncDispatcher::NotifyVsync(TimeStamp aVsyncTimestamp)
 {
   // In vsync thread
 #ifdef MOZ_ENABLE_PROFILER_SPS
-  layers::CompositorParent::PostInsertVsyncProfilerMarker(aVsyncTimestamp);
+  layers::CompositorBridgeParent::PostInsertVsyncProfilerMarker(aVsyncTimestamp);
 #endif
 
   MutexAutoLock lock(mCompositorObserverLock);
   if (mCompositorVsyncObserver) {
     mCompositorVsyncObserver->NotifyVsync(aVsyncTimestamp);
   }
 }
 
@@ -95,17 +95,17 @@ CompositorVsyncDispatcher::SetCompositor
   NS_DispatchToMainThread(vsyncControl);
 }
 
 void
 CompositorVsyncDispatcher::Shutdown()
 {
   // Need to explicitly remove CompositorVsyncDispatcher when the nsBaseWidget shuts down.
   // Otherwise, we would get dead vsync notifications between when the nsBaseWidget
-  // shuts down and the CompositorParent shuts down.
+  // shuts down and the CompositorBridgeParent shuts down.
   MOZ_ASSERT(XRE_IsParentProcess());
   MOZ_ASSERT(NS_IsMainThread());
   ObserveVsync(false);
   mDidShutdown = true;
   { // scope lock
     MutexAutoLock lock(mCompositorObserverLock);
     mCompositorVsyncObserver = nullptr;
   }
--- a/widget/android/AndroidBridge.cpp
+++ b/widget/android/AndroidBridge.cpp
@@ -3,18 +3,18 @@
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include <android/log.h>
 #include <dlfcn.h>
 #include <math.h>
 #include <GLES2/gl2.h>
 
-#include "mozilla/layers/CompositorChild.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeChild.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 
 #include "mozilla/Hal.h"
 #include "nsXULAppAPI.h"
 #include <prthread.h>
 #include "nsXPCOMStrings.h"
 #include "AndroidBridge.h"
 #include "AndroidJNIWrapper.h"
 #include "AndroidBridgeUtilities.h"
--- a/widget/android/nsWindow.cpp
+++ b/widget/android/nsWindow.cpp
@@ -84,18 +84,18 @@ using mozilla::Unused;
 
 using namespace mozilla;
 using namespace mozilla::dom;
 using namespace mozilla::widget;
 using namespace mozilla::layers;
 
 NS_IMPL_ISUPPORTS_INHERITED0(nsWindow, nsBaseWidget)
 
-#include "mozilla/layers/CompositorChild.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeChild.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/layers/LayerTransactionParent.h"
 #include "mozilla/Mutex.h"
 #include "mozilla/Services.h"
 #include "nsThreadUtils.h"
 
 // All the toplevel windows that have been created; these are in
 // stacking order, so the window at gTopLevelWindows[0] is the topmost
 // one.
@@ -445,17 +445,17 @@ public:
 
         MutexAutoLock lock(mWindowLock);
         if (!mWindow) {
             // We already shut down.
             return;
         }
 
         RefPtr<APZCTreeManager> controller = mWindow->mAPZC;
-        RefPtr<CompositorParent> compositor = mWindow->mCompositorParent;
+        RefPtr<CompositorBridgeParent> compositor = mWindow->mCompositorBridgeParent;
         if (controller && compositor) {
             // TODO: Pass in correct values for presShellId and viewId.
             controller->CancelAnimation(ScrollableLayerGuid(
                     compositor->RootLayerTreeId(), 0, 0));
         }
     }
 
     void AdjustScrollForSurfaceShift(float aX, float aY)
@@ -1003,18 +1003,18 @@ public:
         const bool resetting = !!mLayerClient;
         mLayerClient = layerClient;
         layerClient->OnGeckoReady();
 
         if (resetting) {
             // Since we are re-linking the new java objects to Gecko, we need
             // to get the viewport from the compositor (since the Java copy was
             // thrown away) and we do that by setting the first-paint flag.
-            if (window.mCompositorParent) {
-                window.mCompositorParent->ForceIsFirstPaint();
+            if (window.mCompositorBridgeParent) {
+                window.mCompositorBridgeParent->ForceIsFirstPaint();
             }
         }
 
 #ifdef MOZ_ANDROID_APZ
         MOZ_ASSERT(aNPZC);
         auto npzc = NativePanZoomController::LocalRef(
                 jni::GetGeckoThreadEnv(),
                 NativePanZoomController::Ref::From(aNPZC));
@@ -1041,51 +1041,51 @@ public:
     }
 
     void PauseCompositor()
     {
         // The compositor gets paused when the app is about to go into the
         // background. While the compositor is paused, we need to ensure that
         // no layer tree updates (from draw events) occur, since the compositor
         // cannot make a GL context current in order to process updates.
-        if (window.mCompositorChild) {
-            window.mCompositorChild->SendPause();
+        if (window.mCompositorBridgeChild) {
+            window.mCompositorBridgeChild->SendPause();
         }
         mCompositorPaused = true;
     }
 
     void SyncPauseCompositor()
     {
-        if (window.mCompositorParent) {
-            window.mCompositorParent->SchedulePauseOnCompositorThread();
+        if (window.mCompositorBridgeParent) {
+            window.mCompositorBridgeParent->SchedulePauseOnCompositorThread();
             mCompositorPaused = true;
         }
     }
 
     void SyncResumeCompositor()
     {
-        if (window.mCompositorParent &&
-                window.mCompositorParent->ScheduleResumeOnCompositorThread()) {
+        if (window.mCompositorBridgeParent &&
+                window.mCompositorBridgeParent->ScheduleResumeOnCompositorThread()) {
             mCompositorPaused = false;
         }
     }
 
     void SyncResumeResizeCompositor(int32_t aWidth, int32_t aHeight)
     {
-        if (window.mCompositorParent && window.mCompositorParent->
+        if (window.mCompositorBridgeParent && window.mCompositorBridgeParent->
                 ScheduleResumeOnCompositorThread(aWidth, aHeight)) {
             mCompositorPaused = false;
         }
     }
 
     void SyncInvalidateAndScheduleComposite()
     {
-        if (window.mCompositorParent) {
-            window.mCompositorParent->InvalidateOnCompositorThread();
-            window.mCompositorParent->ScheduleRenderOnCompositorThread();
+        if (window.mCompositorBridgeParent) {
+            window.mCompositorBridgeParent->InvalidateOnCompositorThread();
+            window.mCompositorBridgeParent->ScheduleRenderOnCompositorThread();
         }
     }
 };
 
 nsWindow::GeckoViewSupport::~GeckoViewSupport()
 {
     // Disassociate our GeckoEditable instance with our native object.
     // OnDestroy will call disposeNative after any pending native calls have
@@ -3478,18 +3478,18 @@ nsWindow::ScheduleResumeComposition()
     if (gGeckoViewWindow && gGeckoViewWindow->mGLControllerSupport) {
         return gGeckoViewWindow->mGLControllerSupport->SyncResumeCompositor();
     }
 }
 
 float
 nsWindow::ComputeRenderIntegrity()
 {
-    if (gGeckoViewWindow && gGeckoViewWindow->mCompositorParent) {
-        return gGeckoViewWindow->mCompositorParent->ComputeRenderIntegrity();
+    if (gGeckoViewWindow && gGeckoViewWindow->mCompositorBridgeParent) {
+        return gGeckoViewWindow->mCompositorBridgeParent->ComputeRenderIntegrity();
     }
 
     return 1.f;
 }
 
 bool
 nsWindow::WidgetPaintsBackground()
 {
@@ -3512,20 +3512,20 @@ nsWindow::NeedsPaint()
     if (!mGLControllerSupport || mGLControllerSupport->CompositorPaused() ||
             // FindTopLevel() != nsWindow::TopWindow() ||
             !GetLayerManager(nullptr)) {
         return false;
     }
     return nsIWidget::NeedsPaint();
 }
 
-CompositorParent*
-nsWindow::NewCompositorParent(int aSurfaceWidth, int aSurfaceHeight)
+CompositorBridgeParent*
+nsWindow::NewCompositorBridgeParent(int aSurfaceWidth, int aSurfaceHeight)
 {
-    return new CompositorParent(this, true, aSurfaceWidth, aSurfaceHeight);
+    return new CompositorBridgeParent(this, true, aSurfaceWidth, aSurfaceHeight);
 }
 
 void
 nsWindow::ConfigureAPZControllerThread()
 {
     APZThreadUtils::SetControllerThread(nullptr);
 }
 
--- a/widget/android/nsWindow.h
+++ b/widget/android/nsWindow.h
@@ -20,18 +20,18 @@
 struct ANPEvent;
 
 namespace mozilla {
     class AndroidGeckoEvent;
     class TextComposition;
     class WidgetTouchEvent;
 
     namespace layers {
-        class CompositorParent;
-        class CompositorChild;
+        class CompositorBridgeParent;
+        class CompositorBridgeChild;
         class LayerManager;
         class APZCTreeManager;
     }
 }
 
 class nsWindow :
     public nsBaseWidget
 {
@@ -165,17 +165,18 @@ public:
                                   bool* aAllowRetaining = nullptr) override;
 
     NS_IMETHOD ReparentNativeWidget(nsIWidget* aNewParent) override;
 
     virtual bool NeedsPaint() override;
     virtual void DrawWindowUnderlay(LayerManagerComposite* aManager, LayoutDeviceIntRect aRect) override;
     virtual void DrawWindowOverlay(LayerManagerComposite* aManager, LayoutDeviceIntRect aRect) override;
 
-    virtual mozilla::layers::CompositorParent* NewCompositorParent(int aSurfaceWidth, int aSurfaceHeight) override;
+    virtual mozilla::layers::CompositorBridgeParent* NewCompositorBridgeParent(
+      int aSurfaceWidth, int aSurfaceHeight) override;
 
     static bool IsCompositionPaused();
     static void InvalidateAndScheduleComposite();
     static void SchedulePauseComposition();
     static void ScheduleResumeComposition();
     static float ComputeRenderIntegrity();
 
     virtual bool WidgetPaintsBackground() override;
--- a/widget/cocoa/nsChildView.mm
+++ b/widget/cocoa/nsChildView.mm
@@ -59,17 +59,17 @@
 #include "GLContextCGL.h"
 #include "GLUploadHelpers.h"
 #include "ScopedGLHelpers.h"
 #include "HeapCopyOfStackArray.h"
 #include "mozilla/layers/APZCTreeManager.h"
 #include "mozilla/layers/APZThreadUtils.h"
 #include "mozilla/layers/GLManager.h"
 #include "mozilla/layers/CompositorOGL.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/layers/BasicCompositor.h"
 #include "mozilla/layers/InputAPZContext.h"
 #include "gfxUtils.h"
 #include "gfxPrefs.h"
 #include "mozilla/gfx/2D.h"
 #include "mozilla/gfx/BorrowedContext.h"
 #ifdef ACCESSIBILITY
 #include "nsAccessibilityService.h"
@@ -1890,17 +1890,17 @@ NSView<mozView>* nsChildView::GetEditorV
 }
 
 #pragma mark -
 
 void
 nsChildView::CreateCompositor()
 {
   nsBaseWidget::CreateCompositor();
-  if (mCompositorChild) {
+  if (mCompositorBridgeChild) {
     [(ChildView *)mView setUsingOMTCompositor:true];
   }
 }
 
 void
 nsChildView::ConfigureAPZCTreeManager()
 {
   nsBaseWidget::ConfigureAPZCTreeManager();
--- a/widget/gonk/GeckoTouchDispatcher.cpp
+++ b/widget/gonk/GeckoTouchDispatcher.cpp
@@ -24,17 +24,17 @@
 #include "gfxPrefs.h"
 #include "libui/Input.h"
 #include "mozilla/ClearOnShutdown.h"
 #include "mozilla/Mutex.h"
 #include "mozilla/TimeStamp.h"
 #include "mozilla/TouchEvents.h"
 #include "mozilla/dom/Touch.h"
 #include "mozilla/layers/APZThreadUtils.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "nsAppShell.h"
 #include "nsDebug.h"
 #include "nsThreadUtils.h"
 #include "nsWindow.h"
 #include <sys/types.h>
 #include <unistd.h>
 #include <utils/Timers.h>
 
@@ -83,17 +83,17 @@ GeckoTouchDispatcher::GeckoTouchDispatch
   mOldTouchThreshold = TimeDuration::FromMilliseconds(gfxPrefs::TouchResampleOldTouchThreshold());
   mDelayedVsyncThreshold = TimeDuration::FromMilliseconds(gfxPrefs::TouchResampleVsyncDelayThreshold());
 }
 
 void
 GeckoTouchDispatcher::SetCompositorVsyncScheduler(mozilla::layers::CompositorVsyncScheduler *aObserver)
 {
   MOZ_ASSERT(NS_IsMainThread());
-  // We assume on b2g that there is only 1 CompositorParent
+  // We assume on b2g that there is only 1 CompositorBridgeParent
   MOZ_ASSERT(mCompositorVsyncScheduler == nullptr);
   mCompositorVsyncScheduler = aObserver;
 }
 
 void
 GeckoTouchDispatcher::NotifyVsync(TimeStamp aVsyncTimestamp)
 {
   layers::APZThreadUtils::AssertOnControllerThread();
--- a/widget/gonk/HwcComposer2D.cpp
+++ b/widget/gonk/HwcComposer2D.cpp
@@ -21,17 +21,17 @@
 
 #include "gfxPrefs.h"
 #include "ImageLayers.h"
 #include "libdisplay/GonkDisplay.h"
 #include "HwcComposer2D.h"
 #include "LayerScope.h"
 #include "Units.h"
 #include "mozilla/ClearOnShutdown.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/layers/LayerManagerComposite.h"
 #include "mozilla/layers/PLayerTransaction.h"
 #include "mozilla/layers/ShadowLayerUtilsGralloc.h"
 #include "mozilla/layers/TextureHostOGL.h"  // for TextureHostOGL
 #include "mozilla/StaticPtr.h"
 #include "nsThreadUtils.h"
 #include "cutils/properties.h"
 #include "gfx2DGlue.h"
@@ -195,18 +195,18 @@ void
 HwcComposer2D::Invalidate()
 {
     if (!mHal->HasHwc()) {
         LOGE("HwcComposer2D::Invalidate failed!");
         return;
     }
 
     MutexAutoLock lock(mLock);
-    if (mCompositorParent) {
-        mCompositorParent->ScheduleRenderOnCompositorThread();
+    if (mCompositorBridgeParent) {
+        mCompositorBridgeParent->ScheduleRenderOnCompositorThread();
     }
 }
 
 namespace {
 class HotplugEvent : public nsRunnable {
 public:
     HotplugEvent(GonkDisplay::DisplayType aType, bool aConnected)
         : mType(aType)
@@ -234,20 +234,20 @@ private:
 void
 HwcComposer2D::Hotplug(int aDisplay, int aConnected)
 {
     NS_DispatchToMainThread(new HotplugEvent(GonkDisplay::DISPLAY_EXTERNAL,
                                              aConnected));
 }
 
 void
-HwcComposer2D::SetCompositorParent(CompositorParent* aCompositorParent)
+HwcComposer2D::SetCompositorBridgeParent(CompositorBridgeParent* aCompositorBridgeParent)
 {
     MutexAutoLock lock(mLock);
-    mCompositorParent = aCompositorParent;
+    mCompositorBridgeParent = aCompositorBridgeParent;
 }
 
 bool
 HwcComposer2D::ReallocLayerList()
 {
     int size = sizeof(HwcList) +
         ((mMaxLayerCount + LAYER_COUNT_INCREMENTS) * sizeof(HwcLayer));
 
--- a/widget/gonk/HwcComposer2D.h
+++ b/widget/gonk/HwcComposer2D.h
@@ -36,17 +36,17 @@ class nsScreenGonk;
 
 namespace mozilla {
 
 namespace gl {
     class GLContext;
 }
 
 namespace layers {
-class CompositorParent;
+class CompositorBridgeParent;
 class Layer;
 }
 
 /*
  * HwcComposer2D provides a way for gecko to render frames
  * using hwcomposer.h in the AOSP HAL.
  *
  * hwcomposer.h defines an interface for display composition
@@ -81,17 +81,17 @@ public:
 
     virtual bool HasHwc() override { return mHal->HasHwc(); }
 
     bool EnableVsync(bool aEnable);
     bool RegisterHwcEventCallback();
     void Vsync(int aDisplay, int64_t aTimestamp);
     void Invalidate();
     void Hotplug(int aDisplay, int aConnected);
-    void SetCompositorParent(layers::CompositorParent* aCompositorParent);
+    void SetCompositorBridgeParent(layers::CompositorBridgeParent* aCompositorBridgeParent);
 
 private:
     void Reset();
     void Prepare(buffer_handle_t dispHandle, int fence, nsScreenGonk* screen);
     bool Commit(nsScreenGonk* aScreen);
     bool TryHwComposition(nsScreenGonk* aScreen);
     bool ReallocLayerList();
     bool PrepareLayerList(layers::Layer* aContainer, const nsIntRect& aClip,
@@ -109,15 +109,15 @@ private:
     //to render the current frame
     std::list<HwcUtils::RectVector>   mVisibleRegions;
     layers::FenceHandle mPrevRetireFence;
     layers::FenceHandle mPrevDisplayFence;
     nsTArray<HwcLayer>      mCachedSidebandLayers;
     nsTArray<layers::LayerComposite*> mHwcLayerMap;
     bool                    mPrepared;
     bool                    mHasHWVsync;
-    layers::CompositorParent* mCompositorParent;
+    layers::CompositorBridgeParent* mCompositorBridgeParent;
     Mutex mLock;
 };
 
 } // namespace mozilla
 
 #endif // mozilla_HwcComposer2D
--- a/widget/gonk/nativewindow/FakeSurfaceComposer.cpp
+++ b/widget/gonk/nativewindow/FakeSurfaceComposer.cpp
@@ -36,17 +36,17 @@
 #endif
 
 #include "../libdisplay/GonkDisplay.h"
 #include "../nsScreenManagerGonk.h"
 #include "FakeSurfaceComposer.h"
 #include "gfxPrefs.h"
 #include "MainThreadUtils.h"
 #include "mozilla/Assertions.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "nsProxyRelease.h"
 #include "nsThreadUtils.h"
 
 using namespace mozilla;
 
 namespace android {
 
 /* static */
@@ -519,17 +519,17 @@ FakeSurfaceComposer::captureScreenImp(co
             } else {
                 result = BAD_VALUE;
             }
             native_window_api_disconnect(window, NATIVE_WINDOW_API_EGL);
             static_cast<GraphicProducerWrapper*>(producer->asBinder().get())->exit(result);
             NS_ReleaseOnMainThread(screenAlias.forget());
         });
 
-    mozilla::layers::CompositorParent::CompositorLoop()->PostTask(
+    mozilla::layers::CompositorBridgeParent::CompositorLoop()->PostTask(
         FROM_HERE, new RunnableCallTask(runnable));
 }
 
 #if ANDROID_VERSION >= 21
 void
 FakeSurfaceComposer::setPowerMode(const sp<IBinder>& display, int mode)
 {
 }
--- a/widget/gonk/nsAppShell.cpp
+++ b/widget/gonk/nsAppShell.cpp
@@ -67,17 +67,17 @@
 #include "ipc/Nuwa.h"
 #endif
 
 #include "mozilla/Preferences.h"
 #include "GeckoProfiler.h"
 
 // Defines kKeyMapping and GetKeyNameIndex()
 #include "GonkKeyMapping.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "GeckoTouchDispatcher.h"
 
 #undef LOG
 #define LOG(args...)                                            \
     __android_log_print(ANDROID_LOG_INFO, "Gonk" , ## args)
 #ifdef VERBOSE_LOG_ENABLED
 # define VERBOSE_LOG(args...)                           \
     __android_log_print(ANDROID_LOG_INFO, "Gonk" , ## args)
--- a/widget/gonk/nsScreenManagerGonk.cpp
+++ b/widget/gonk/nsScreenManagerGonk.cpp
@@ -23,17 +23,17 @@
 #include "libdisplay/BootAnimation.h"
 #include "libdisplay/GonkDisplay.h"
 #include "nsScreenManagerGonk.h"
 #include "nsThreadUtils.h"
 #include "HwcComposer2D.h"
 #include "VsyncSource.h"
 #include "nsWindow.h"
 #include "mozilla/ClearOnShutdown.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/Services.h"
 #include "mozilla/ProcessPriorityManager.h"
 #include "nsIdleService.h"
 #include "nsIObserverService.h"
 #include "nsAppShell.h"
 #include "nsProxyRelease.h"
 #include "nsTArray.h"
 #include "pixelflinger/format.h"
@@ -148,25 +148,25 @@ nsScreenGonk::nsScreenGonk(uint32_t aId,
         mPhysicalScreenRotation = atoi(propValue) / 90;
     }
 
     mColorDepth = SurfaceFormatToColorDepth(mSurfaceFormat);
 }
 
 static void
 ReleaseGLContextSync(mozilla::gl::GLContext* aGLContext) {
-    MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+    MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
     aGLContext->Release();
 }
 
 nsScreenGonk::~nsScreenGonk()
 {
     // Release GLContext on compositor thread
     if (mGLContext) {
-        CompositorParent::CompositorLoop()->PostTask(
+        CompositorBridgeParent::CompositorLoop()->PostTask(
             FROM_HERE,
             NewRunnableFunction(&ReleaseGLContextSync,
                                 mGLContext.forget().take()));
         mGLContext = nullptr;
     }
 }
 
 bool
@@ -418,17 +418,17 @@ NeedsRBSwap(int aHalFormat)
         MOZ_CRASH("Unhandled HAL pixel format");
         return false; // not reached
     }
 }
 
 already_AddRefed<DrawTarget>
 nsScreenGonk::StartRemoteDrawing()
 {
-    MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+    MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
     MOZ_ASSERT(!mFramebuffer);
     MOZ_ASSERT(!mMappedBuffer);
 
     mFramebuffer = DequeueBuffer();
     int width = mFramebuffer->width, height = mFramebuffer->height;
     if (gralloc_module()->lock(gralloc_module(), mFramebuffer->handle,
                                GRALLOC_USAGE_SW_READ_NEVER |
                                GRALLOC_USAGE_SW_WRITE_OFTEN |
@@ -456,17 +456,17 @@ nsScreenGonk::StartRemoteDrawing()
     }
     RefPtr<DrawTarget> buffer(mBackBuffer);
     return buffer.forget();
 }
 
 void
 nsScreenGonk::EndRemoteDrawing()
 {
-    MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+    MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
 
     if (mFramebufferTarget && mFramebuffer) {
         IntSize size = mFramebufferTarget->GetSize();
         Rect rect(0, 0, size.width, size.height);
         RefPtr<SourceSurface> source = mBackBuffer->Snapshot();
         mFramebufferTarget->DrawSurface(source, rect, rect);
 
         // Convert from BGR to RGB
@@ -523,20 +523,20 @@ nsScreenGonk::QueueBuffer(ANativeWindowB
   int ret = mNativeWindow->queueBuffer(mNativeWindow.get(), buf);
   return ret == 0;
 #endif
 }
 
 nsresult
 nsScreenGonk::MakeSnapshot(ANativeWindowBuffer* aBuffer)
 {
-    MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+    MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
     MOZ_ASSERT(aBuffer);
 
-    layers::CompositorParent* compositorParent = mCompositorParent;
+    layers::CompositorBridgeParent* compositorParent = mCompositorBridgeParent;
     if (!compositorParent) {
         return NS_ERROR_FAILURE;
     }
 
     int width = aBuffer->width, height = aBuffer->height;
     uint8_t* mappedBuffer = nullptr;
     if (gralloc_module()->lock(gralloc_module(), aBuffer->handle,
                                GRALLOC_USAGE_SW_READ_OFTEN |
@@ -571,20 +571,20 @@ nsScreenGonk::MakeSnapshot(ANativeWindow
             aBuffer->stride * aBuffer->height * gfx::BytesPerPixel(format));
         mappedBuffer = nullptr;
     }
     gralloc_module()->unlock(gralloc_module(), aBuffer->handle);
     return NS_OK;
 }
 
 void
-nsScreenGonk::SetCompositorParent(layers::CompositorParent* aCompositorParent)
+nsScreenGonk::SetCompositorBridgeParent(layers::CompositorBridgeParent* aCompositorBridgeParent)
 {
     MOZ_ASSERT(NS_IsMainThread());
-    mCompositorParent = aCompositorParent;
+    mCompositorBridgeParent = aCompositorBridgeParent;
 }
 
 #if ANDROID_VERSION >= 17
 android::DisplaySurface*
 nsScreenGonk::GetDisplaySurface()
 {
     return mDisplaySurface.get();
 }
@@ -605,48 +605,48 @@ nsScreenGonk::GetDisplayType()
     return mDisplayType;
 }
 
 void
 nsScreenGonk::SetEGLInfo(hwc_display_t aDisplay,
                          hwc_surface_t aSurface,
                          gl::GLContext* aGLContext)
 {
-    MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+    MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
     mEGLDisplay = aDisplay;
     mEGLSurface = aSurface;
     mGLContext = aGLContext;
 }
 
 hwc_display_t
 nsScreenGonk::GetEGLDisplay()
 {
-    MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+    MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
     return mEGLDisplay;
 }
 
 hwc_surface_t
 nsScreenGonk::GetEGLSurface()
 {
-    MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+    MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
     return mEGLSurface;
 }
 
 already_AddRefed<mozilla::gl::GLContext>
 nsScreenGonk::GetGLContext()
 {
-    MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+    MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
     RefPtr<mozilla::gl::GLContext>glContext = mGLContext;
     return glContext.forget();
 }
 
 static void
 UpdateMirroringWidgetSync(nsMainThreadPtrHandle<nsScreenGonk>&& aScreen, nsWindow* aWindow)
 {
-    MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+    MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
     already_AddRefed<nsWindow> window(aWindow);
     aScreen->UpdateMirroringWidget(window);
 }
 
 bool
 nsScreenGonk::EnableMirroring()
 {
     MOZ_ASSERT(NS_IsMainThread());
@@ -663,17 +663,17 @@ nsScreenGonk::EnableMirroring()
     initData.mScreenId = mId;
     RefPtr<nsWindow> window = new nsWindow();
     window->Create(nullptr, nullptr, mNaturalBounds, &initData);
     MOZ_ASSERT(static_cast<nsWindow*>(window)->GetScreen() == this);
 
     // Update mMirroringWidget on compositor thread
     nsMainThreadPtrHandle<nsScreenGonk> primary =
       nsMainThreadPtrHandle<nsScreenGonk>(new nsMainThreadPtrHolder<nsScreenGonk>(primaryScreen, false));
-    CompositorParent::CompositorLoop()->PostTask(
+    CompositorBridgeParent::CompositorLoop()->PostTask(
         FROM_HERE,
         NewRunnableFunction(&UpdateMirroringWidgetSync,
                             primary,
                             window.forget().take()));
 
     mIsMirroring = true;
     return true;
 }
@@ -689,17 +689,17 @@ nsScreenGonk::DisableMirroring()
     NS_ENSURE_TRUE(primaryScreen, false);
 
     bool ret = primaryScreen->ClearMirroringScreen(this);
     NS_ENSURE_TRUE(ret, false);
 
     // Update mMirroringWidget on compositor thread
     nsMainThreadPtrHandle<nsScreenGonk> primary =
       nsMainThreadPtrHandle<nsScreenGonk>(new nsMainThreadPtrHolder<nsScreenGonk>(primaryScreen, false));
-    CompositorParent::CompositorLoop()->PostTask(
+    CompositorBridgeParent::CompositorLoop()->PostTask(
         FROM_HERE,
         NewRunnableFunction(&UpdateMirroringWidgetSync,
                             primary,
                             nullptr));
     return true;
 }
 
 bool
@@ -726,30 +726,30 @@ nsScreenGonk::ClearMirroringScreen(nsScr
     }
     mMirroringScreen = nullptr;
     return true;
 }
 
 void
 nsScreenGonk::UpdateMirroringWidget(already_AddRefed<nsWindow>& aWindow)
 {
-    MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+    MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
     MOZ_ASSERT(IsPrimaryScreen());
 
     if (mMirroringWidget) {
         nsCOMPtr<nsIWidget> widget = mMirroringWidget.forget();
         NS_ReleaseOnMainThread(widget.forget());
     }
     mMirroringWidget = aWindow;
 }
 
 nsWindow*
 nsScreenGonk::GetMirroringWidget()
 {
-    MOZ_ASSERT(CompositorParent::IsInCompositorThread());
+    MOZ_ASSERT(CompositorBridgeParent::IsInCompositorThread());
     MOZ_ASSERT(IsPrimaryScreen());
 
     return mMirroringWidget;
 }
 
 NS_IMPL_ISUPPORTS(nsScreenManagerGonk, nsIScreenManager)
 
 nsScreenManagerGonk::nsScreenManagerGonk()
@@ -1066,15 +1066,15 @@ nsScreenManagerGonk::RemoveScreen(GonkDi
 }
 
 #if ANDROID_VERSION >= 19
 void
 nsScreenManagerGonk::SetCompositorVsyncScheduler(mozilla::layers::CompositorVsyncScheduler *aObserver)
 {
     MOZ_ASSERT(NS_IsMainThread());
 
-    // We assume on b2g that there is only 1 CompositorParent
+    // We assume on b2g that there is only 1 CompositorBridgeParent
     MOZ_ASSERT(mCompositorVsyncScheduler == nullptr);
     MOZ_ASSERT(aObserver);
     mCompositorVsyncScheduler = aObserver;
     mCompositorVsyncScheduler->SetDisplay(mDisplayEnabled);
 }
 #endif
--- a/widget/gonk/nsScreenManagerGonk.h
+++ b/widget/gonk/nsScreenManagerGonk.h
@@ -40,31 +40,31 @@ namespace android {
 };
 
 namespace mozilla {
 namespace gl {
     class GLContext;
 }
 namespace layers {
 class CompositorVsyncScheduler;
-class CompositorParent;
+class CompositorBridgeParent;
 }
 }
 
 enum class NotifyDisplayChangedEvent : int8_t {
   Observable,
   Suppressed
 };
 
 class nsScreenGonk : public nsBaseScreen
 {
     typedef mozilla::hal::ScreenConfiguration ScreenConfiguration;
     typedef mozilla::GonkDisplay GonkDisplay;
     typedef mozilla::LayoutDeviceIntRect LayoutDeviceIntRect;
-    typedef mozilla::layers::CompositorParent CompositorParent;
+    typedef mozilla::layers::CompositorBridgeParent CompositorBridgeParent;
     typedef mozilla::gfx::DrawTarget DrawTarget;
 
 public:
     nsScreenGonk(uint32_t aId,
                  GonkDisplay::DisplayType aDisplayType,
                  const GonkDisplay::NativeData& aNativeData,
                  NotifyDisplayChangedEvent aEventVisibility);
 
@@ -88,17 +88,17 @@ public:
     uint32_t EffectiveScreenRotation();
     ScreenConfiguration GetConfiguration();
     bool IsPrimaryScreen();
 
     already_AddRefed<DrawTarget> StartRemoteDrawing();
     void EndRemoteDrawing();
 
     nsresult MakeSnapshot(ANativeWindowBuffer* aBuffer);
-    void SetCompositorParent(CompositorParent* aCompositorParent);
+    void SetCompositorBridgeParent(CompositorBridgeParent* aCompositorBridgeParent);
 
 #if ANDROID_VERSION >= 17
     android::DisplaySurface* GetDisplaySurface();
     int GetPrevDispAcquireFd();
 #endif
     GonkDisplay::DisplayType GetDisplayType();
 
     void RegisterWindow(nsWindow* aWindow);
@@ -146,17 +146,17 @@ protected:
     uint32_t mScreenRotation;
     uint32_t mPhysicalScreenRotation;
     nsTArray<nsWindow*> mTopWindows;
 #if ANDROID_VERSION >= 17
     android::sp<android::DisplaySurface> mDisplaySurface;
 #endif
     bool mIsMirroring; // Non-primary screen only
     RefPtr<nsScreenGonk> mMirroringScreen; // Primary screen only
-    mozilla::Atomic<CompositorParent*> mCompositorParent;
+    mozilla::Atomic<CompositorBridgeParent*> mCompositorBridgeParent;
 
     // Accessed and updated only on compositor thread
     GonkDisplay::DisplayType mDisplayType;
     hwc_display_t mEGLDisplay;
     hwc_surface_t mEGLSurface;
     RefPtr<mozilla::gl::GLContext> mGLContext;
     RefPtr<nsWindow> mMirroringWidget; // Primary screen only
 
--- a/widget/gonk/nsWindow.cpp
+++ b/widget/gonk/nsWindow.cpp
@@ -37,17 +37,17 @@
 #include "ClientLayerManager.h"
 #include "BasicLayers.h"
 #include "libdisplay/GonkDisplay.h"
 #include "mozilla/TextEvents.h"
 #include "mozilla/gfx/2D.h"
 #include "mozilla/gfx/Logging.h"
 #include "mozilla/layers/APZCTreeManager.h"
 #include "mozilla/layers/APZThreadUtils.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/TouchEvents.h"
 #include "HwcComposer2D.h"
 
 #define LOG(args...)  __android_log_print(ANDROID_LOG_INFO, "Gonk" , ## args)
 #define LOGW(args...) __android_log_print(ANDROID_LOG_WARN, "Gonk", ## args)
 #define LOGE(args...) __android_log_print(ANDROID_LOG_ERROR, "Gonk", ## args)
 
 #define IS_TOPLEVEL() (mWindowType == eWindowType_toplevel || mWindowType == eWindowType_dialog)
@@ -79,17 +79,17 @@ nsWindow::nsWindow()
     if (!ShouldUseOffMainThreadCompositing()) {
         MOZ_CRASH("How can we render apps, then?");
     }
 }
 
 nsWindow::~nsWindow()
 {
     if (mScreen->IsPrimaryScreen()) {
-        mComposer2D->SetCompositorParent(nullptr);
+        mComposer2D->SetCompositorBridgeParent(nullptr);
     }
 }
 
 void
 nsWindow::DoDraw(void)
 {
     if (!hal::GetScreenEnabled()) {
         gDrawRequest = true;
@@ -125,17 +125,17 @@ nsWindow::DoDraw(void)
     if (listener) {
         listener->DidPaintWindow();
     }
 }
 
 void
 nsWindow::ConfigureAPZControllerThread()
 {
-    APZThreadUtils::SetControllerThread(CompositorParent::CompositorLoop());
+    APZThreadUtils::SetControllerThread(CompositorBridgeParent::CompositorLoop());
 }
 
 /*static*/ nsEventStatus
 nsWindow::DispatchKeyInput(WidgetKeyboardEvent& aEvent)
 {
     if (!gFocusedWindow) {
         return nsEventStatus_eIgnore;
     }
@@ -687,43 +687,43 @@ nsWindow::GetLayerManager(PLayerTransact
     nsWindow *topWindow = windows[0];
 
     if (!topWindow) {
         LOGW(" -- no topwindow\n");
         return nullptr;
     }
 
     CreateCompositor();
-    if (mCompositorParent) {
-        mScreen->SetCompositorParent(mCompositorParent);
+    if (mCompositorBridgeParent) {
+        mScreen->SetCompositorBridgeParent(mCompositorBridgeParent);
         if (mScreen->IsPrimaryScreen()) {
-            mComposer2D->SetCompositorParent(mCompositorParent);
+            mComposer2D->SetCompositorBridgeParent(mCompositorBridgeParent);
         }
     }
     MOZ_ASSERT(mLayerManager);
     return mLayerManager;
 }
 
 void
 nsWindow::DestroyCompositor()
 {
-    if (mCompositorParent) {
-        mScreen->SetCompositorParent(nullptr);
+    if (mCompositorBridgeParent) {
+        mScreen->SetCompositorBridgeParent(nullptr);
         if (mScreen->IsPrimaryScreen()) {
-            // Unset CompositorParent
-            mComposer2D->SetCompositorParent(nullptr);
+            // Unset CompositorBridgeParent
+            mComposer2D->SetCompositorBridgeParent(nullptr);
         }
     }
     nsBaseWidget::DestroyCompositor();
 }
 
-CompositorParent*
-nsWindow::NewCompositorParent(int aSurfaceWidth, int aSurfaceHeight)
+CompositorBridgeParent*
+nsWindow::NewCompositorBridgeParent(int aSurfaceWidth, int aSurfaceHeight)
 {
-    return new CompositorParent(this, true, aSurfaceWidth, aSurfaceHeight);
+    return new CompositorBridgeParent(this, true, aSurfaceWidth, aSurfaceHeight);
 }
 
 void
 nsWindow::BringToTop()
 {
     const nsTArray<nsWindow*>& windows = mScreen->GetTopWindows();
     if (!windows.IsEmpty()) {
         if (nsIWidgetListener* listener = windows[0]->GetWidgetListener()) {
--- a/widget/gonk/nsWindow.h
+++ b/widget/gonk/nsWindow.h
@@ -111,17 +111,17 @@ public:
     virtual double GetDefaultScaleInternal();
     virtual mozilla::layers::LayerManager*
         GetLayerManager(PLayerTransactionChild* aShadowManager = nullptr,
                         LayersBackend aBackendHint = mozilla::layers::LayersBackend::LAYERS_NONE,
                         LayerManagerPersistence aPersistence = LAYER_MANAGER_CURRENT,
                         bool* aAllowRetaining = nullptr);
     virtual void DestroyCompositor();
 
-    virtual CompositorParent* NewCompositorParent(int aSurfaceWidth, int aSurfaceHeight);
+    virtual CompositorBridgeParent* NewCompositorBridgeParent(int aSurfaceWidth, int aSurfaceHeight);
 
     NS_IMETHOD_(void) SetInputContext(const InputContext& aContext,
                                       const InputContextAction& aAction);
     NS_IMETHOD_(InputContext) GetInputContext();
 
     virtual uint32_t GetGLFrameBufferFormat() override;
 
     virtual LayoutDeviceIntRect GetNaturalBounds() override;
--- a/widget/gtk/nsWindow.cpp
+++ b/widget/gtk/nsWindow.cpp
@@ -111,17 +111,17 @@ using namespace mozilla::widget;
 
 #include "gfxPlatformGtk.h"
 #include "gfxContext.h"
 #include "gfxImageSurface.h"
 #include "gfxUtils.h"
 #include "Layers.h"
 #include "GLContextProvider.h"
 #include "mozilla/gfx/2D.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 
 #ifdef MOZ_X11
 #include "gfxXlibSurface.h"
 #endif
   
 #include "nsShmImage.h"
 
 #include "nsIDOMWheelEvent.h"
@@ -2144,17 +2144,17 @@ nsWindow::OnExposeEvent(cairo_t *cr)
     LayoutDeviceIntRegion region = exposeRegion;
     region.ScaleRoundOut(scale, scale);
 
     ClientLayerManager *clientLayers =
         (GetLayerManager()->GetBackendType() == LayersBackend::LAYERS_CLIENT)
         ? static_cast<ClientLayerManager*>(GetLayerManager())
         : nullptr;
 
-    if (clientLayers && mCompositorParent) {
+    if (clientLayers && mCompositorBridgeParent) {
         // We need to paint to the screen even if nothing changed, since if we
         // don't have a compositing window manager, our pixels could be stale.
         clientLayers->SetNeedsComposite(true);
         clientLayers->SendInvalidRegion(region.ToUnknownRegion());
     }
 
     // Dispatch WillPaintWindow notification to allow scripts etc. to run
     // before we paint
@@ -2169,18 +2169,18 @@ nsWindow::OnExposeEvent(cairo_t *cr)
         // Re-get the listener since the will paint notification might have
         // killed it.
         listener =
             mAttachedWidgetListener ? mAttachedWidgetListener : mWidgetListener;
         if (!listener)
             return FALSE;
     }
 
-    if (clientLayers && mCompositorParent && clientLayers->NeedsComposite()) {
-        mCompositorParent->ScheduleRenderOnCompositorThread();
+    if (clientLayers && mCompositorBridgeParent && clientLayers->NeedsComposite()) {
+        mCompositorBridgeParent->ScheduleRenderOnCompositorThread();
         clientLayers->SetNeedsComposite(false);
     }
 
     LOGDRAW(("sending expose event [%p] %p 0x%lx (rects follow):\n",
              (void *)this, (void *)mGdkWindow,
              gdk_x11_window_get_xid(mGdkWindow)));
 
     // Our bounds may have changed after calling WillPaintWindow.  Clip
--- a/widget/nsBaseWidget.cpp
+++ b/widget/nsBaseWidget.cpp
@@ -3,18 +3,18 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "mozilla/ArrayUtils.h"
 #include "mozilla/TextEventDispatcher.h"
 #include "mozilla/TextEventDispatcherListener.h"
 
-#include "mozilla/layers/CompositorChild.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeChild.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/layers/ImageBridgeChild.h"
 #include "nsBaseWidget.h"
 #include "nsDeviceContext.h"
 #include "nsCOMPtr.h"
 #include "nsGfxCIID.h"
 #include "nsWidgetsCID.h"
 #include "nsServiceManagerUtils.h"
 #include "nsIScreenManager.h"
@@ -265,22 +265,22 @@ nsBaseWidget::Shutdown()
     Preferences::SetInt(kAccessibilityLastRunDatePref, now);
   }
 #endif
 #endif
 }
 
 void nsBaseWidget::DestroyCompositor()
 {
-  if (mCompositorChild) {
-    // XXX CompositorChild and CompositorParent might be re-created in
+  if (mCompositorBridgeChild) {
+    // XXX CompositorBridgeChild and CompositorBridgeParent might be re-created in
     // ClientLayerManager destructor. See bug 1133426.
-    RefPtr<CompositorChild> compositorChild = mCompositorChild;
-    RefPtr<CompositorParent> compositorParent = mCompositorParent;
-    mCompositorChild->Destroy();
+    RefPtr<CompositorBridgeChild> compositorChild = mCompositorBridgeChild;
+    RefPtr<CompositorBridgeParent> compositorParent = mCompositorBridgeParent;
+    mCompositorBridgeChild->Destroy();
   }
 
   // Can have base widgets that are things like tooltips
   // which don't have CompositorVsyncDispatchers
   if (mCompositorVsyncDispatcher) {
     mCompositorVsyncDispatcher->Shutdown();
   }
 }
@@ -292,17 +292,17 @@ void nsBaseWidget::DestroyLayerManager()
     mLayerManager = nullptr;
   }
   DestroyCompositor();
 }
 
 void
 nsBaseWidget::OnRenderingDeviceReset()
 {
-  if (!mLayerManager || !mCompositorParent) {
+  if (!mLayerManager || !mCompositorBridgeParent) {
     return;
   }
 
   nsTArray<LayersBackend> backendHints;
   gfxPlatform::GetPlatform()->GetCompositorBackends(ComputeShouldAccelerate(), backendHints);
 
   // If the existing compositor does not use acceleration, and this widget
   // should not be accelerated, then there's no point in resetting.
@@ -314,17 +314,17 @@ nsBaseWidget::OnRenderingDeviceReset()
   if (!ComputeShouldAccelerate() &&
       clm->GetTextureFactoryIdentifier().mParentBackend != LayersBackend::LAYERS_BASIC)
   {
     return;
   }
 
   // Recreate the compositor.
   TextureFactoryIdentifier identifier;
-  if (!mCompositorParent->ResetCompositor(backendHints, &identifier)) {
+  if (!mCompositorBridgeParent->ResetCompositor(backendHints, &identifier)) {
     // No action was taken, so we don't have to do anything.
     return;
   }
 
   // Invalidate all layers.
   FrameLayerBuilder::InvalidateAllLayers(mLayerManager);
 
   // Update the texture factory identifier.
@@ -926,20 +926,20 @@ nsBaseWidget::AutoLayerManagerSetup::~Au
 }
 
 bool
 nsBaseWidget::ComputeShouldAccelerate()
 {
   return gfxPlatform::GetPlatform()->ShouldUseLayersAcceleration();
 }
 
-CompositorParent* nsBaseWidget::NewCompositorParent(int aSurfaceWidth,
+CompositorBridgeParent* nsBaseWidget::NewCompositorBridgeParent(int aSurfaceWidth,
                                                     int aSurfaceHeight)
 {
-  return new CompositorParent(this, false, aSurfaceWidth, aSurfaceHeight);
+  return new CompositorBridgeParent(this, false, aSurfaceWidth, aSurfaceHeight);
 }
 
 void nsBaseWidget::CreateCompositor()
 {
   LayoutDeviceIntRect rect;
   GetBounds(rect);
   CreateCompositor(rect.width, rect.height);
 }
@@ -979,18 +979,18 @@ void nsBaseWidget::ConfigureAPZCTreeMana
     MOZ_ASSERT(NS_IsMainThread());
     APZThreadUtils::RunOnControllerThread(NewRunnableMethod(
         treeManager.get(), &APZCTreeManager::SetAllowedTouchBehavior,
         aInputBlockId, aFlags));
   };
 
   RefPtr<GeckoContentController> controller = CreateRootContentController();
   if (controller) {
-    uint64_t rootLayerTreeId = mCompositorParent->RootLayerTreeId();
-    CompositorParent::SetControllerForLayerTree(rootLayerTreeId, controller);
+    uint64_t rootLayerTreeId = mCompositorBridgeParent->RootLayerTreeId();
+    CompositorBridgeParent::SetControllerForLayerTree(rootLayerTreeId, controller);
   }
 
   // When APZ is enabled, we can actually enable raw touch events because we
   // have code that can deal with them properly. If APZ is not enabled, this
   // function doesn't get called.
   if (Preferences::GetInt("dom.w3c_touch_events.enabled", 0) ||
       Preferences::GetBool("dom.w3c_pointer_events.enabled", false)) {
     RegisterTouchWindow();
@@ -1014,33 +1014,33 @@ nsBaseWidget::SetConfirmedTargetAPZC(uin
     mAPZC.get(), setTargetApzcFunc, aInputBlockId, aTargets));
 }
 
 void
 nsBaseWidget::UpdateZoomConstraints(const uint32_t& aPresShellId,
                                     const FrameMetrics::ViewID& aViewId,
                                     const Maybe<ZoomConstraints>& aConstraints)
 {
-  if (!mCompositorParent || !mAPZC) {
+  if (!mCompositorBridgeParent || !mAPZC) {
     if (mInitialZoomConstraints) {
       MOZ_ASSERT(mInitialZoomConstraints->mPresShellID == aPresShellId);
       MOZ_ASSERT(mInitialZoomConstraints->mViewID == aViewId);
       if (!aConstraints) {
         mInitialZoomConstraints.reset();
       }
     }
 
     if (aConstraints) {
       // We have some constraints, but the compositor and APZC aren't created yet.
       // Save these so we can use them later.
       mInitialZoomConstraints = Some(InitialZoomConstraints(aPresShellId, aViewId, aConstraints.ref()));
     }
     return;
   }
-  uint64_t layersId = mCompositorParent->RootLayerTreeId();
+  uint64_t layersId = mCompositorBridgeParent->RootLayerTreeId();
   mAPZC->UpdateZoomConstraints(ScrollableLayerGuid(layersId, aPresShellId, aViewId),
                                aConstraints);
 }
 
 bool
 nsBaseWidget::AsyncPanZoomEnabled() const
 {
   return !!mAPZC;
@@ -1055,17 +1055,17 @@ nsBaseWidget::ProcessUntransformedAPZEve
   MOZ_ASSERT(NS_IsMainThread());
   InputAPZContext context(aGuid, aInputBlockId, aApzResponse);
 
   // If this is an event that the APZ has targeted to an APZC in the root
   // process, apply that APZC's callback-transform before dispatching the
   // event. If the event is instead targeted to an APZC in the child process,
   // the transform will be applied in the child process before dispatching
   // the event there (see e.g. TabChild::RecvRealTouchEvent()).
-  if (aGuid.mLayersId == mCompositorParent->RootLayerTreeId()) {
+  if (aGuid.mLayersId == mCompositorBridgeParent->RootLayerTreeId()) {
     APZCCallbackHelper::ApplyCallbackTransform(*aEvent, aGuid,
         GetDefaultScale());
   }
 
   // Make a copy of the original event for the APZCCallbackHelper helpers that
   // we call later, because the event passed to DispatchEvent can get mutated in
   // ways that we don't want (i.e. touch points can get stripped out).
   nsEventStatus status;
@@ -1231,43 +1231,43 @@ nsBaseWidget::GetCompositorVsyncDispatch
 void nsBaseWidget::CreateCompositor(int aWidth, int aHeight)
 {
   // This makes sure that gfxPlatforms gets initialized if it hasn't by now.
   gfxPlatform::GetPlatform();
 
   MOZ_ASSERT(gfxPlatform::UsesOffMainThreadCompositing(),
              "This function assumes OMTC");
 
-  MOZ_ASSERT(!mCompositorParent && !mCompositorChild,
+  MOZ_ASSERT(!mCompositorBridgeParent && !mCompositorBridgeChild,
     "Should have properly cleaned up the previous PCompositor pair beforehand");
 
-  if (mCompositorChild) {
-    mCompositorChild->Destroy();
+  if (mCompositorBridgeChild) {
+    mCompositorBridgeChild->Destroy();
   }
 
   // Recreating this is tricky, as we may still have an old and we need
   // to make sure it's properly destroyed by calling DestroyCompositor!
 
   // If we've already received a shutdown notification, don't try
   // create a new compositor.
   if (!mShutdownObserver) {
     return;
   }
 
   CreateCompositorVsyncDispatcher();
-  mCompositorParent = NewCompositorParent(aWidth, aHeight);
+  mCompositorBridgeParent = NewCompositorBridgeParent(aWidth, aHeight);
   RefPtr<ClientLayerManager> lm = new ClientLayerManager(this);
-  mCompositorChild = new CompositorChild(lm);
-  mCompositorChild->OpenSameProcess(mCompositorParent);
+  mCompositorBridgeChild = new CompositorBridgeChild(lm);
+  mCompositorBridgeChild->OpenSameProcess(mCompositorBridgeParent);
 
   // Make sure the parent knows it is same process.
-  mCompositorParent->SetOtherProcessId(base::GetCurrentProcId());
-
-  uint64_t rootLayerTreeId = mCompositorParent->RootLayerTreeId();
-  mAPZC = CompositorParent::GetAPZCTreeManager(rootLayerTreeId);
+  mCompositorBridgeParent->SetOtherProcessId(base::GetCurrentProcId());
+
+  uint64_t rootLayerTreeId = mCompositorBridgeParent->RootLayerTreeId();
+  mAPZC = CompositorBridgeParent::GetAPZCTreeManager(rootLayerTreeId);
   if (mAPZC) {
     ConfigureAPZCTreeManager();
   }
 
   if (mInitialZoomConstraints) {
     UpdateZoomConstraints(mInitialZoomConstraints->mPresShellID,
                           mInitialZoomConstraints->mViewID,
                           Some(mInitialZoomConstraints->mConstraints));
@@ -1277,28 +1277,28 @@ void nsBaseWidget::CreateCompositor(int 
   TextureFactoryIdentifier textureFactoryIdentifier;
   PLayerTransactionChild* shadowManager = nullptr;
 
   nsTArray<LayersBackend> backendHints;
   gfxPlatform::GetPlatform()->GetCompositorBackends(ComputeShouldAccelerate(), backendHints);
 
   bool success = false;
   if (!backendHints.IsEmpty()) {
-    shadowManager = mCompositorChild->SendPLayerTransactionConstructor(
+    shadowManager = mCompositorBridgeChild->SendPLayerTransactionConstructor(
       backendHints, 0, &textureFactoryIdentifier, &success);
   }
 
   ShadowLayerForwarder* lf = lm->AsShadowForwarder();
 
   if (!success || !lf) {
     NS_WARNING("Failed to create an OMT compositor.");
     DestroyCompositor();
     mLayerManager = nullptr;
-    mCompositorChild = nullptr;
-    mCompositorParent = nullptr;
+    mCompositorBridgeChild = nullptr;
+    mCompositorBridgeParent = nullptr;
     mCompositorVsyncDispatcher = nullptr;
     return;
   }
 
   lf->SetShadowManager(shadowManager);
   lf->IdentifyTextureHost(textureFactoryIdentifier);
   ImageBridgeChild::IdentifyCompositorTextureHost(textureFactoryIdentifier);
   WindowUsesOMTC();
@@ -1345,19 +1345,19 @@ LayerManager* nsBaseWidget::GetLayerMana
   return mLayerManager;
 }
 
 LayerManager* nsBaseWidget::CreateBasicLayerManager()
 {
   return new BasicLayerManager(this);
 }
 
-CompositorChild* nsBaseWidget::GetRemoteRenderer()
+CompositorBridgeChild* nsBaseWidget::GetRemoteRenderer()
 {
-  return mCompositorChild;
+  return mCompositorBridgeChild;
 }
 
 already_AddRefed<mozilla::gfx::DrawTarget> nsBaseWidget::StartRemoteDrawing()
 {
   return nullptr;
 }
 
 already_AddRefed<mozilla::gfx::DrawTarget>
@@ -1816,20 +1816,20 @@ nsBaseWidget::GetNativeTextEventDispatch
 }
 
 void
 nsBaseWidget::ZoomToRect(const uint32_t& aPresShellId,
                          const FrameMetrics::ViewID& aViewId,
                          const CSSRect& aRect,
                          const uint32_t& aFlags)
 {
-  if (!mCompositorParent || !mAPZC) {
+  if (!mCompositorBridgeParent || !mAPZC) {
     return;
   }
-  uint64_t layerId = mCompositorParent->RootLayerTreeId();
+  uint64_t layerId = mCompositorBridgeParent->RootLayerTreeId();
   mAPZC->ZoomToRect(ScrollableLayerGuid(layerId, aPresShellId, aViewId), aRect, aFlags);
 }
 
 #ifdef ACCESSIBILITY
 
 a11y::Accessible*
 nsBaseWidget::GetRootAccessible()
 {
@@ -1861,19 +1861,19 @@ nsBaseWidget::GetRootAccessible()
 
 void
 nsBaseWidget::StartAsyncScrollbarDrag(const AsyncDragMetrics& aDragMetrics)
 {
   if (!AsyncPanZoomEnabled()) {
     return;
   }
 
-  MOZ_ASSERT(XRE_IsParentProcess() && mCompositorParent);
-
-  int layersId = mCompositorParent->RootLayerTreeId();;
+  MOZ_ASSERT(XRE_IsParentProcess() && mCompositorBridgeParent);
+
+  int layersId = mCompositorBridgeParent->RootLayerTreeId();;
   ScrollableLayerGuid guid(layersId, aDragMetrics.mPresShellId, aDragMetrics.mViewId);
 
   APZThreadUtils::RunOnControllerThread(
     NewRunnableMethod(mAPZC.get(), &APZCTreeManager::StartScrollbarDrag, guid, aDragMetrics));
 }
 
 already_AddRefed<nsIScreen>
 nsBaseWidget::GetWidgetScreen()
@@ -2088,17 +2088,17 @@ nsIWidget::SnapshotWidgetOnScreen()
     return nullptr;
   }
 
   ClientLayerManager* lm = layerManager->AsClientLayerManager();
   if (!lm) {
     return nullptr;
   }
 
-  CompositorChild* cc = lm->GetRemoteRenderer();
+  CompositorBridgeChild* cc = lm->GetRemoteRenderer();
   if (!cc) {
     return nullptr;
   }
 
   LayoutDeviceIntRect bounds;
   GetBounds(bounds);
   if (bounds.IsEmpty()) {
     return nullptr;
--- a/widget/nsBaseWidget.h
+++ b/widget/nsBaseWidget.h
@@ -29,18 +29,18 @@ namespace mozilla {
 #ifdef ACCESSIBILITY
 namespace a11y {
 class Accessible;
 }
 #endif
 
 namespace layers {
 class BasicLayerManager;
-class CompositorChild;
-class CompositorParent;
+class CompositorBridgeChild;
+class CompositorBridgeParent;
 class APZCTreeManager;
 class GeckoContentController;
 class APZEventState;
 struct ScrollableLayerGuid;
 } // namespace layers
 
 class CompositorVsyncDispatcher;
 } // namespace mozilla
@@ -87,18 +87,18 @@ class nsBaseWidget : public nsIWidget, p
 {
   friend class nsAutoRollup;
   friend class DispatchWheelEventOnMainThread;
 
 protected:
   typedef base::Thread Thread;
   typedef mozilla::layers::BasicLayerManager BasicLayerManager;
   typedef mozilla::layers::BufferMode BufferMode;
-  typedef mozilla::layers::CompositorChild CompositorChild;
-  typedef mozilla::layers::CompositorParent CompositorParent;
+  typedef mozilla::layers::CompositorBridgeChild CompositorBridgeChild;
+  typedef mozilla::layers::CompositorBridgeParent CompositorBridgeParent;
   typedef mozilla::layers::APZCTreeManager APZCTreeManager;
   typedef mozilla::layers::GeckoContentController GeckoContentController;
   typedef mozilla::layers::ScrollableLayerGuid ScrollableLayerGuid;
   typedef mozilla::layers::APZEventState APZEventState;
   typedef mozilla::layers::SetAllowedTouchBehaviorCallback SetAllowedTouchBehaviorCallback;
   typedef mozilla::CSSIntRect CSSIntRect;
   typedef mozilla::CSSRect CSSRect;
   typedef mozilla::ScreenRotation ScreenRotation;
@@ -155,17 +155,17 @@ public:
 
   virtual LayerManager*   GetLayerManager(PLayerTransactionChild* aShadowManager = nullptr,
                                           LayersBackend aBackendHint = mozilla::layers::LayersBackend::LAYERS_NONE,
                                           LayerManagerPersistence aPersistence = LAYER_MANAGER_CURRENT,
                                           bool* aAllowRetaining = nullptr) override;
 
   CompositorVsyncDispatcher* GetCompositorVsyncDispatcher() override;
   void            CreateCompositorVsyncDispatcher();
-  virtual CompositorParent* NewCompositorParent(int aSurfaceWidth, int aSurfaceHeight);
+  virtual CompositorBridgeParent* NewCompositorBridgeParent(int aSurfaceWidth, int aSurfaceHeight);
   virtual void            CreateCompositor();
   virtual void            CreateCompositor(int aWidth, int aHeight);
   virtual void            PrepareWindowEffects() override {}
   virtual void            CleanupWindowEffects() override {}
   virtual bool            PreRender(LayerManagerComposite* aManager) override { return true; }
   virtual void            PostRender(LayerManagerComposite* aManager) override {}
   virtual void            DrawWindowUnderlay(LayerManagerComposite* aManager, LayoutDeviceIntRect aRect) override {}
   virtual void            DrawWindowOverlay(LayerManagerComposite* aManager, LayoutDeviceIntRect aRect) override {}
@@ -478,17 +478,17 @@ protected:
   {
     SizeConstraints c = GetSizeConstraints();
     *aWidth = std::max(c.mMinSize.width,
                        std::min(c.mMaxSize.width, *aWidth));
     *aHeight = std::max(c.mMinSize.height,
                         std::min(c.mMaxSize.height, *aHeight));
   }
 
-  virtual CompositorChild* GetRemoteRenderer() override;
+  virtual CompositorBridgeChild* GetRemoteRenderer() override;
 
   /**
    * Notify the widget that this window is being used with OMTC.
    */
   virtual void WindowUsesOMTC() {}
   virtual void RegisterTouchWindow() {}
 
   nsIDocument* GetDocument() const;
@@ -512,18 +512,18 @@ protected:
   void DestroyLayerManager();
 
   void FreeShutdownObserver();
 
   nsIWidgetListener* mWidgetListener;
   nsIWidgetListener* mAttachedWidgetListener;
   nsIWidgetListener* mPreviouslyAttachedWidgetListener;
   RefPtr<LayerManager> mLayerManager;
-  RefPtr<CompositorChild> mCompositorChild;
-  RefPtr<CompositorParent> mCompositorParent;
+  RefPtr<CompositorBridgeChild> mCompositorBridgeChild;
+  RefPtr<CompositorBridgeParent> mCompositorBridgeParent;
   RefPtr<mozilla::CompositorVsyncDispatcher> mCompositorVsyncDispatcher;
   RefPtr<APZCTreeManager> mAPZC;
   RefPtr<APZEventState> mAPZEventState;
   SetAllowedTouchBehaviorCallback mSetAllowedTouchBehaviorCallback;
   RefPtr<WidgetShutdownObserver> mShutdownObserver;
   RefPtr<TextEventDispatcher> mTextEventDispatcher;
   nsCursor          mCursor;
   nsBorderStyle     mBorderStyle;
--- a/widget/nsIWidget.h
+++ b/widget/nsIWidget.h
@@ -47,17 +47,17 @@ class TabChild;
 } // namespace dom
 namespace plugins {
 class PluginWidgetChild;
 } // namespace plugins
 namespace layers {
 class AsyncDragMetrics;
 class Composer2D;
 class Compositor;
-class CompositorChild;
+class CompositorBridgeChild;
 class LayerManager;
 class LayerManagerComposite;
 class PLayerTransactionChild;
 struct ScrollableLayerGuid;
 } // namespace layers
 namespace gfx {
 class DrawTarget;
 class SourceSurface;
@@ -322,17 +322,17 @@ private:
  * all basic and necessary functionality.
  */
 class nsIWidget : public nsISupports {
   protected:
     typedef mozilla::dom::TabChild TabChild;
 
   public:
     typedef mozilla::layers::Composer2D Composer2D;
-    typedef mozilla::layers::CompositorChild CompositorChild;
+    typedef mozilla::layers::CompositorBridgeChild CompositorBridgeChild;
     typedef mozilla::layers::AsyncDragMetrics AsyncDragMetrics;
     typedef mozilla::layers::FrameMetrics FrameMetrics;
     typedef mozilla::layers::LayerManager LayerManager;
     typedef mozilla::layers::LayerManagerComposite LayerManagerComposite;
     typedef mozilla::layers::LayersBackend LayersBackend;
     typedef mozilla::layers::PLayerTransactionChild PLayerTransactionChild;
     typedef mozilla::layers::ZoomConstraints ZoomConstraints;
     typedef mozilla::widget::IMEMessage IMEMessage;
@@ -2016,17 +2016,17 @@ public:
      * null.
      */
     virtual TabChild* GetOwningTabChild() { return nullptr; }
 
     /**
      * If this isn't directly compositing to its window surface,
      * return the compositor which is doing that on our behalf.
      */
-    virtual CompositorChild* GetRemoteRenderer()
+    virtual CompositorBridgeChild* GetRemoteRenderer()
     { return nullptr; }
 
     /**
      * If this widget has a more efficient composer available for its
      * native framebuffer, return it.
      *
      * This can be called from a non-main thread, but that thread must
      * hold a strong reference to this.
--- a/widget/windows/nsWindow.cpp
+++ b/widget/windows/nsWindow.cpp
@@ -3630,17 +3630,17 @@ nsWindow::GetLayerManager(PLayerTransact
 
     // e10s uses the parameter to pass in the shadow manager from the TabChild
     // so we don't expect to see it there since this doesn't support e10s.
     NS_ASSERTION(aShadowManager == nullptr, "Async Compositor not supported with e10s");
     CreateCompositor();
   }
 
   if (!mLayerManager) {
-    MOZ_ASSERT(!mCompositorParent && !mCompositorChild);
+    MOZ_ASSERT(!mCompositorBridgeParent && !mCompositorBridgeChild);
     mLayerManager = CreateBasicLayerManager();
   }
 
   NS_ASSERTION(mLayerManager, "Couldn't provide a valid layer manager.");
 
   return mLayerManager;
 }
 
--- a/widget/windows/nsWindowGfx.cpp
+++ b/widget/windows/nsWindowGfx.cpp
@@ -37,18 +37,18 @@ using mozilla::plugins::PluginInstancePa
 #include "gfxContext.h"
 #include "prmem.h"
 #include "WinUtils.h"
 #include "nsIWidgetListener.h"
 #include "mozilla/unused.h"
 #include "nsDebug.h"
 #include "nsIXULRuntime.h"
 
-#include "mozilla/layers/CompositorParent.h"
-#include "mozilla/layers/CompositorChild.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
+#include "mozilla/layers/CompositorBridgeChild.h"
 #include "ClientLayerManager.h"
 
 #include "nsUXThemeData.h"
 #include "nsUXThemeConstants.h"
 
 using namespace mozilla;
 using namespace mozilla::gfx;
 using namespace mozilla::layers;
@@ -164,17 +164,17 @@ nsIWidgetListener* nsWindow::GetPaintLis
 {
   if (mDestroyCalled)
     return nullptr;
   return mAttachedWidgetListener ? mAttachedWidgetListener : mWidgetListener;
 }
 
 void nsWindow::ForcePresent()
 {
-  if (CompositorChild* remoteRenderer = GetRemoteRenderer()) {
+  if (CompositorBridgeChild* remoteRenderer = GetRemoteRenderer()) {
     remoteRenderer->SendForcePresent();
   }
 }
 
 bool nsWindow::OnPaint(HDC aDC, uint32_t aNestingLevel)
 {
   // We never have reentrant paint events, except when we're running our RPC
   // windows event spin loop. If we don't trap for this, we'll try to paint,
@@ -225,22 +225,22 @@ bool nsWindow::OnPaint(HDC aDC, uint32_t
     }
 
     ValidateRect(mWnd, nullptr);
     return true;
   }
 
   ClientLayerManager *clientLayerManager = GetLayerManager()->AsClientLayerManager();
 
-  if (clientLayerManager && mCompositorParent &&
+  if (clientLayerManager && mCompositorBridgeParent &&
       !mBounds.IsEqualEdges(mLastPaintBounds))
   {
     // Do an early async composite so that we at least have something on the
     // screen in the right place, even if the content is out of date.
-    mCompositorParent->ScheduleRenderOnCompositorThread();
+    mCompositorBridgeParent->ScheduleRenderOnCompositorThread();
   }
   mLastPaintBounds = mBounds;
 
   PAINTSTRUCT ps;
 
 #ifdef MOZ_XUL
   if (!aDC && (eTransparencyTransparent == mTransparencyMode))
   {
@@ -276,35 +276,35 @@ bool nsWindow::OnPaint(HDC aDC, uint32_t
 
 #ifdef MOZ_XUL
   bool forceRepaint = aDC || (eTransparencyTransparent == mTransparencyMode);
 #else
   bool forceRepaint = nullptr != aDC;
 #endif
   nsIntRegion region = GetRegionToPaint(forceRepaint, ps, hDC);
 
-  if (clientLayerManager && mCompositorParent) {
+  if (clientLayerManager && mCompositorBridgeParent) {
     // We need to paint to the screen even if nothing changed, since if we
     // don't have a compositing window manager, our pixels could be stale.
     clientLayerManager->SetNeedsComposite(true);
     clientLayerManager->SendInvalidRegion(region);
   }
 
   nsIWidgetListener* listener = GetPaintListener();
   if (listener) {
     listener->WillPaintWindow(this);
   }
   // Re-get the listener since the will paint notification may have killed it.
   listener = GetPaintListener();
   if (!listener) {
     return false;
   }
 
-  if (clientLayerManager && mCompositorParent && clientLayerManager->NeedsComposite()) {
-    mCompositorParent->ScheduleRenderOnCompositorThread();
+  if (clientLayerManager && mCompositorBridgeParent && clientLayerManager->NeedsComposite()) {
+    mCompositorBridgeParent->ScheduleRenderOnCompositorThread();
     clientLayerManager->SetNeedsComposite(false);
   }
 
   bool result = true;
   if (!region.IsEmpty() && listener)
   {
     // Should probably pass in a real region here, using GetRandomRgn
     // http://msdn.microsoft.com/library/default.asp?url=/library/en-us/gdi/clipping_4q0e.asp
--- a/xpcom/build/XPCOMInit.cpp
+++ b/xpcom/build/XPCOMInit.cpp
@@ -12,17 +12,17 @@
 #include "mozilla/SharedThreadPool.h"
 #include "mozilla/XPCOM.h"
 #include "nsXULAppAPI.h"
 
 #include "nsXPCOMPrivate.h"
 #include "nsXPCOMCIDInternal.h"
 
 #include "mozilla/layers/ImageBridgeChild.h"
-#include "mozilla/layers/CompositorParent.h"
+#include "mozilla/layers/CompositorBridgeParent.h"
 #include "mozilla/layers/AsyncTransactionTracker.h"
 #include "mozilla/layers/SharedBufferManagerChild.h"
 
 #include "prlink.h"
 
 #include "nsCycleCollector.h"
 #include "nsObserverList.h"
 #include "nsObserverService.h"