Bug 1458121 - Don't try to layerize when we have a clip-path mask as well as rounded rect clipping. r=mstange
authorMatt Woodrow <mwoodrow@mozilla.com>
Thu, 21 Jun 2018 12:43:22 +1200
changeset 425485 78e841de1a73cc8a234810e791475d95b2956d48
parent 425484 ffb7b5015fc331bdc4c5e6ab52b9de669faa8864
child 425486 dfc8ad9b2244b8112340e44368a8e43b523c82e6
push id66078
push usermwoodrow@mozilla.com
push dateSun, 08 Jul 2018 22:40:17 +0000
treeherderautoland@78e841de1a73 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmstange
bugs1458121
milestone63.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
Bug 1458121 - Don't try to layerize when we have a clip-path mask as well as rounded rect clipping. r=mstange MozReview-Commit-ID: GhOay2a6z9t
layout/base/crashtests/1458121.html
layout/base/crashtests/crashtests.list
layout/painting/nsDisplayList.cpp
new file mode 100644
--- /dev/null
+++ b/layout/base/crashtests/1458121.html
@@ -0,0 +1,23 @@
+<script>
+window.requestIdleCallback(function(){
+  document.documentElement.style.display="none";
+  document.documentElement.getBoundingClientRect();
+  document.documentElement.style.display="";
+});
+</script>
+<style>
+body {
+  -webkit-border-radius: 16px;
+  overflow-x: hidden;
+  -webkit-filter: blur(0px);
+  width: 1em;
+}
+:root {
+  scroll-snap-destination: left top 36%;
+}
+#a {
+  overflow: scroll;
+  clip-path: url(#x);
+}
+</style>
+<dl id="a">|<dialog open>
--- a/layout/base/crashtests/crashtests.list
+++ b/layout/base/crashtests/crashtests.list
@@ -533,16 +533,17 @@ load 1437155.html
 pref(dom.webcomponents.shadowdom.enabled,true) load 1439016.html
 load 1442506.html
 load 1443027-1.html
 load 1448841-1.html
 load 1452839.html
 load 1453196.html
 load 1453342.html
 load 1453702.html
+load 1458121.html
 pref(dom.webcomponents.shadowdom.enabled,true) load 1461749.html
 load 1461812.html
 load 1462412.html
 load 1463940.html
 pref(dom.webcomponents.shadowdom.enabled,true) HTTP load 1464641.html
 load 1464737.html
 load 1467688.html
 load 1467964.html
--- a/layout/painting/nsDisplayList.cpp
+++ b/layout/painting/nsDisplayList.cpp
@@ -9245,16 +9245,22 @@ bool nsDisplayMask::CanPaintOnMaskLayer(
   if (!nsSVGIntegrationUtils::IsMaskResourceReady(mFrame)) {
     return false;
   }
 
   if (gfxPrefs::DrawMaskLayer()) {
     return false;
   }
 
+  // We don't currently support this item creating a mask
+  // for both the clip-path, and rounded rect clipping.
+  if (GetClip().GetRoundedRectCount() != 0) {
+    return false;
+  }
+
   return true;
 }
 
 bool nsDisplayMask::ComputeVisibility(nsDisplayListBuilder* aBuilder,
                                       nsRegion* aVisibleRegion)
 {
   // Our children may be made translucent or arbitrarily deformed so we should
   // not allow them to subtract area from aVisibleRegion.