panfrost: Make sure a clear does not re-use a pre-existing batch
authorBoris Brezillon <boris.brezillon@collabora.com>
Thu, 19 Sep 2019 13:52:02 +0000 (15:52 +0200)
committerBoris Brezillon <boris.brezillon@collabora.com>
Tue, 8 Oct 2019 08:07:54 +0000 (10:07 +0200)
commitc138ca80d2390ce0d0fe640bc74aab2d2d0cb80d
tree66f196d239cdeb54e2342e46b5f4ed301570a42b
parent016c19bc895ffaa85954aa864a9de969261f9922
panfrost: Make sure a clear does not re-use a pre-existing batch

glClear()s are expected to be the first thing GL apps do before drawing
new things. If there's already an existing batch targetting the same
FBO that has draws attached to it, we should make sure the new clear
gets a new batch assigned to guaranteed that the FB content is actually
cleared with the requested color/depth/stencil values.

We create a panfrost_get_fresh_batch_for_fbo() helper for that and
call it from panfrost_clear().

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
.gitlab-ci/deqp-panfrost-t760-fails.txt
.gitlab-ci/deqp-panfrost-t860-fails.txt
src/gallium/drivers/panfrost/pan_context.c
src/gallium/drivers/panfrost/pan_job.c
src/gallium/drivers/panfrost/pan_job.h