Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(341)

Unified Diff: include/private/GrAuditTrail.h

Issue 1765123002: Fix up GrAuditTrail to allow arbitrary reordering (Closed) Base URL: https://skia.googlesource.com/skia@master
Patch Set: fix up audit trail Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/gpu/GrAuditTrail.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/private/GrAuditTrail.h
diff --git a/include/private/GrAuditTrail.h b/include/private/GrAuditTrail.h
index 4d2d99aa9a2550296dc9261b54f1ab718c63414b..3bb7bea43503fc968f153ea7911e57bd871045bf 100644
--- a/include/private/GrAuditTrail.h
+++ b/include/private/GrAuditTrail.h
@@ -84,11 +84,9 @@ public:
fCurrentStackTrace.push_back(SkString(framename));
}
- void addBatch(const char* name, const SkRect& bounds);
+ void addBatch(const GrBatch* batch);
- void batchingResultCombined(GrBatch* combiner);
-
- void batchingResultNew(GrBatch* batch);
+ void batchingResultCombined(const GrBatch* consumer, const GrBatch* consumed);
// Because batching is heavily dependent on sequence of draw calls, these calls will only
// produce valid information for the given draw sequence which preceeded them.
@@ -153,10 +151,9 @@ private:
template <typename T>
static void JsonifyTArray(SkString* json, const char* name, const T& array,
bool addComma);
-
- Batch* fCurrentBatch;
+
BatchPool fBatchPool;
- SkTHashMap<GrBatch*, int> fIDLookup;
+ SkTHashMap<uint32_t, int> fIDLookup;
SkTHashMap<int, Batches*> fClientIDLookup;
BatchList fBatchList;
SkTArray<SkString> fCurrentStackTrace;
@@ -177,13 +174,13 @@ private:
#define GR_AUDIT_TRAIL_RESET(audit_trail) \
//GR_AUDIT_TRAIL_INVOKE_GUARD(audit_trail, fullReset);
-#define GR_AUDIT_TRAIL_ADDBATCH(audit_trail, batchname, bounds) \
- GR_AUDIT_TRAIL_INVOKE_GUARD(audit_trail, addBatch, batchname, bounds);
+#define GR_AUDIT_TRAIL_ADDBATCH(audit_trail, batch) \
+ GR_AUDIT_TRAIL_INVOKE_GUARD(audit_trail, addBatch, batch);
-#define GR_AUDIT_TRAIL_BATCHING_RESULT_COMBINED(audit_trail, combiner) \
- GR_AUDIT_TRAIL_INVOKE_GUARD(audit_trail, batchingResultCombined, combiner);
+#define GR_AUDIT_TRAIL_BATCHING_RESULT_COMBINED(audit_trail, combineWith, batch) \
+ GR_AUDIT_TRAIL_INVOKE_GUARD(audit_trail, batchingResultCombined, combineWith, batch);
#define GR_AUDIT_TRAIL_BATCHING_RESULT_NEW(audit_trail, batch) \
- GR_AUDIT_TRAIL_INVOKE_GUARD(audit_trail, batchingResultNew, batch);
+ // Doesn't do anything now, one day...
#endif
« no previous file with comments | « no previous file | src/gpu/GrAuditTrail.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698