Back out cset ae5c9d27cc3c (bug 1340067) for causing intermittent linux64qr-opt reftest-e10-6 and other failures. r=backout
authorKartikaya Gupta <kgupta@mozilla.com>
Fri, 17 Feb 2017 09:37:08 -0500
changeset 373013 f6a20aef8d1066dee2a351c069a6bf84355d8d72
parent 373012 ce81b6b4c8f28a8aec74d71ed84915ecc1cd5807
child 373014 458e659ab1f2157ac67d0eeb691ee4c9a1d69c33
push id10863
push userjlorenzo@mozilla.com
push dateMon, 06 Mar 2017 23:02:23 +0000
treeherdermozilla-aurora@0931190cd725 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbackout
bugs1340067
milestone54.0a1
backs outae5c9d27cc3cb7e309b9b21d12a4c338a5de82a0
Back out cset ae5c9d27cc3c (bug 1340067) for causing intermittent linux64qr-opt reftest-e10-6 and other failures. r=backout
gfx/layers/ipc/PWebRenderBridge.ipdl
gfx/layers/wr/WebRenderBridgeChild.cpp
gfx/layers/wr/WebRenderBridgeParent.cpp
gfx/layers/wr/WebRenderBridgeParent.h
--- a/gfx/layers/ipc/PWebRenderBridge.ipdl
+++ b/gfx/layers/ipc/PWebRenderBridge.ipdl
@@ -32,17 +32,18 @@ parent:
 
   sync Create(IntSize aSize);
   sync AddImage(IntSize aSize, uint32_t aStride,
                 SurfaceFormat aFormat, ByteBuffer aBytes)
     returns (ImageKey aOutImageKey);
   sync UpdateImage(ImageKey aImageKey, IntSize aSize,
                    SurfaceFormat aFormat, ByteBuffer aBytes);
   sync DeleteImage(ImageKey aImageKey);
-  async DPBegin(IntSize aSize);
+  sync DPBegin(IntSize aSize)
+    returns (bool aOutSuccess);
   async DPEnd(WebRenderCommand[] commands, OpDestroy[] toDestroy, uint64_t fwdTransactionId, uint64_t transactionId);
   sync DPSyncEnd(WebRenderCommand[] commands, OpDestroy[] toDestroy, uint64_t fwdTransactionId, uint64_t transactionId);
   sync DPGetSnapshot(PTexture texture);
   async AddExternalImageId(uint64_t aImageId, CompositableHandle aHandle);
   async AddExternalImageIdForCompositable(uint64_t aImageId, CompositableHandle aHandle);
   async RemoveExternalImageId(uint64_t aImageId);
   async SetLayerObserverEpoch(uint64_t layerObserverEpoch);
   async ClearCachedResources();
--- a/gfx/layers/wr/WebRenderBridgeChild.cpp
+++ b/gfx/layers/wr/WebRenderBridgeChild.cpp
@@ -56,19 +56,23 @@ WebRenderBridgeChild::AddWebRenderComman
   mCommands.AppendElements(aCommands);
 }
 
 bool
 WebRenderBridgeChild::DPBegin(const gfx::IntSize& aSize)
 {
   MOZ_ASSERT(!mDestroyed);
   MOZ_ASSERT(!mIsInTransaction);
-
+  bool success = false;
   UpdateFwdTransactionId();
-  this->SendDPBegin(aSize);
+  this->SendDPBegin(aSize, &success);
+  if (!success) {
+    return false;
+  }
+
   mIsInTransaction = true;
   return true;
 }
 
 void
 WebRenderBridgeChild::DPEnd(bool aIsSync, uint64_t aTransactionId)
 {
   MOZ_ASSERT(!mDestroyed);
--- a/gfx/layers/wr/WebRenderBridgeParent.cpp
+++ b/gfx/layers/wr/WebRenderBridgeParent.cpp
@@ -179,23 +179,26 @@ WebRenderBridgeParent::RecvDeleteImage(c
     return IPC_OK();
   }
   MOZ_ASSERT(mApi);
   mKeysToDelete.push_back(aImageKey);
   return IPC_OK();
 }
 
 mozilla::ipc::IPCResult
-WebRenderBridgeParent::RecvDPBegin(const gfx::IntSize& aSize)
+WebRenderBridgeParent::RecvDPBegin(const gfx::IntSize& aSize,
+                                   bool* aOutSuccess)
 {
   if (mDestroyed) {
     return IPC_OK();
   }
   MOZ_ASSERT(mBuilder.isSome());
   mBuilder.ref().Begin(LayerIntSize(aSize.width, aSize.height));
+  *aOutSuccess = true;
+
   return IPC_OK();
 }
 
 void
 WebRenderBridgeParent::HandleDPEnd(InfallibleTArray<WebRenderCommand>&& aCommands,
                                  InfallibleTArray<OpDestroy>&& aToDestroy,
                                  const uint64_t& aFwdTransactionId,
                                  const uint64_t& aTransactionId)
--- a/gfx/layers/wr/WebRenderBridgeParent.h
+++ b/gfx/layers/wr/WebRenderBridgeParent.h
@@ -65,17 +65,18 @@ public:
                                        const gfx::SurfaceFormat& aFormat,
                                        const ByteBuffer& aBuffer,
                                        wr::ImageKey* aOutImageKey) override;
   mozilla::ipc::IPCResult RecvUpdateImage(const wr::ImageKey& aImageKey,
                                           const gfx::IntSize& aSize,
                                           const gfx::SurfaceFormat& aFormat,
                                           const ByteBuffer& aBuffer) override;
   mozilla::ipc::IPCResult RecvDeleteImage(const wr::ImageKey& a1) override;
-  mozilla::ipc::IPCResult RecvDPBegin(const gfx::IntSize& aSize) override;
+  mozilla::ipc::IPCResult RecvDPBegin(const gfx::IntSize& aSize,
+                                      bool* aOutSuccess) override;
   mozilla::ipc::IPCResult RecvDPEnd(InfallibleTArray<WebRenderCommand>&& aCommands,
                                     InfallibleTArray<OpDestroy>&& aToDestroy,
                                     const uint64_t& aFwdTransactionId,
                                     const uint64_t& aTransactionId) override;
   mozilla::ipc::IPCResult RecvDPSyncEnd(InfallibleTArray<WebRenderCommand>&& aCommands,
                                         InfallibleTArray<OpDestroy>&& aToDestroy,
                                         const uint64_t& aFwdTransactionId,
                                         const uint64_t& aTransactionId) override;