Backed out changeset d98c1bfa1caf (bug 1305326) for windows reftest failures a=backout
authorWes Kocher <wkocher@mozilla.com>
Thu, 29 Sep 2016 18:10:08 -0700
changeset 315943 0f3851b3e17eafa449ecdb84524d2880c232c2b5
parent 315942 8468a31dcb9441bbdd8a1f4f27a982409c677f0a
child 315944 36dbc4e296bf3adaaefe0807b2161673463ac676
push id20634
push usercbook@mozilla.com
push dateFri, 30 Sep 2016 10:10:13 +0000
treeherderfx-team@afe79b010d13 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbackout
bugs1305326
milestone52.0a1
backs outd98c1bfa1caf05ce2edc741b34b38e818434353c
Backed out changeset d98c1bfa1caf (bug 1305326) for windows reftest failures a=backout
gfx/ipc/GraphicsMessages.ipdlh
gfx/layers/IMFYCbCrImage.cpp
gfx/thebes/DeviceManagerDx.cpp
gfx/thebes/DeviceManagerDx.h
--- a/gfx/ipc/GraphicsMessages.ipdlh
+++ b/gfx/ipc/GraphicsMessages.ipdlh
@@ -14,17 +14,16 @@ using gfxImageFormat from "mozilla/gfx/T
 
 namespace mozilla {
 namespace gfx {
 
 struct D3D11DeviceStatus
 {
   bool isWARP;
   bool textureSharingWorks;
-  bool alphaTextureSharingWorks;
   uint32_t featureLevel;
   DxgiAdapterDesc adapter;
 };
 
 struct DevicePrefs
 {
   FeatureStatus hwCompositing;
   FeatureStatus d3d11Compositing;
--- a/gfx/layers/IMFYCbCrImage.cpp
+++ b/gfx/layers/IMFYCbCrImage.cpp
@@ -232,18 +232,17 @@ IMFYCbCrImage::GetTextureClient(KnowsCom
   if (!device || backend != LayersBackend::LAYERS_D3D11) {
     if (backend == LayersBackend::LAYERS_D3D9 ||
         backend == LayersBackend::LAYERS_D3D11) {
       return GetD3D9TextureClient(aForwarder);
     }
     return nullptr;
   }
 
-  if (!gfx::DeviceManagerDx::Get()->CanInitializeKeyedMutexTextures() ||
-      !gfx::DeviceManagerDx::Get()->AlphaTextureSharingWorks()) {
+  if (!gfx::DeviceManagerDx::Get()->CanInitializeKeyedMutexTextures()) {
     return nullptr;
   }
 
   if (mData.mYStride < 0 || mData.mCbCrStride < 0) {
     // D3D11 only supports unsigned stride values.
     return nullptr;
   }
 
--- a/gfx/thebes/DeviceManagerDx.cpp
+++ b/gfx/thebes/DeviceManagerDx.cpp
@@ -323,17 +323,16 @@ DeviceManagerDx::CreateCompositorDevice(
     }
   } else {
     mCompositorDeviceSupportsVideo = true;
   }
 
   // Only test this when not using WARP since it can fail and cause
   // GetDeviceRemovedReason to return weird values.
   bool textureSharingWorks = D3D11Checks::DoesTextureSharingWork(device);
-  bool alphaTextureSharingWorks = D3D11Checks::DoesAlphaTextureSharingWork(device);
 
   DXGI_ADAPTER_DESC desc;
   PodZero(&desc);
   adapter->GetDesc(&desc);
 
   if (!textureSharingWorks) {
     gfxConfig::SetFailed(Feature::D3D11_HW_ANGLE,
                          FeatureStatus::Broken,
@@ -351,17 +350,16 @@ DeviceManagerDx::CreateCompositorDevice(
 
   int featureLevel = device->GetFeatureLevel();
   {
     MutexAutoLock lock(mDeviceLock);
     mCompositorDevice = device;
     mDeviceStatus = Some(D3D11DeviceStatus(
       false,
       textureSharingWorks,
-      alphaTextureSharingWorks,
       featureLevel,
       DxgiAdapterDesc::From(desc)));
   }
   mCompositorDevice->SetExceptionMode(0);
 }
 
 bool
 DeviceManagerDx::CreateDevice(IDXGIAdapter* aAdapter,
@@ -406,33 +404,30 @@ DeviceManagerDx::CreateWARPCompositorDev
     d3d11.SetFailed(FeatureStatus::Failed, "Failed to create a D3D11 WARP device",
                     NS_LITERAL_CSTRING("FEATURE_FAILURE_D3D11_WARP_DEVICE2"));
     return;
   }
 
   // Only test for texture sharing on Windows 8 since it puts the device into
   // an unusable state if used on Windows 7
   bool textureSharingWorks = false;
-  bool alphaTextureSharingWorks = false;
   if (IsWin8OrLater()) {
     textureSharingWorks = D3D11Checks::DoesTextureSharingWork(device);
-    alphaTextureSharingWorks = D3D11Checks::DoesAlphaTextureSharingWork(device);
   }
 
   DxgiAdapterDesc nullAdapter;
   PodZero(&nullAdapter);
 
   int featureLevel = device->GetFeatureLevel();
   {
     MutexAutoLock lock(mDeviceLock);
     mCompositorDevice = device;
     mDeviceStatus = Some(D3D11DeviceStatus(
       true,
       textureSharingWorks,
-      alphaTextureSharingWorks,
       featureLevel,
       nullAdapter));
   }
   mCompositorDevice->SetExceptionMode(0);
 
   reporterWARP.SetSuccessful();
 }
 
@@ -671,26 +666,16 @@ DeviceManagerDx::TextureSharingWorks()
   MutexAutoLock lock(mDeviceLock);
   if (!mDeviceStatus) {
     return false;
   }
   return mDeviceStatus->textureSharingWorks();
 }
 
 bool
-DeviceManagerDx::AlphaTextureSharingWorks()
-{
-  MutexAutoLock lock(mDeviceLock);
-  if (!mDeviceStatus) {
-    return false;
-  }
-  return mDeviceStatus->alphaTextureSharingWorks();
-}
-
-bool
 DeviceManagerDx::CanInitializeKeyedMutexTextures()
 {
   MutexAutoLock lock(mDeviceLock);
   if (!mDeviceStatus) {
     return false;
   }
   // Disable this on all Intel devices because of crashes.
   // See bug 1292923.
--- a/gfx/thebes/DeviceManagerDx.h
+++ b/gfx/thebes/DeviceManagerDx.h
@@ -53,17 +53,16 @@ public:
 
   RefPtr<ID3D11Device> GetCompositorDevice();
   RefPtr<ID3D11Device> GetContentDevice();
   RefPtr<ID3D11Device> CreateDecoderDevice();
   IDirectDraw7* GetDirectDraw();
 
   unsigned GetCompositorFeatureLevel() const;
   bool TextureSharingWorks();
-  bool AlphaTextureSharingWorks();
   bool IsWARP();
 
   // Returns true if we can create a texture with
   // D3D11_RESOURCE_MISC_SHARED_KEYEDMUTEX and also
   // upload texture data during the CreateTexture2D
   // call. This crashes on some devices, so we might
   // need to avoid it.
   bool CanInitializeKeyedMutexTextures();