Back out 5 changesets (bug 1271180) for static analysis bustage
authorPhil Ringnalda <philringnalda@gmail.com>
Sat, 11 Jun 2016 00:46:09 -0700
changeset 301611 a173da18f0dd25e0f53a514bd3586bc02012f055
parent 301610 72577f72121a09977fdf229b720f2a15c4597365
child 301612 8942d876c66827556741ac5ec088c4cc5396ed83
push id30336
push usercbook@mozilla.com
push dateSun, 12 Jun 2016 09:26:58 +0000
treeherdermozilla-central@016e0f47e8ad [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1271180
milestone50.0a1
backs outcfb53b780b1851da17ba1a4b7387d171fd1c760c
204b084385f83ad87133d7db7fd61cddba3e8643
353da876be334d8abb8139f20ea28cb86c7c2d0c
4472dfbc1dc6d9de295d9559134439985421b4d4
81079e787b8a1c60d50aa6c16f29ad5c77ef4501
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
Back out 5 changesets (bug 1271180) for static analysis bustage CLOSED TREE Backed out changeset cfb53b780b18 (bug 1271180) Backed out changeset 204b084385f8 (bug 1271180) Backed out changeset 353da876be33 (bug 1271180) Backed out changeset 4472dfbc1dc6 (bug 1271180) Backed out changeset 81079e787b8a (bug 1271180)
dom/plugins/ipc/PluginModuleParent.h
dom/plugins/ipc/PluginProcessParent.h
dom/plugins/ipc/TaskFactory.h
dom/plugins/ipc/moz.build
gfx/config/gfxFeature.h
gfx/ipc/GPUChild.cpp
gfx/ipc/GPUChild.h
gfx/ipc/GPUParent.cpp
gfx/ipc/GPUParent.h
gfx/ipc/GPUProcessHost.cpp
gfx/ipc/GPUProcessHost.h
gfx/ipc/GPUProcessImpl.cpp
gfx/ipc/GPUProcessImpl.h
gfx/ipc/GPUProcessManager.cpp
gfx/ipc/GPUProcessManager.h
gfx/ipc/PGPU.ipdl
gfx/ipc/moz.build
gfx/thebes/gfxPlatform.cpp
gfx/thebes/gfxPrefs.h
ipc/glue/GeckoChildProcessHost.cpp
ipc/glue/TaskFactory.h
ipc/glue/moz.build
toolkit/xre/nsAppRunner.cpp
toolkit/xre/nsEmbedFunctions.cpp
xpcom/build/nsXULAppAPI.h
xpcom/system/nsIXULRuntime.idl
--- a/dom/plugins/ipc/PluginModuleParent.h
+++ b/dom/plugins/ipc/PluginModuleParent.h
@@ -10,17 +10,17 @@
 #include "base/process.h"
 #include "mozilla/FileUtils.h"
 #include "mozilla/HangAnnotations.h"
 #include "mozilla/PluginLibrary.h"
 #include "mozilla/plugins/PluginProcessParent.h"
 #include "mozilla/plugins/PPluginModuleParent.h"
 #include "mozilla/plugins/PluginMessageUtils.h"
 #include "mozilla/plugins/PluginTypes.h"
-#include "mozilla/ipc/TaskFactory.h"
+#include "mozilla/plugins/TaskFactory.h"
 #include "mozilla/TimeStamp.h"
 #include "npapi.h"
 #include "npfunctions.h"
 #include "nsDataHashtable.h"
 #include "nsHashKeys.h"
 #include "nsIObserver.h"
 #ifdef XP_WIN
 #include "nsWindowsHelpers.h"
@@ -324,17 +324,17 @@ protected:
     bool mIsChrome;
     bool mShutdown;
     bool mHadLocalInstance;
     bool mClearSiteDataSupported;
     bool mGetSitesWithDataSupported;
     NPNetscapeFuncs* mNPNIface;
     NPPluginFuncs* mNPPIface;
     nsNPAPIPlugin* mPlugin;
-    ipc::TaskFactory<PluginModuleParent> mTaskFactory;
+    TaskFactory<PluginModuleParent> mTaskFactory;
     nsString mPluginDumpID;
     nsString mBrowserDumpID;
     nsString mHangID;
     RefPtr<nsIObserver> mProfilerObserver;
     TimeDuration mTimeBlocked;
     nsCString mPluginName;
     nsCString mPluginVersion;
     int32_t mSandboxLevel;
@@ -542,17 +542,17 @@ private:
 
     virtual bool RecvNotifyContentModuleDestroyed() override;
 
     static void CachedSettingChanged(const char* aPref, void* aModule);
 
     PluginProcessParent* mSubprocess;
     uint32_t mPluginId;
 
-    ipc::TaskFactory<PluginModuleChromeParent> mChromeTaskFactory;
+    TaskFactory<PluginModuleChromeParent> mChromeTaskFactory;
 
     enum HangAnnotationFlags
     {
         kInPluginCall = (1u << 0),
         kHangUIShown = (1u << 1),
         kHangUIContinued = (1u << 2),
         kHangUIDontShow = (1u << 3)
     };
--- a/dom/plugins/ipc/PluginProcessParent.h
+++ b/dom/plugins/ipc/PluginProcessParent.h
@@ -12,17 +12,17 @@
 
 #include "base/file_path.h"
 #include "base/task.h"
 #include "base/thread.h"
 #include "base/waitable_event.h"
 #include "chrome/common/child_process_host.h"
 
 #include "mozilla/ipc/GeckoChildProcessHost.h"
-#include "mozilla/ipc/TaskFactory.h"
+#include "mozilla/plugins/TaskFactory.h"
 #include "mozilla/UniquePtr.h"
 #include "nsCOMPtr.h"
 #include "nsIRunnable.h"
 
 namespace mozilla {
 namespace plugins {
 
 class LaunchCompleteTask : public Runnable
@@ -76,17 +76,17 @@ public:
     virtual void OnChannelError() override;
 
     bool IsConnected();
 
 private:
     void RunLaunchCompleteTask();
 
     std::string mPluginFilePath;
-    ipc::TaskFactory<PluginProcessParent> mTaskFactory;
+    TaskFactory<PluginProcessParent> mTaskFactory;
     UniquePtr<LaunchCompleteTask> mLaunchCompleteTask;
     MessageLoop* mMainMsgLoop;
     bool mRunCompleteTaskImmediately;
 
     DISALLOW_EVIL_CONSTRUCTORS(PluginProcessParent);
 };
 
 
rename from ipc/glue/TaskFactory.h
rename to dom/plugins/ipc/TaskFactory.h
--- a/ipc/glue/TaskFactory.h
+++ b/dom/plugins/ipc/TaskFactory.h
@@ -14,17 +14,17 @@
  * Chromium's factories assert if tasks are created and run on different threads,
  * which is something we need to do in PluginModuleParent (hang UI vs. main thread).
  * TaskFactory just provides cancellable tasks that don't assert this.
  * This version also allows both ScopedMethod and regular Tasks to be generated
  * by the same Factory object.
  */
 
 namespace mozilla {
-namespace ipc {
+namespace plugins {
 
 template<class T>
 class TaskFactory : public RevocableStore
 {
 private:
   template<class TaskType>
   class TaskWrapper : public TaskType
   {
@@ -98,12 +98,12 @@ protected:
     Method meth_;
     Params params_;
   };
 
 private:
   T* object_;
 };
 
-} // namespace ipc
+} // namespace plugins
 } // namespace mozilla
 
 #endif // mozilla_plugins_TaskFactory_h
--- a/dom/plugins/ipc/moz.build
+++ b/dom/plugins/ipc/moz.build
@@ -38,16 +38,17 @@ EXPORTS.mozilla.plugins += [
     'PluginScriptableObjectUtils.h',
     'PluginStreamChild.h',
     'PluginStreamParent.h',
     'PluginUtilsOSX.h',
     'PluginWidgetChild.h',
     'PluginWidgetParent.h',
     'StreamNotifyChild.h',
     'StreamNotifyParent.h',
+    'TaskFactory.h',
 ]
 
 if CONFIG['OS_ARCH'] == 'WINNT':
     EXPORTS.mozilla.plugins += [
         'PluginSurfaceParent.h',
     ]
     UNIFIED_SOURCES += [
         'PluginHangUIParent.cpp',
--- a/gfx/config/gfxFeature.h
+++ b/gfx/config/gfxFeature.h
@@ -17,17 +17,16 @@ namespace gfx {
 
 #define GFX_FEATURE_MAP(_)                                                        \
   /* Name,                        Type,         Description */                    \
   _(HW_COMPOSITING,               Feature,      "Compositing")                    \
   _(D3D11_COMPOSITING,            Feature,      "Direct3D11 Compositing")         \
   _(D3D9_COMPOSITING,             Feature,      "Direct3D9 Compositing")          \
   _(DIRECT2D,                     Feature,      "Direct2D")                       \
   _(D3D11_HW_ANGLE,               Feature,      "Direct3D11 hardware ANGLE")               \
-  _(GPU_PROCESS,                  Feature,      "GPU Process")                    \
   /* Add new entries above this comment */
 
 enum class Feature : uint32_t {
 #define MAKE_ENUM(name, type, desc) name,
   GFX_FEATURE_MAP(MAKE_ENUM)
 #undef MAKE_ENUM
   NumValues
 };
deleted file mode 100644
--- a/gfx/ipc/GPUChild.cpp
+++ /dev/null
@@ -1,52 +0,0 @@
-/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/* vim: set ts=8 sts=2 et sw=2 tw=99: */
-/* 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 "GPUChild.h"
-#include "GPUProcessHost.h"
-
-namespace mozilla {
-namespace gfx {
-
-GPUChild::GPUChild(GPUProcessHost* aHost)
- : mHost(aHost)
-{
-  MOZ_COUNT_CTOR(GPUChild);
-}
-
-GPUChild::~GPUChild()
-{
-  MOZ_COUNT_DTOR(GPUChild);
-}
-
-void
-GPUChild::ActorDestroy(ActorDestroyReason aWhy)
-{
-  mHost->OnChannelClosed();
-}
-
-class DeferredDeleteGPUChild : public Runnable
-{
-public:
-  explicit DeferredDeleteGPUChild(UniquePtr<GPUChild>&& aChild)
-    : mChild(Move(aChild))
-  {
-  }
-
-  NS_IMETHODIMP Run() override {
-    return NS_OK;
-  }
-
-private:
-  UniquePtr<GPUChild> mChild;
-};
-
-/* static */ void
-GPUChild::Destroy(UniquePtr<GPUChild>&& aChild)
-{
-  NS_DispatchToMainThread(new DeferredDeleteGPUChild(Move(aChild)));
-}
-
-} // namespace gfx
-} // namespace mozilla
deleted file mode 100644
--- a/gfx/ipc/GPUChild.h
+++ /dev/null
@@ -1,34 +0,0 @@
-/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/* vim: set ts=8 sts=2 et sw=2 tw=99: */
-/* 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 _include_mozilla_gfx_ipc_GPUChild_h_
-#define _include_mozilla_gfx_ipc_GPUChild_h_
-
-#include "mozilla/gfx/PGPUChild.h"
-#include "mozilla/UniquePtr.h"
-
-namespace mozilla {
-namespace gfx {
-
-class GPUProcessHost;
-
-class GPUChild final : public PGPUChild
-{
-public:
-  GPUChild(GPUProcessHost* aHost);
-  ~GPUChild();
-
-  static void Destroy(UniquePtr<GPUChild>&& aChild);
-
-  void ActorDestroy(ActorDestroyReason aWhy) override;
-
-private:
-  GPUProcessHost* mHost;
-};
-
-} // namespace gfx
-} // namespace mozilla
-
-#endif // _include_mozilla_gfx_ipc_GPUChild_h_
deleted file mode 100644
--- a/gfx/ipc/GPUParent.cpp
+++ /dev/null
@@ -1,62 +0,0 @@
-/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/* vim: set ts=8 sts=2 et sw=2 tw=99: */
-/* 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 "GPUParent.h"
-#include "gfxConfig.h"
-#include "GPUProcessHost.h"
-#include "mozilla/Assertions.h"
-#include "mozilla/ipc/ProcessChild.h"
-
-namespace mozilla {
-namespace gfx {
-
-using namespace ipc;
-
-GPUParent::GPUParent()
-{
-}
-
-GPUParent::~GPUParent()
-{
-}
-
-bool
-GPUParent::Init(base::ProcessId aParentPid,
-                MessageLoop* aIOLoop,
-                IPC::Channel* aChannel)
-{
-  if (NS_WARN_IF(!Open(aChannel, aParentPid, aIOLoop))) {
-    return false;
-  }
-
-  return true;
-}
-
-bool
-GPUParent::RecvNothing()
-{
-  return true;
-}
-
-void
-GPUParent::ActorDestroy(ActorDestroyReason aWhy)
-{
-  if (AbnormalShutdown == aWhy) {
-    NS_WARNING("Shutting down GPU process early due to a crash!");
-    ProcessChild::QuickExit();
-  }
-
-#ifndef NS_FREE_PERMANENT_DATA
-  // No point in going through XPCOM shutdown because we don't keep persistent
-  // state. Currently we quick-exit in RecvBeginShutdown so this should be
-  // unreachable.
-  ProcessChild::QuickExit();
-#else
-  XRE_ShutdownChildProcess();
-#endif
-}
-
-} // namespace gfx
-} // namespace mozilla
deleted file mode 100644
--- a/gfx/ipc/GPUParent.h
+++ /dev/null
@@ -1,32 +0,0 @@
-/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/* vim: set ts=8 sts=2 et sw=2 tw=99: */
-/* 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 _include_gfx_ipc_GPUParent_h__
-#define _include_gfx_ipc_GPUParent_h__
-
-#include "mozilla/gfx/PGPUParent.h"
-
-namespace mozilla {
-namespace gfx {
-
-class GPUParent final : public PGPUParent
-{
-public:
-  GPUParent();
-  ~GPUParent();
-
-  bool Init(base::ProcessId aParentPid,
-            MessageLoop* aIOLoop,
-            IPC::Channel* aChannel);
-
-  bool RecvNothing() override;
-
-  void ActorDestroy(ActorDestroyReason aWhy) override;
-};
-
-} // namespace gfx
-} // namespace mozilla
-
-#endif // _include_gfx_ipc_GPUParent_h__
deleted file mode 100644
--- a/gfx/ipc/GPUProcessHost.cpp
+++ /dev/null
@@ -1,209 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
- * vim: sts=8 sw=2 ts=2 tw=99 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 "GPUProcessHost.h"
-#include "chrome/common/process_watcher.h"
-#include "gfxPrefs.h"
-#include "mozilla/gfx/Logging.h"
-#include "nsITimer.h"
-
-namespace mozilla {
-namespace gfx {
-
-GPUProcessHost::GPUProcessHost(Listener* aListener)
- : GeckoChildProcessHost(GeckoProcessType_GPU),
-   mListener(aListener),
-   mTaskFactory(this),
-   mLaunchPhase(LaunchPhase::Unlaunched),
-   mShutdownRequested(false)
-{
-  MOZ_COUNT_CTOR(GPUProcessHost);
-}
-
-GPUProcessHost::~GPUProcessHost()
-{
-  MOZ_COUNT_DTOR(GPUProcessHost);
-}
-
-bool
-GPUProcessHost::Launch()
-{
-  MOZ_ASSERT(mLaunchPhase == LaunchPhase::Unlaunched);
-  MOZ_ASSERT(!mGPUChild);
-
-  mLaunchPhase = LaunchPhase::Waiting;
-  if (!GeckoChildProcessHost::AsyncLaunch()) {
-    mLaunchPhase = LaunchPhase::Complete;
-    return false;
-  }
-  return true;
-}
-
-bool
-GPUProcessHost::WaitForLaunch()
-{
-  if (mLaunchPhase == LaunchPhase::Complete) {
-    return !!mGPUChild;
-  }
-
-  int32_t timeoutMs = gfxPrefs::GPUProcessDevTimeoutMs();
-
-  // Our caller expects the connection to be finished after we return, so we
-  // immediately set up the IPDL actor and fire callbacks. The IO thread will
-  // still dispatch a notification to the main thread - we'll just ignore it.
-  bool result = GeckoChildProcessHost::WaitUntilConnected(timeoutMs);
-  InitAfterConnect(result);
-  return result;
-}
-
-void
-GPUProcessHost::OnChannelConnected(int32_t peer_pid)
-{
-  MOZ_ASSERT(!NS_IsMainThread());
-
-  GeckoChildProcessHost::OnChannelConnected(peer_pid);
-
-  // Post a task to the main thread. Take the lock because mTaskFactory is not
-  // thread-safe.
-  RefPtr<Runnable> runnable;
-  {
-    MonitorAutoLock lock(mMonitor);
-    runnable = mTaskFactory.NewRunnableMethod(&GPUProcessHost::OnChannelConnectedTask);
-  }
-  NS_DispatchToMainThread(runnable);
-}
-
-void
-GPUProcessHost::OnChannelError()
-{
-  MOZ_ASSERT(!NS_IsMainThread());
-
-  GeckoChildProcessHost::OnChannelError();
-
-  // Post a task to the main thread. Take the lock because mTaskFactory is not
-  // thread-safe.
-  RefPtr<Runnable> runnable;
-  {
-    MonitorAutoLock lock(mMonitor);
-    runnable = mTaskFactory.NewRunnableMethod(&GPUProcessHost::OnChannelErrorTask);
-  }
-  NS_DispatchToMainThread(runnable);
-}
-
-void
-GPUProcessHost::OnChannelConnectedTask()
-{
-  if (mLaunchPhase == LaunchPhase::Waiting) {
-    InitAfterConnect(true);
-  }
-}
-
-void
-GPUProcessHost::OnChannelErrorTask()
-{
-  if (mLaunchPhase == LaunchPhase::Waiting) {
-    InitAfterConnect(false);
-  }
-}
-
-void
-GPUProcessHost::InitAfterConnect(bool aSucceeded)
-{
-  MOZ_ASSERT(mLaunchPhase == LaunchPhase::Waiting);
-  MOZ_ASSERT(!mGPUChild);
-
-  mLaunchPhase = LaunchPhase::Complete;
-
-  if (aSucceeded) {
-    mGPUChild = MakeUnique<GPUChild>(this);
-    DebugOnly<bool> rv =
-      mGPUChild->Open(GetChannel(), base::GetProcId(GetChildProcessHandle()));
-    MOZ_ASSERT(rv);
-  }
-
-  if (mListener) {
-    mListener->OnProcessLaunchComplete(this);
-  }
-}
-
-void
-GPUProcessHost::Shutdown()
-{
-  MOZ_ASSERT(!mShutdownRequested);
-
-  mListener = nullptr;
-
-  if (mGPUChild) {
-    // OnChannelClosed uses this to check if the shutdown was expected or
-    // unexpected.
-    mShutdownRequested = true;
-
-#ifdef NS_FREE_PERMANENT_DATA
-    mGPUChild->Close();
-#else
-    // No need to communicate shutdown, the GPU process doesn't need to
-    // communicate anything back.
-    KillHard("NormalShutdown");
-#endif
-
-    // Wait for ActorDestroy.
-    return;
-  }
-
-  DestroyProcess();
-}
-
-void
-GPUProcessHost::OnChannelClosed()
-{
-  if (!mShutdownRequested) {
-    // This is an unclean shutdown. Notify our listener that we're going away.
-    if (mListener) {
-      mListener->OnProcessUnexpectedShutdown(this);
-    }
-  }
-
-  // Release the actor.
-  GPUChild::Destroy(Move(mGPUChild));
-  MOZ_ASSERT(!mGPUChild);
-
-  // If the owner of GPUProcessHost already requested shutdown, we can now
-  // schedule destruction. Otherwise we must wait for someone to call
-  // Shutdown. Note that GPUProcessManager calls Shutdown within
-  // OnProcessUnexpectedShutdown.
-  if (mShutdownRequested) {
-    DestroyProcess();
-  }
-}
-
-void
-GPUProcessHost::KillHard(const char* aReason)
-{
-  ProcessHandle handle = GetChildProcessHandle();
-  if (!base::KillProcess(handle, base::PROCESS_END_KILLED_BY_USER, false)) {
-    NS_WARNING("failed to kill subprocess!");
-  }
-
-  SetAlreadyDead();
-  XRE_GetIOMessageLoop()->PostTask(
-    NewRunnableFunction(&ProcessWatcher::EnsureProcessTerminated, handle, /*force=*/true));
-}
-
-void
-GPUProcessHost::DestroyProcess()
-{
-  // Cancel all tasks. We don't want anything triggering after our caller
-  // expects this to go away.
-  {
-    MonitorAutoLock lock(mMonitor);
-    mTaskFactory.RevokeAll();
-  }
-
-  DissociateActor();
-}
-
-} // namespace gfx
-} // namespace mozilla
deleted file mode 100644
--- a/gfx/ipc/GPUProcessHost.h
+++ /dev/null
@@ -1,125 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
- * vim: sts=8 sw=2 ts=2 tw=99 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/. */
-
-#ifndef _include_mozilla_gfx_ipc_GPUProcessHost_h_
-#define _include_mozilla_gfx_ipc_GPUProcessHost_h_
-
-#include "mozilla/Function.h"
-#include "mozilla/Maybe.h"
-#include "mozilla/UniquePtr.h"
-#include "mozilla/ipc/GeckoChildProcessHost.h"
-#include "mozilla/ipc/ProtocolUtils.h"
-#include "mozilla/ipc/TaskFactory.h"
-
-class nsITimer;
-
-namespace mozilla {
-namespace gfx {
-
-class GPUChild;
-
-// GPUProcessHost is the "parent process" container for a subprocess handle and
-// IPC connection. It owns the parent process IPDL actor, which in this case,
-// is a GPUChild.
-//
-// GPUProcessHosts are allocated and managed by GPUProcessManager. For all
-// intents and purposes it is a singleton, though more than one may be allocated
-// at a time due to its shutdown being asynchronous.
-class GPUProcessHost final : public ipc::GeckoChildProcessHost
-{
-  friend class GPUChild;
-
-public:
-  class Listener {
-  public:
-    virtual void OnProcessLaunchComplete(GPUProcessHost* aHost)
-    {}
-
-    // The GPUProcessHost has unexpectedly shutdown or had its connection
-    // severed. This is not called if an error occurs after calling
-    // Shutdown().
-    virtual void OnProcessUnexpectedShutdown(GPUProcessHost* aHost)
-    {}
-  };
-
-public:
-  GPUProcessHost(Listener* listener);
-  ~GPUProcessHost();
-
-  // Launch the subprocess asynchronously. On failure, false is returned.
-  // Otherwise, true is returned, and the OnLaunchComplete listener callback
-  // will be invoked either when a connection has been established, or if a
-  // connection could not be established due to an asynchronous error.
-  bool Launch();
-
-  // If the process is being launched, block until it has launched and
-  // connected. If a launch task is pending, it will fire immediately.
-  //
-  // Returns true if the process is successfully connected; false otherwise.
-  bool WaitForLaunch();
-
-  // Inform the process that it should clean up its resources and shut down.
-  // This initiates an asynchronous shutdown sequence. After this method returns,
-  // it is safe for the caller to forget its pointer to the GPUProcessHost.
-  //
-  // After this returns, the attached Listener is no longer used.
-  void Shutdown();
-
-  // Return the actor for the top-level actor of the process. If the process
-  // has not connected yet, this returns null.
-  GPUChild* GetActor() const {
-    return mGPUChild.get();
-  }
-
-  bool IsConnected() const {
-    return !!mGPUChild;
-  }
-
-  // Called on the IO thread.
-  void OnChannelConnected(int32_t peer_pid) override;
-  void OnChannelError() override;
-
-  void SetListener(Listener* aListener);
-
-private:
-  // Called on the main thread.
-  void OnChannelConnectedTask();
-  void OnChannelErrorTask();
-
-  // Called on the main thread after a connection has been established.
-  void InitAfterConnect(bool aSucceeded);
-
-  // Called on the main thread when the mGPUChild actor is shutting down.
-  void OnChannelClosed();
-
-  // Kill the remote process, triggering IPC shutdown.
-  void KillHard(const char* aReason);
-
-  void DestroyProcess();
-
-private:
-  DISALLOW_COPY_AND_ASSIGN(GPUProcessHost);
-
-  Listener* mListener;
-  ipc::TaskFactory<GPUProcessHost> mTaskFactory;
-
-  enum class LaunchPhase {
-    Unlaunched,
-    Waiting,
-    Complete
-  };
-  LaunchPhase mLaunchPhase;
-
-  UniquePtr<GPUChild> mGPUChild;
-  Listener* listener_;
-
-  bool mShutdownRequested;
-};
-
-} // namespace gfx
-} // namespace mozilla
-
-#endif // _include_mozilla_gfx_ipc_GPUProcessHost_h_
deleted file mode 100644
--- a/gfx/ipc/GPUProcessImpl.cpp
+++ /dev/null
@@ -1,37 +0,0 @@
-/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/* vim: set ts=8 sts=2 et sw=2 tw=99: */
-/* 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 "GPUProcessImpl.h"
-#include "mozilla/ipc/IOThreadChild.h"
-
-namespace mozilla {
-namespace gfx {
-
-using namespace ipc;
-
-GPUProcessImpl::GPUProcessImpl(ProcessId aParentPid)
- : ProcessChild(aParentPid)
-{
-}
-
-GPUProcessImpl::~GPUProcessImpl()
-{
-}
-
-bool
-GPUProcessImpl::Init()
-{
-  return mGPU.Init(ParentPid(),
-                   IOThreadChild::message_loop(),
-                   IOThreadChild::channel());
-}
-
-void
-GPUProcessImpl::CleanUp()
-{
-}
-
-} // namespace gfx
-} // namespace mozilla
deleted file mode 100644
--- a/gfx/ipc/GPUProcessImpl.h
+++ /dev/null
@@ -1,34 +0,0 @@
-/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/* vim: set ts=8 sts=2 et sw=2 tw=99: */
-/* 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 _include_gfx_ipc_GPUProcessImpl_h__
-#define _include_gfx_ipc_GPUProcessImpl_h__
-
-#include "mozilla/ipc/ProcessChild.h"
-#include "GPUParent.h"
-
-namespace mozilla {
-namespace gfx {
-
-// This class owns the subprocess instance of a PGPU - which in this case,
-// is a GPUParent. It is instantiated as a singleton in XRE_InitChildProcess.
-class GPUProcessImpl final : public ipc::ProcessChild
-{
-public:
-  explicit GPUProcessImpl(ProcessId aParentPid);
-  ~GPUProcessImpl();
-
-  bool Init() override;
-  void CleanUp() override;
-
-private:
-  DISALLOW_COPY_AND_ASSIGN(GPUProcessImpl);
-  GPUParent mGPU;
-};
-
-} // namespace gfx
-} // namespace mozilla
-
-#endif // _include_gfx_ipc_GPUProcessImpl_h__
--- a/gfx/ipc/GPUProcessManager.cpp
+++ b/gfx/ipc/GPUProcessManager.cpp
@@ -1,18 +1,16 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=99: */
 /* 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 "GPUProcessManager.h"
-#include "GPUProcessHost.h"
 #include "mozilla/layers/CompositorSession.h"
 #include "mozilla/StaticPtr.h"
-#include "nsContentUtils.h"
 
 namespace mozilla {
 namespace gfx {
 
 using namespace mozilla::layers;
 
 static StaticAutoPtr<GPUProcessManager> sSingleton;
 
@@ -31,127 +29,21 @@ GPUProcessManager::Initialize()
 
 void
 GPUProcessManager::Shutdown()
 {
   sSingleton = nullptr;
 }
 
 GPUProcessManager::GPUProcessManager()
- : mProcess(nullptr),
-   mGPUChild(nullptr)
 {
-  mObserver = new Observer(this);
-  nsContentUtils::RegisterShutdownObserver(mObserver);
 }
 
 GPUProcessManager::~GPUProcessManager()
 {
-  // The GPU process should have already been shut down.
-  MOZ_ASSERT(!mProcess && !mGPUChild);
-
-  // We should have already removed observers.
-  MOZ_ASSERT(!mObserver);
-}
-
-NS_IMPL_ISUPPORTS(GPUProcessManager::Observer, nsIObserver);
-
-GPUProcessManager::Observer::Observer(GPUProcessManager* aManager)
- : mManager(aManager)
-{
-}
-
-NS_IMETHODIMP
-GPUProcessManager::Observer::Observe(nsISupports* aSubject, const char* aTopic, const char16_t* aData)
-{
-  if (!strcmp(aTopic, NS_XPCOM_SHUTDOWN_OBSERVER_ID)) {
-    mManager->OnXPCOMShutdown();
-  }
-  return NS_OK;
-}
-
-void
-GPUProcessManager::OnXPCOMShutdown()
-{
-  if (mObserver) {
-    nsContentUtils::UnregisterShutdownObserver(mObserver);
-    mObserver = nullptr;
-  }
-
-  DestroyProcess();
-}
-
-void
-GPUProcessManager::EnableGPUProcess()
-{
-  if (mProcess) {
-    return;
-  }
-
-  // The subprocess is launched asynchronously, so we wait for a callback to
-  // acquire the IPDL actor.
-  mProcess = new GPUProcessHost(this);
-  if (!mProcess->Launch()) {
-    DisableGPUProcess("Failed to launch GPU process");
-  }
-}
-
-void
-GPUProcessManager::DisableGPUProcess(const char* aMessage)
-{
-  gfxConfig::SetFailed(Feature::GPU_PROCESS, FeatureStatus::Failed, aMessage);
-  gfxCriticalNote << aMessage;
-
-  DestroyProcess();
-}
-
-void
-GPUProcessManager::EnsureGPUReady()
-{
-  if (mProcess && mProcess->IsConnected()) {
-    if (!mProcess->WaitForLaunch()) {
-      // If this fails, we should have fired OnProcessLaunchComplete and
-      // removed the process.
-      MOZ_ASSERT(!mProcess && !mGPUChild);
-      return;
-    }
-  }
-}
-
-void
-GPUProcessManager::OnProcessLaunchComplete(GPUProcessHost* aHost)
-{
-  MOZ_ASSERT(mProcess && mProcess == aHost);
-
-  if (!mProcess->IsConnected()) {
-    DisableGPUProcess("Failed to launch GPU process");
-    return;
-  }
-
-  mGPUChild = mProcess->GetActor();
-}
-
-void
-GPUProcessManager::OnProcessUnexpectedShutdown(GPUProcessHost* aHost)
-{
-  MOZ_ASSERT(mProcess && mProcess == aHost);
-
-  DestroyProcess();
-}
-
-void
-GPUProcessManager::DestroyProcess()
-{
-  if (!mProcess) {
-    return;
-  }
-
-  mProcess->Shutdown();
-  mProcess = nullptr;
-  mGPUChild = nullptr;
 }
 
 already_AddRefed<CompositorSession>
 GPUProcessManager::CreateTopLevelCompositor(widget::CompositorWidgetProxy* aProxy,
                                             ClientLayerManager* aLayerManager,
                                             CSSToLayoutDeviceScale aScale,
                                             bool aUseAPZ,
                                             bool aUseExternalSurfaceSize,
--- a/gfx/ipc/GPUProcessManager.h
+++ b/gfx/ipc/GPUProcessManager.h
@@ -5,19 +5,17 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 #ifndef _include_mozilla_gfx_ipc_GPUProcessManager_h_
 #define _include_mozilla_gfx_ipc_GPUProcessManager_h_
 
 #include "base/basictypes.h"
 #include "base/process.h"
 #include "Units.h"
 #include "mozilla/dom/ipc/IdType.h"
-#include "mozilla/gfx/GPUProcessHost.h"
 #include "mozilla/ipc/Transport.h"
-#include "nsIObserverService.h"
 
 namespace mozilla {
 namespace layers {
 class APZCTreeManager;
 class CompositorSession;
 class ClientLayerManager;
 class CompositorUpdateObserver;
 class PCompositorBridgeParent;
@@ -29,41 +27,31 @@ namespace dom {
 class ContentParent;
 class TabParent;
 } // namespace dom
 namespace ipc {
 class GeckoChildProcessHost;
 } // namespace ipc
 namespace gfx {
 
-class GPUChild;
-
 // The GPUProcessManager is a singleton responsible for creating GPU-bound
 // objects that may live in another process. Currently, it provides access
 // to the compositor via CompositorBridgeParent.
-class GPUProcessManager final : public GPUProcessHost::Listener
+class GPUProcessManager final
 {
   typedef layers::APZCTreeManager APZCTreeManager;
   typedef layers::CompositorUpdateObserver CompositorUpdateObserver;
 
 public:
   static void Initialize();
   static void Shutdown();
   static GPUProcessManager* Get();
 
   ~GPUProcessManager();
 
-  // If not using a GPU process, launch a new GPU process asynchronously.
-  void EnableGPUProcess();
-
-  // Ensure that GPU-bound methods can be used. If no GPU process is being
-  // used, or one is launched and ready, this function returns immediately.
-  // Otherwise it blocks until the GPU process has finished launching.
-  void EnsureGPUReady();
-
   already_AddRefed<layers::CompositorSession> CreateTopLevelCompositor(
     widget::CompositorWidgetProxy* aProxy,
     layers::ClientLayerManager* aLayerManager,
     CSSToLayoutDeviceScale aScale,
     bool aUseAPZ,
     bool aUseExternalSurfaceSize,
     int aSurfaceWidth,
     int aSurfaceHeight);
@@ -99,49 +87,18 @@ public:
   // aContentParent The ContentParent for the process that the TabChild for
   //                aTabId lives in.
   // aBrowserParent The toplevel TabParent for aTabId.
   bool UpdateRemoteContentController(uint64_t aLayersId,
                                      dom::ContentParent* aContentParent,
                                      const dom::TabId& aTabId,
                                      dom::TabParent* aBrowserParent);
 
-  void OnProcessLaunchComplete(GPUProcessHost* aHost) override;
-  void OnProcessUnexpectedShutdown(GPUProcessHost* aHost) override;
-
-private:
-  // Called from our xpcom-shutdown observer.
-  void OnXPCOMShutdown();
-
 private:
   GPUProcessManager();
 
-  // Permanently disable the GPU process and record a message why.
-  void DisableGPUProcess(const char* aMessage);
-
-  // Shutdown the GPU process.
-  void DestroyProcess();
-
   DISALLOW_COPY_AND_ASSIGN(GPUProcessManager);
-
-  class Observer final : public nsIObserver {
-  public:
-    NS_DECL_ISUPPORTS
-    NS_DECL_NSIOBSERVER
-    Observer(GPUProcessManager* aManager);
-
-  protected:
-    ~Observer() {}
-
-    GPUProcessManager* mManager;
-  };
-  friend class Observer;
-
-private:
-  RefPtr<Observer> mObserver;
-  GPUProcessHost* mProcess;
-  GPUChild* mGPUChild;
 };
 
 } // namespace gfx
 } // namespace mozilla
 
 #endif // _include_mozilla_gfx_ipc_GPUProcessManager_h_
deleted file mode 100644
--- a/gfx/ipc/PGPU.ipdl
+++ /dev/null
@@ -1,17 +0,0 @@
-/* -*- Mode: C++; tab-width: 8; 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/. */
-
-namespace mozilla {
-namespace gfx {
-
-sync protocol PGPU
-{
-parent:
-  // Sent by the UI process to initiate shutdown.
-  async Nothing();
-};
-
-} // namespace gfx
-} // namespace mozilla
--- a/gfx/ipc/moz.build
+++ b/gfx/ipc/moz.build
@@ -5,20 +5,16 @@
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 EXPORTS.mozilla += [
     'D3DMessageUtils.h',
     'GfxMessageUtils.h'
 ]
 
 EXPORTS.mozilla.gfx += [
-    'GPUChild.h',
-    'GPUParent.h',
-    'GPUProcessHost.h',
-    'GPUProcessImpl.h',
     'GPUProcessManager.h',
     'SharedDIB.h',
 ]
 
 EXPORTS.mozilla.layers += [
     'CompositorSession.h',
 ]
 
