diff options
author | Rob Clark <[email protected]> | 2017-11-19 10:36:19 -0500 |
---|---|---|
committer | Rob Clark <[email protected]> | 2017-12-03 14:17:40 -0500 |
commit | 15ebf387fc43632be0e68365cf92ac8fb1b64a9c (patch) | |
tree | c38457eb447df994c138d01a155122406accda3c /src/gallium/drivers/freedreno/freedreno_query_hw.c | |
parent | deb57fb237c3be9629a39ef1978dfac4563d6bda (diff) |
freedreno: rework fence tracking
ctx->last_fence isn't such a terribly clever idea, if batches can be
flushed out of order. Instead, each batch now holds a fence, which is
created before the batch is flushed (useful for next patch), that later
gets populated after the batch is actually flushed.
Signed-off-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/gallium/drivers/freedreno/freedreno_query_hw.c')
-rw-r--r-- | src/gallium/drivers/freedreno/freedreno_query_hw.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gallium/drivers/freedreno/freedreno_query_hw.c b/src/gallium/drivers/freedreno/freedreno_query_hw.c index c92573ec936..8b25e9cbcca 100644 --- a/src/gallium/drivers/freedreno/freedreno_query_hw.c +++ b/src/gallium/drivers/freedreno/freedreno_query_hw.c @@ -211,7 +211,7 @@ fd_hw_get_query_result(struct fd_context *ctx, struct fd_query *q, * spin forever: */ if (hq->no_wait_cnt++ > 5) - fd_batch_flush(rsc->write_batch, false); + fd_batch_flush(rsc->write_batch, false, false); return false; } @@ -239,7 +239,7 @@ fd_hw_get_query_result(struct fd_context *ctx, struct fd_query *q, struct fd_resource *rsc = fd_resource(start->prsc); if (rsc->write_batch) - fd_batch_flush(rsc->write_batch, true); + fd_batch_flush(rsc->write_batch, true, false); /* some piglit tests at least do query with no draws, I guess: */ if (!rsc->bo) |