Bug 1022080 - Split out the paint item dumping from the rest of the paint dumping. r=mattwoodrow
authorKartikaya Gupta <kgupta@mozilla.com>
Tue, 12 May 2015 09:16:54 -0400
changeset 243542 12e87a6861d743ba8992c3347ac2d368b064bc7f
parent 243541 e6051c09670d2954a55a9c2af3c9b7689c07fdf6
child 243543 678c2a90dd64a20766153fcedbc2648fc2a27c13
push id28741
push userkwierso@gmail.com
push dateTue, 12 May 2015 23:24:40 +0000
treeherdermozilla-central@d476776d920d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmattwoodrow
bugs1022080
milestone40.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 1022080 - Split out the paint item dumping from the rest of the paint dumping. r=mattwoodrow
gfx/thebes/gfxUtils.cpp
gfx/thebes/gfxUtils.h
layout/base/FrameLayerBuilder.cpp
--- a/gfx/thebes/gfxUtils.cpp
+++ b/gfx/thebes/gfxUtils.cpp
@@ -1449,20 +1449,22 @@ gfxUtils::DumpDisplayList() {
 }
 
 FILE *gfxUtils::sDumpPaintFile = stderr;
 
 #ifdef MOZ_DUMP_PAINTING
 bool gfxUtils::sDumpPainting = getenv("MOZ_DUMP_PAINT") != 0;
 bool gfxUtils::sDumpPaintingIntermediate = getenv("MOZ_DUMP_PAINT_INTERMEDIATE") != 0;
 bool gfxUtils::sDumpPaintingToFile = getenv("MOZ_DUMP_PAINT_TO_FILE") != 0;
+bool gfxUtils::sDumpPaintItems = getenv("MOZ_DUMP_PAINT_ITEMS") != 0;
 #else
 bool gfxUtils::sDumpPainting = false;
 bool gfxUtils::sDumpPaintingIntermediate = false;
 bool gfxUtils::sDumpPaintingToFile = false;
+bool gfxUtils::sDumpPaintItems = false;
 #endif
 
 namespace mozilla {
 namespace gfx {
 
 Color ToDeviceColor(Color aColor)
 {
   // aColor is pass-by-value since to get return value optimization goodness we
--- a/gfx/thebes/gfxUtils.h
+++ b/gfx/thebes/gfxUtils.h
@@ -290,16 +290,17 @@ public:
     static void CopyAsDataURI(SourceSurface* aSourceSurface);
     static void CopyAsDataURI(DrawTarget* aDT);
 
     static bool DumpDisplayList();
 
     static bool sDumpPainting;
     static bool sDumpPaintingIntermediate;
     static bool sDumpPaintingToFile;
+    static bool sDumpPaintItems;
     static FILE* sDumpPaintFile;
 };
 
 namespace mozilla {
 namespace gfx {
 
 /**
  * If the CMS mode is eCMSMode_All, these functions transform the passed
--- a/layout/base/FrameLayerBuilder.cpp
+++ b/layout/base/FrameLayerBuilder.cpp
@@ -5054,17 +5054,17 @@ FrameLayerBuilder::PaintItems(nsTArray<C
     if (cdi->mInactiveLayerManager) {
       bool saved = aDrawTarget.GetPermitSubpixelAA();
       PaintInactiveLayer(aBuilder, cdi->mInactiveLayerManager, cdi->mItem, aContext, aRC);
       aDrawTarget.SetPermitSubpixelAA(saved);
     } else {
       nsIFrame* frame = cdi->mItem->Frame();
       frame->AddStateBits(NS_FRAME_PAINTED_THEBES);
 #ifdef MOZ_DUMP_PAINTING
-      if (gfxUtils::sDumpPainting) {
+      if (gfxUtils::sDumpPaintItems) {
         DebugPaintItem(aDrawTarget, aPresContext, cdi->mItem, aBuilder);
       } else {
 #else
       {
 #endif
         cdi->mItem->Paint(aBuilder, aRC);
       }
     }