@@ -30,27 +26,22 @@ if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'wind
     UNIFIED_SOURCES += [
         'SharedDIBSurface.cpp',
         'SharedDIBWin.cpp',
     ]
 
 UNIFIED_SOURCES += [
     'CompositorSession.cpp',
     'D3DMessageUtils.cpp',
-    'GPUChild.cpp',
-    'GPUParent.cpp',
-    'GPUProcessHost.cpp',
-    'GPUProcessImpl.cpp',
     'GPUProcessManager.cpp',
     'SharedDIB.cpp',
 ]
 
 IPDL_SOURCES = [
     'GraphicsMessages.ipdlh',
-    'PGPU.ipdl',
 ]
 
 include('/ipc/chromium/chromium-config.mozbuild')
 
 FINAL_LIBRARY = 'xul'
 
 CXXFLAGS += CONFIG['MOZ_CAIRO_CFLAGS']
 CXXFLAGS += CONFIG['TK_CFLAGS']
--- a/gfx/thebes/gfxPlatform.cpp
+++ b/gfx/thebes/gfxPlatform.cpp
@@ -137,17 +137,16 @@ class mozilla::gl::SkiaGLGlue : public G
 #include "nsIGfxInfo.h"
 #include "nsIXULRuntime.h"
 #include "VsyncSource.h"
 #include "SoftwareVsyncSource.h"
 #include "nscore.h" // for NS_FREE_PERMANENT_DATA
 #include "mozilla/dom/ContentChild.h"
 #include "gfxVR.h"
 #include "VRManagerChild.h"
