Provide record time allocator to onCombineIfPossible()

Change-Id: I3acf5d5fdb29bfbd3407a8065b7567dff43503a0
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/259427
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
diff --git a/src/gpu/GrOpsTask.h b/src/gpu/GrOpsTask.h
index 7d4e15e..d497f56 100644
--- a/src/gpu/GrOpsTask.h
+++ b/src/gpu/GrOpsTask.h
@@ -32,6 +32,7 @@
 class GrGpuBuffer;
 class GrOpMemoryPool;
 class GrRenderTargetProxy;
+class SkArenaAlloc;
 
 class GrOpsTask : public GrRenderTask {
 private:
@@ -40,7 +41,7 @@
 public:
     // The GrOpMemoryPool must outlive the GrOpsTask, either by preserving the context that owns
     // the pool, or by moving the pool to the DDL that takes over the GrOpsTask.
-    GrOpsTask(GrOpMemoryPool*, GrSurfaceProxyView, GrAuditTrail*);
+    GrOpsTask(GrOpMemoryPool*, SkArenaAlloc*, GrSurfaceProxyView, GrAuditTrail*);
     ~GrOpsTask() override;
 
     GrOpsTask* asOpsTask() override { return this; }
@@ -199,14 +200,14 @@
         // Attempts to move the ops from the passed chain to this chain at the head. Also attempts
         // to merge ops between the chains. Upon success the passed chain is empty.
         // Fails when the chains aren't of the same op type, have different clips or dst proxies.
-        bool prependChain(OpChain*, const GrCaps&, GrOpMemoryPool*, GrAuditTrail*);
+        bool prependChain(OpChain*, const GrCaps&, GrOpMemoryPool*, SkArenaAlloc*, GrAuditTrail*);
 
         // Attempts to add 'op' to this chain either by merging or adding to the tail. Returns
         // 'op' to the caller upon failure, otherwise null. Fails when the op and chain aren't of
         // the same op type, have different clips or dst proxies.
         std::unique_ptr<GrOp> appendOp(std::unique_ptr<GrOp> op, GrProcessorSet::Analysis,
                                        const DstProxyView*, const GrAppliedClip*, const GrCaps&,
-                                       GrOpMemoryPool*, GrAuditTrail*);
+                                       GrOpMemoryPool*, SkArenaAlloc*, GrAuditTrail*);
 
         void setSkipExecuteFlag() { fSkipExecute = true; }
         bool shouldExecute() const {
@@ -240,8 +241,10 @@
         void validate() const;
 
         bool tryConcat(List*, GrProcessorSet::Analysis, const DstProxyView&, const GrAppliedClip*,
-                       const SkRect& bounds, const GrCaps&, GrOpMemoryPool*, GrAuditTrail*);
-        static List DoConcat(List, List, const GrCaps&, GrOpMemoryPool*, GrAuditTrail*);
+                       const SkRect& bounds, const GrCaps&, GrOpMemoryPool*, SkArenaAlloc*,
+                       GrAuditTrail*);
+        static List DoConcat(List, List, const GrCaps&, GrOpMemoryPool*, SkArenaAlloc*,
+                             GrAuditTrail*);
 
         List fList;
         GrProcessorSet::Analysis fProcessorAnalysis;
@@ -280,6 +283,7 @@
     // In the DDL case, the GrOpMemoryPool must have been detached from the original recording
     // context and moved into the owning DDL.
     GrOpMemoryPool* fOpMemoryPool;
+    SkArenaAlloc*   fRecordTimeAllocator;
     GrAuditTrail*   fAuditTrail;
 
     GrLoadOp fColorLoadOp = GrLoadOp::kLoad;