Bug 1026404 - Disable OES_EGL_image and OES_EGL_image_external on SGX 544 MP devices. r=eflores a=ritu FIREFOX_50_0b11_BUILD1 FIREFOX_50_0b11_RELEASE
authorJamie Nicol <jnicol@mozilla.com>
Wed, 26 Oct 2016 15:28:08 +0100
changeset 431046 829a3f99f2606759305e3db204185242566a4ca6
parent 431045 30092cd6645ff14c7714da97e177f82fee34caf1
child 431047 33be6bf8174cd5da272260bcf76a3b7e060ba620
push id33986
push userfelipc@gmail.com
push dateFri, 28 Oct 2016 16:41:47 +0000
reviewerseflores, ritu
bugs1026404
milestone50.0
Bug 1026404 - Disable OES_EGL_image and OES_EGL_image_external on SGX 544 MP devices. r=eflores a=ritu EGLImageTargetTexture2D crashes on SGX 544 MP GPUs on Kit Kat with either GL_TEXTURE_2D or GL_TEXTURE_EXTERNAL as the texture target. This means that both OES_EGL_image and OES_EGL_image_external extensions do not work and must be avoided. MozReview-Commit-ID: DJmtUL6kexC
gfx/gl/GLContext.cpp
gfx/gl/GLContext.h
--- a/gfx/gl/GLContext.cpp
+++ b/gfx/gl/GLContext.cpp
@@ -819,16 +819,17 @@ GLContext::InitWithPrefixImpl(const char
         "Adreno (TM) 305",
         "Adreno (TM) 320",
         "Adreno (TM) 330",
         "Adreno (TM) 420",
         "Mali-400 MP",
         "Mali-450 MP",
         "PowerVR SGX 530",
         "PowerVR SGX 540",
+        "PowerVR SGX 544MP",
         "NVIDIA Tegra",
         "Android Emulator",
         "Gallium 0.4 on llvmpipe",
         "Intel HD Graphics 3000 OpenGL Engine",
         "Microsoft Basic Render Driver"
     };
 
     mRenderer = GLRenderer::Other;
@@ -1804,16 +1805,27 @@ GLContext::InitExtensions()
 
         if (Vendor() == GLVendor::Imagination &&
             Renderer() == GLRenderer::SGX540)
         {
             // Bug 980048
             MarkExtensionUnsupported(OES_EGL_sync);
         }
 
+#ifdef MOZ_WIDGET_ANDROID
+        if (Vendor() == GLVendor::Imagination &&
+            Renderer() == GLRenderer::SGX544MP &&
+            AndroidBridge::Bridge()->GetAPIVersion() < 21)
+        {
+            // Bug 1026404
+            MarkExtensionUnsupported(OES_EGL_image);
+            MarkExtensionUnsupported(OES_EGL_image_external);
+        }
+#endif
+
         if (Vendor() == GLVendor::ARM &&
             (Renderer() == GLRenderer::Mali400MP ||
              Renderer() == GLRenderer::Mali450MP))
         {
             // Bug 1264505
             MarkExtensionUnsupported(OES_EGL_image_external);
         }
 
--- a/gfx/gl/GLContext.h
+++ b/gfx/gl/GLContext.h
@@ -175,16 +175,17 @@ enum class GLRenderer {
     AdrenoTM305,
     AdrenoTM320,
     AdrenoTM330,
     AdrenoTM420,
     Mali400MP,
     Mali450MP,
     SGX530,
     SGX540,
+    SGX544MP,
     Tegra,
     AndroidEmulator,
     GalliumLlvmpipe,
     IntelHD3000,
     MicrosoftBasicRenderDriver,
     Other
 };