summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/radeonsi/si_perfcounter.c
diff options
context:
space:
mode:
authorNicolai Hähnle <[email protected]>2018-09-18 15:52:17 +0200
committerNicolai Hähnle <[email protected]>2018-12-19 12:02:01 +0100
commite0f0d3675d462aad4ca30e4383a3530d46e6e85d (patch)
tree36a04d25d4b4c93c5bc355d383eb446ef2c52a12 /src/gallium/drivers/radeonsi/si_perfcounter.c
parent0fc6e573dddbaaeac517bb8b03c1484a50943cd9 (diff)
radeonsi: factor si_query_buffer logic out of si_query_hw
This is a move towards using composition instead of inheritance for different query types. This change weakens out-of-memory error reporting somewhat, though this should be acceptable since we didn't consistently report such errors in the first place. Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium/drivers/radeonsi/si_perfcounter.c')
-rw-r--r--src/gallium/drivers/radeonsi/si_perfcounter.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/gallium/drivers/radeonsi/si_perfcounter.c b/src/gallium/drivers/radeonsi/si_perfcounter.c
index 0b3d8f89273..f0d10c054c4 100644
--- a/src/gallium/drivers/radeonsi/si_perfcounter.c
+++ b/src/gallium/drivers/radeonsi/si_perfcounter.c
@@ -768,9 +768,8 @@ static void si_pc_query_destroy(struct si_screen *sscreen,
si_query_hw_destroy(sscreen, rquery);
}
-static bool si_pc_query_prepare_buffer(struct si_screen *screen,
- struct si_query_hw *hwquery,
- struct r600_resource *buffer)
+static bool si_pc_query_prepare_buffer(struct si_context *ctx,
+ struct si_query_buffer *qbuf)
{
/* no-op */
return true;
@@ -1062,9 +1061,6 @@ struct pipe_query *si_create_batch_query(struct pipe_context *ctx,
counter->qwords *= block->num_instances;
}
- if (!si_query_hw_init(screen, &query->b))
- goto error;
-
return (struct pipe_query *)query;
error: