diff options
author | Christian Gmeiner <[email protected]> | 2018-03-05 23:26:42 +0100 |
---|---|---|
committer | Christian Gmeiner <[email protected]> | 2018-03-08 20:43:55 +0100 |
commit | 3d912bd742edc2f66758b25b36371e581fd62d45 (patch) | |
tree | 5ec2e78892fa900d58bbd26fb00775736dd3f76e /src/gallium/drivers/etnaviv/etnaviv_query_sw.c | |
parent | 1e9d779331544f8f039978c36430bef1c4efdb2d (diff) |
etnaviv: add query_group_info for sw counters
Signed-off-by: Christian Gmeiner <[email protected]>
Reviewed-by: Lucas Stach <[email protected]>
Diffstat (limited to 'src/gallium/drivers/etnaviv/etnaviv_query_sw.c')
-rw-r--r-- | src/gallium/drivers/etnaviv/etnaviv_query_sw.c | 30 |
1 files changed, 24 insertions, 6 deletions
diff --git a/src/gallium/drivers/etnaviv/etnaviv_query_sw.c b/src/gallium/drivers/etnaviv/etnaviv_query_sw.c index 2e65065b285..f955d8e2106 100644 --- a/src/gallium/drivers/etnaviv/etnaviv_query_sw.c +++ b/src/gallium/drivers/etnaviv/etnaviv_query_sw.c @@ -118,16 +118,16 @@ etna_sw_create_query(struct etna_context *ctx, unsigned query_type) return q; } +static const struct pipe_driver_query_info list[] = { + {"prims-emitted", PIPE_QUERY_PRIMITIVES_EMITTED, { 0 }}, + {"draw-calls", ETNA_QUERY_DRAW_CALLS, { 0 }}, + {"rs-operations", ETNA_QUERY_RS_OPERATIONS, { 0 }}, +}; + int etna_sw_get_driver_query_info(struct pipe_screen *pscreen, unsigned index, struct pipe_driver_query_info *info) { - static const struct pipe_driver_query_info list[] = { - {"prims-emitted", PIPE_QUERY_PRIMITIVES_EMITTED, { 0 }}, - {"draw-calls", ETNA_QUERY_DRAW_CALLS, { 0 }}, - {"rs-operations", ETNA_QUERY_RS_OPERATIONS, { 0 }}, - }; - if (!info) return ARRAY_SIZE(list); @@ -138,3 +138,21 @@ etna_sw_get_driver_query_info(struct pipe_screen *pscreen, unsigned index, return 1; } + +int +etna_sw_get_driver_query_group_info(struct pipe_screen *pscreen, + unsigned index, + struct pipe_driver_query_group_info *info) +{ + if (!info) + return ARRAY_SIZE(list); + + if (index != 0) + return 0; + + info->name = "driver"; + info->max_active_queries = ARRAY_SIZE(list); + info->num_queries = ARRAY_SIZE(list); + + return 1; +} |