-#include "mozilla/gfx/GPUParent.h"
 
 namespace mozilla {
 namespace layers {
 #ifdef MOZ_WIDGET_GONK
 void InitGralloc();
 #endif
 void ShutdownTileCache();
 } // namespace layers
@@ -590,19 +589,17 @@ gfxPlatform::Init()
     gEverInitialized = true;
 
     // Initialize the preferences by creating the singleton.
     gfxPrefs::GetSingleton();
     MediaPrefs::GetSingleton();
 
     gfxConfig::Init();
 
-    if (XRE_IsParentProcess()) {
-      GPUProcessManager::Initialize();
-    }
+    GPUProcessManager::Initialize();
 
     auto fwd = new CrashStatsLogForwarder("GraphicsCriticalError");
     fwd->SetCircularBufferSize(gfxPrefs::GfxLoggingCrashLength());
 
     // Drop a note in the crash report if we end up forcing an option that could
     // destabilize things.  New items should be appended at the end (of an existing
     // or in a new section), so that we don't have to know the version to interpret
     // these cryptic strings.
@@ -846,19 +843,17 @@ gfxPlatform::Shutdown()
     // most platforms.  Windows is a "special snowflake", though, and has three
     // context providers available, so we have to shut all of them down.
     // We should only support the default GL provider on Windows; then, this
     // could go away. Unfortunately, we currently support WGL (the default) for
     // WebGL on Optimus.
     GLContextProviderEGL::Shutdown();
 #endif
 
-    if (XRE_IsParentProcess()) {
-      GPUProcessManager::Shutdown();
-    }
+    GPUProcessManager::Shutdown();
 
     // This is a bit iffy - we're assuming that we were the ones that set the
     // log forwarder in the Factory, so that it's our responsibility to
     // delete it.
     delete mozilla::gfx::Factory::GetLogForwarder();
     mozilla::gfx::Factory::SetLogForwarder(nullptr);
 
     gfx::Factory::ShutDown();
@@ -2115,33 +2110,16 @@ gfxPlatform::InitAcceleration()
          sLayersSupportsHardwareVideoDecoding = true;
     }
   }
 
   Preferences::AddBoolVarCache(&sLayersHardwareVideoDecodingFailed,
                                "media.hardware-video-decoding.failed",
                                false);
 
