summaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2018-12-14 21:09:32 -0800
committerKenneth Graunke <[email protected]>2019-01-15 11:43:04 -0800
commite760be08b45dd2d56058d7afc9048b99241fd1de (patch)
tree3f7e25575d2b4d80977972b61811e3f4e924b08a /src/gallium
parent4a131a13303773d8b0e4d47e917b9c52d439146a (diff)
st/mesa: Make an enum for pipeline statistics query result indices.
Gallium handles pipeline statistics queries as a single query (PIPE_QUERY_PIPELINE_STATISTICS) which returns a struct with 11 values. Sometimes it's useful to refer to each of those values individually, rather than as a group. To avoid hardcoding numbers, we define a new enum for each value. Here, the name and enum value correspond to the index in the struct pipe_query_data_pipeline_statistics result. Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Tapani Pälli <[email protected]>
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/include/pipe/p_defines.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/gallium/include/pipe/p_defines.h b/src/gallium/include/pipe/p_defines.h
index 82c49c801e5..4480b54eb2f 100644
--- a/src/gallium/include/pipe/p_defines.h
+++ b/src/gallium/include/pipe/p_defines.h
@@ -569,6 +569,23 @@ enum pipe_query_type {
};
/**
+ * Index for PIPE_QUERY_PIPELINE_STATISTICS subqueries.
+ */
+enum pipe_statistics_query_index {
+ PIPE_STAT_QUERY_IA_VERTICES,
+ PIPE_STAT_QUERY_IA_PRIMITIVES,
+ PIPE_STAT_QUERY_VS_INVOCATIONS,
+ PIPE_STAT_QUERY_GS_INVOCATIONS,
+ PIPE_STAT_QUERY_GS_PRIMITIVES,
+ PIPE_STAT_QUERY_C_INVOCATIONS,
+ PIPE_STAT_QUERY_C_PRIMITIVES,
+ PIPE_STAT_QUERY_PS_INVOCATIONS,
+ PIPE_STAT_QUERY_HS_INVOCATIONS,
+ PIPE_STAT_QUERY_DS_INVOCATIONS,
+ PIPE_STAT_QUERY_CS_INVOCATIONS,
+};
+
+/**
* Conditional rendering modes
*/
enum pipe_render_cond_flag {