diff options
author | Rob Clark <[email protected]> | 2018-09-11 16:21:29 -0400 |
---|---|---|
committer | Rob Clark <[email protected]> | 2018-09-27 15:41:46 -0400 |
commit | 919741b8d5357b2a061a48f7142c1e24be8656d4 (patch) | |
tree | ba4d6279898c864973c8f37b08a9a00346a0243c /src/gallium/drivers/freedreno/a3xx | |
parent | 19e9d286464d1941f731f0d84402725f918623d6 (diff) |
freedreno: handle invalidated buffers harder
Do a better job of skipping mem2gmem/gmem2mem..
Signed-off-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/gallium/drivers/freedreno/a3xx')
-rw-r--r-- | src/gallium/drivers/freedreno/a3xx/fd3_gmem.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gallium/drivers/freedreno/a3xx/fd3_gmem.c b/src/gallium/drivers/freedreno/a3xx/fd3_gmem.c index 3b299b81755..3874615015c 100644 --- a/src/gallium/drivers/freedreno/a3xx/fd3_gmem.c +++ b/src/gallium/drivers/freedreno/a3xx/fd3_gmem.c @@ -322,10 +322,15 @@ emit_gmem2mem_surf(struct fd_batch *batch, struct fd_ringbuffer *ring = batch->gmem; struct fd_resource *rsc = fd_resource(psurf->texture); enum pipe_format format = psurf->format; + + if (!rsc->valid) + return; + if (stencil) { rsc = rsc->stencil; format = rsc->base.format; } + struct fd_resource_slice *slice = fd_resource_slice(rsc, psurf->u.tex.level); uint32_t offset = fd_resource_offset(rsc, psurf->u.tex.level, psurf->u.tex.first_layer); |