Add debug-only helper methods to get #ops & #clips per opList

These are being/will be used to determine the correct amout of memory to preallocate for ops & clips in the opLists.

Change-Id: I98ebaec8a6e72a43d97101aca5fbc58264964ebd
Reviewed-on: https://skia-review.googlesource.com/15882
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
diff --git a/src/gpu/GrRenderTargetOpList.h b/src/gpu/GrRenderTargetOpList.h
index 342f927..21dd70e 100644
--- a/src/gpu/GrRenderTargetOpList.h
+++ b/src/gpu/GrRenderTargetOpList.h
@@ -106,6 +106,9 @@
 
     SkDEBUGCODE(void validateTargetsSingleRenderTarget() const override;)
 
+    SkDEBUGCODE(int numOps() const override { return fRecordedOps.count(); })
+    SkDEBUGCODE(int numClips() const override { return fNumClips; })
+
 private:
     friend class GrRenderTargetContextPriv; // for stencil clip state. TODO: this is invasive
 
@@ -153,6 +156,7 @@
     // MDB TODO: 4096 for the first allocation of the clip space will be huge overkill.
     // Gather statistics to determine the correct size.
     SkArenaAlloc fClipAllocator{4096};
+    SkDEBUGCODE(int          fNumClips;)
 
     typedef GrOpList INHERITED;
 };