Revert "Implement alternate method for determining recycle-ability of allocated GrSurfaces"
This reverts commit 7eec3cd688b27944dcf1210e333c155ba24b2bde.
Reason for revert: Chrome assert
Original change's description:
> Implement alternate method for determining recycle-ability of allocated GrSurfaces
>
> With the upcoming removal of pendingIO refs the GrResourceAllocator needs a new means of determining when a backing GrSurface can be recycled and when it needs to be left assigned to a GrSurfaceProxy.
>
> Change-Id: I6f62a793e8aba70019dc8d0e7d585366d1097d70
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/208227
> Reviewed-by: Brian Salomon <bsalomon@google.com>
> Commit-Queue: Robert Phillips <robertphillips@google.com>
TBR=bsalomon@google.com,robertphillips@google.com
Change-Id: Ia7098e1fcbf5623a7846b52b3b26f724e183d5ff
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/209807
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
diff --git a/src/gpu/GrRenderTargetOpList.cpp b/src/gpu/GrRenderTargetOpList.cpp
index f586293..e652902 100644
--- a/src/gpu/GrRenderTargetOpList.cpp
+++ b/src/gpu/GrRenderTargetOpList.cpp
@@ -633,27 +633,24 @@
// they can be recycled. This is a bit unfortunate because a flush can proceed in waves
// with sub-flushes. The deferred proxies only need to be pinned from the start of
// the sub-flush in which they appear.
- alloc->addInterval(fDeferredProxies[i], 0, 0, GrResourceAllocator::ActualUse::kNo);
+ alloc->addInterval(fDeferredProxies[i], 0, 0);
}
// Add the interval for all the writes to this opList's target
if (fOpChains.count()) {
unsigned int cur = alloc->curOp();
- alloc->addInterval(fTarget.get(), cur, cur + fOpChains.count() - 1,
- GrResourceAllocator::ActualUse::kYes);
+ alloc->addInterval(fTarget.get(), cur, cur + fOpChains.count() - 1);
} else {
// This can happen if there is a loadOp (e.g., a clear) but no other draws. In this case we
// still need to add an interval for the destination so we create a fake op# for
// the missing clear op.
- alloc->addInterval(fTarget.get(), alloc->curOp(), alloc->curOp(),
- GrResourceAllocator::ActualUse::kYes);
+ alloc->addInterval(fTarget.get(), alloc->curOp(), alloc->curOp());
alloc->incOps();
}
auto gather = [ alloc SkDEBUGCODE(, this) ] (GrSurfaceProxy* p) {
- alloc->addInterval(p, alloc->curOp(), alloc->curOp(), GrResourceAllocator::ActualUse::kYes
- SkDEBUGCODE(, fTarget.get() == p));
+ alloc->addInterval(p, alloc->curOp(), alloc->curOp() SkDEBUGCODE(, fTarget.get() == p));
};
for (const OpChain& recordedOp : fOpChains) {
// only diff from the GrTextureOpList version