-  if (XRE_IsParentProcess()) {
-    if (gfxPrefs::GPUProcessDevEnabled()) {
-      // We want to hide this from about:support, so only set a default if the
-      // pref is known to be true.
-      gfxConfig::SetDefaultFromPref(
-        Feature::GPU_PROCESS,
-        gfxPrefs::GetGPUProcessDevEnabledPrefName(),
-        true,
-        gfxPrefs::GetGPUProcessDevEnabledPrefDefault());
-    }
-
-    if (gfxConfig::IsEnabled(Feature::GPU_PROCESS)) {
-      GPUProcessManager* gpu = GPUProcessManager::Get();
-      gpu->EnableGPUProcess();
-    }
-  }
-
   sLayersAccelerationPrefsInitialized = true;
 }
 
 void
 gfxPlatform::InitCompositorAccelerationPrefs()
 {
   const char *acceleratedEnv = PR_GetEnv("MOZ_ACCELERATED");
 
--- a/gfx/thebes/gfxPrefs.h
+++ b/gfx/thebes/gfxPrefs.h
@@ -66,17 +66,17 @@ static const char* Get##Name##PrefName()
 static Type Get##Name##PrefDefault() { return Default; }                      \
 private:                                                                      \
 PrefTemplate<UpdatePolicy::Update, Type, Get##Name##PrefDefault, Get##Name##PrefName> mPref##Name
 
 class PreferenceAccessImpl;
 class gfxPrefs;
 class gfxPrefs final
 {
-private:
+  private:
   /// See Logging.h.  This lets Moz2D access preference values it owns.
   PreferenceAccessImpl* mMoz2DPrefAccess;
 
 private:
   // Enums for the update policy.
   enum class UpdatePolicy {
     Skip, // Set the value to default, skip any Preferences calls
     Once, // Evaluate the preference once, unchanged during the session
@@ -360,18 +360,16 @@ private:
   // decrease it until we hit mid gray at -1 contrast, after that it gets weird.
   DECL_GFX_PREF(Live, "layers.effect.contrast",                LayersEffectContrast, float, 0.0f);
   DECL_GFX_PREF(Live, "layers.effect.grayscale",               LayersEffectGrayscale, bool, false);
   DECL_GFX_PREF(Live, "layers.effect.invert",                  LayersEffectInvert, bool, false);
   DECL_GFX_PREF(Once, "layers.enable-tiles",                   LayersTilesEnabled, bool, false);
   DECL_GFX_PREF(Live, "layers.flash-borders",                  FlashLayerBorders, bool, false);
   DECL_GFX_PREF(Once, "layers.force-shmem-tiles",              ForceShmemTiles, bool, false);
   DECL_GFX_PREF(Live, "layers.frame-counter",                  DrawFrameCounter, bool, false);
-  DECL_GFX_PREF(Once, "layers.gpu-process.dev.enabled",        GPUProcessDevEnabled, bool, false);
-  DECL_GFX_PREF(Once, "layers.gpu-process.dev.timeout_ms",     GPUProcessDevTimeoutMs, int32_t, 5000);
   DECL_GFX_PREF(Once, "layers.gralloc.disable",                DisableGralloc, bool, false);
   DECL_GFX_PREF(Live, "layers.low-precision-buffer",           UseLowPrecisionBuffer, bool, false);
   DECL_GFX_PREF(Live, "layers.low-precision-opacity",          LowPrecisionOpacity, float, 1.0f);
   DECL_GFX_PREF(Live, "layers.low-precision-resolution",       LowPrecisionResolution, float, 0.25f);
   DECL_GFX_PREF(Live, "layers.max-active",                     MaxActiveLayers, int32_t, -1);
   DECL_GFX_PREF(Once, "layers.offmainthreadcomposition.force-disabled", LayersOffMainThreadCompositionForceDisabled, bool, false);
   DECL_GFX_PREF(Live, "layers.offmainthreadcomposition.frame-rate", LayersCompositionFrameRate, int32_t,-1);
   DECL_GFX_PREF(Live, "layers.orientation.sync.timeout",       OrientationSyncMillis, uint32_t, (uint32_t)0);
--- a/ipc/glue/GeckoChildProcessHost.cpp
+++ b/ipc/glue/GeckoChildProcessHost.cpp
@@ -1067,18 +1067,16 @@ GeckoChildProcessHost::PerformAsyncLaunc
         auto level = isWidevine ? SandboxBroker::Restricted : SandboxBroker::LockDown;
         bool ok = mSandboxBroker.SetSecurityLevelForGMPlugin(level);
         if (!ok) {
           return false;
         }
         shouldSandboxCurrentProcess = true;
       }
       break;
-    case GeckoProcessType_GPU:
-      break;
     case GeckoProcessType_Default:
     default:
       MOZ_CRASH("Bad process type in GeckoChildProcessHost");
       break;
   };
 
   if (shouldSandboxCurrentProcess) {
     MaybeAddNsprLogFileAccess(mAllowedFilesReadWrite);
--- a/ipc/glue/moz.build
+++ b/ipc/glue/moz.build
@@ -30,17 +30,16 @@ EXPORTS.mozilla.ipc += [
     'ProcessChild.h',
     'ProtocolUtils.h',
     'ScopedXREEmbed.h',
     'SendStream.h',
     'SendStreamAlloc.h',
     'SharedMemory.h',
     'SharedMemoryBasic.h',
     'Shmem.h',
-    'TaskFactory.h',
     'Transport.h',
     'URIUtils.h',
     'WindowsMessageLoop.h',
 ]
 
 if CONFIG['MOZ_FAULTY'] == '1':
     EXPORTS.mozilla.ipc += ['Faulty.h']
     SOURCES += ['Faulty.cpp']
--- a/toolkit/xre/nsAppRunner.cpp
+++ b/toolkit/xre/nsAppRunner.cpp
@@ -955,21 +955,19 @@ nsXULAppInfo::GetWidgetToolkit(nsACStrin
   static_assert(nsIXULRuntime::PROCESS_TYPE_ ## a == \
                 static_cast<int>(GeckoProcessType_ ## b), \
                 "GeckoProcessType in nsXULAppAPI.h not synchronized with nsIXULRuntime.idl");
 
 SYNC_ENUMS(DEFAULT, Default)
 SYNC_ENUMS(PLUGIN, Plugin)
 SYNC_ENUMS(CONTENT, Content)
 SYNC_ENUMS(IPDLUNITTEST, IPDLUnitTest)
-SYNC_ENUMS(GMPLUGIN, GMPlugin)
-SYNC_ENUMS(GPU, GPU)
 
 // .. and ensure that that is all of them:
-static_assert(GeckoProcessType_GPU + 1 == GeckoProcessType_End,
+static_assert(GeckoProcessType_GMPlugin + 1 == GeckoProcessType_End,
               "Did not find the final GeckoProcessType");
 
 NS_IMETHODIMP
 nsXULAppInfo::GetProcessType(uint32_t* aResult)
 {
   NS_ENSURE_ARG_POINTER(aResult);
   *aResult = XRE_GetProcessType();
   return NS_OK;
--- a/toolkit/xre/nsEmbedFunctions.cpp
+++ b/toolkit/xre/nsEmbedFunctions.cpp
@@ -68,17 +68,16 @@
 #include "mozilla/dom/ContentChild.h"
 
 #include "mozilla/ipc/TestShellParent.h"
 #include "mozilla/ipc/XPCShellEnvironment.h"
 #include "mozilla/WindowsDllBlocklist.h"
 
 #include "GMPProcessChild.h"
 #include "GMPLoader.h"
-#include "mozilla/gfx/GPUProcessImpl.h"
 
 #include "GeckoProfiler.h"
 
 #include "mozilla/Telemetry.h"
 
 #if defined(MOZ_SANDBOX) && defined(XP_WIN)
 #include "mozilla/sandboxTarget.h"
 #include "mozilla/sandboxing/loggingCallbacks.h"
@@ -562,19 +561,16 @@ XRE_InitChildProcess(int aArgc,
   switch (XRE_GetProcessType()) {
   case GeckoProcessType_Content:
       // Content processes need the XPCOM/chromium frankenventloop
       uiLoopType = MessageLoop::TYPE_MOZILLA_CHILD;
       break;
   case GeckoProcessType_GMPlugin:
       uiLoopType = MessageLoop::TYPE_DEFAULT;
       break;
-  case GeckoProcessType_GPU:
-      uiLoopType = MessageLoop::TYPE_UI;
-      break;
   default:
       uiLoopType = MessageLoop::TYPE_UI;
       break;
   }
 
   {
     // This is a lexical scope for the MessageLoop below.  We want it
     // to go out of scope before NS_LogTerm() so that we don't get
@@ -620,20 +616,16 @@ XRE_InitChildProcess(int aArgc,
         NS_RUNTIMEABORT("rebuild with --enable-ipdl-tests");
 #endif
         break;
 
       case GeckoProcessType_GMPlugin:
         process = new gmp::GMPProcessChild(parentPID);
         break;
 
-      case GeckoProcessType_GPU:
-        process = new gfx::GPUProcessImpl(parentPID);
-        break;
-
       default:
         NS_RUNTIMEABORT("Unknown main thread class");
       }
 
       if (!process->Init()) {
         profiler_shutdown();
         NS_LogTerm();
         return NS_ERROR_FAILURE;
--- a/xpcom/build/nsXULAppAPI.h
+++ b/xpcom/build/nsXULAppAPI.h
@@ -396,29 +396,26 @@ enum GeckoProcessType
 
   GeckoProcessType_Plugin,
   GeckoProcessType_Content,
 
   GeckoProcessType_IPDLUnitTest,
 
   GeckoProcessType_GMPlugin, // Gecko Media Plugin
 
-  GeckoProcessType_GPU,      // GPU and compositor process
-
   GeckoProcessType_End,
   GeckoProcessType_Invalid = GeckoProcessType_End
 };
 
 static const char* const kGeckoProcessTypeString[] = {
   "default",
   "plugin",
   "tab",
   "ipdlunittest",
-  "geckomediaplugin",
-  "gpu"
+  "geckomediaplugin"
 };
 
 static_assert(MOZ_ARRAY_LENGTH(kGeckoProcessTypeString) ==
               GeckoProcessType_End,
               "Array length mismatch");
 
 XRE_API(const char*,
         XRE_ChildProcessTypeToString, (GeckoProcessType aProcessType))
--- a/xpcom/system/nsIXULRuntime.idl
+++ b/xpcom/system/nsIXULRuntime.idl
@@ -69,17 +69,16 @@ interface nsIXULRuntime : nsISupports
   /**
    * The legal values of processType.
    */
   const unsigned long PROCESS_TYPE_DEFAULT = 0;
   const unsigned long PROCESS_TYPE_PLUGIN = 1;
   const unsigned long PROCESS_TYPE_CONTENT = 2;
   const unsigned long PROCESS_TYPE_IPDLUNITTEST = 3;
   const unsigned long PROCESS_TYPE_GMPLUGIN = 4;
-  const unsigned long PROCESS_TYPE_GPU = 5;
 
   /**
    * The type of the caller's process.  Returns one of the values above.
    */
   readonly attribute unsigned long processType;
 
   /**
    * The system process ID of the caller's process.