summaryrefslogtreecommitdiff
path: root/lib/mesa/src/gallium/drivers/etnaviv/etnaviv_query_acc_perfmon.c
diff options
context:
space:
mode:
authorJonathan Gray <jsg@cvs.openbsd.org>2022-09-02 05:47:02 +0000
committerJonathan Gray <jsg@cvs.openbsd.org>2022-09-02 05:47:02 +0000
commit0dbbf1e0708df85a357d70e2708c0a11aeb5480e (patch)
tree6656ff8eb8b15a2fc1c02888973caf618388cfd0 /lib/mesa/src/gallium/drivers/etnaviv/etnaviv_query_acc_perfmon.c
parent5f66494d31f735486b8222ecfa0a0c9046e92543 (diff)
Merge Mesa 22.1.7
Diffstat (limited to 'lib/mesa/src/gallium/drivers/etnaviv/etnaviv_query_acc_perfmon.c')
-rw-r--r--lib/mesa/src/gallium/drivers/etnaviv/etnaviv_query_acc_perfmon.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/mesa/src/gallium/drivers/etnaviv/etnaviv_query_acc_perfmon.c b/lib/mesa/src/gallium/drivers/etnaviv/etnaviv_query_acc_perfmon.c
index 7c49fc88f..72fa77769 100644
--- a/lib/mesa/src/gallium/drivers/etnaviv/etnaviv_query_acc_perfmon.c
+++ b/lib/mesa/src/gallium/drivers/etnaviv/etnaviv_query_acc_perfmon.c
@@ -39,6 +39,7 @@ struct etna_pm_query
struct etna_perfmon_signal *signal;
unsigned sequence;
+ bool multiply_with_8;
};
static inline struct etna_pm_query *
@@ -116,6 +117,7 @@ perfmon_allocate(struct etna_context *ctx, unsigned query_type)
return NULL;
pm_add_signal(pq, ctx->screen->perfmon, cfg);
+ pq->multiply_with_8 = cfg->multiply_with_8;
return &pq->base;
}
@@ -155,6 +157,9 @@ perfmon_result(struct etna_acc_query *aq, void *buf,
result->u32 = sum;
+ if (pq->multiply_with_8)
+ result->u32 *= 8;
+
return true;
}