intel/perf: link queries back to the gen_perf_config object
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Marcin Ślusarz <marcin.slusarz@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8525>
This commit is contained in:
parent
e79f112e4f
commit
b7032d6776
|
@ -201,6 +201,8 @@ struct gen_perf_registers {
|
|||
};
|
||||
|
||||
struct gen_perf_query_info {
|
||||
struct gen_perf_config *perf;
|
||||
|
||||
enum gen_perf_query_type {
|
||||
GEN_PERF_QUERY_TYPE_OA,
|
||||
GEN_PERF_QUERY_TYPE_RAW,
|
||||
|
|
|
@ -681,6 +681,7 @@ def main():
|
|||
|
||||
c("struct gen_perf_query_info *query = rzalloc(perf, struct gen_perf_query_info);\n")
|
||||
c("\n")
|
||||
c("query->perf = perf;\n")
|
||||
c("query->kind = GEN_PERF_QUERY_TYPE_OA;\n")
|
||||
c("query->name = \"" + set.name + "\";\n")
|
||||
c("query->symbol_name = \"" + set.symbol_name + "\";\n")
|
||||
|
|
|
@ -76,6 +76,8 @@ gen_perf_append_query_info(struct gen_perf_config *perf, int max_counters)
|
|||
query = &perf->queries[perf->n_queries - 1];
|
||||
memset(query, 0, sizeof(*query));
|
||||
|
||||
query->perf = perf;
|
||||
|
||||
if (max_counters > 0) {
|
||||
query->max_counters = max_counters;
|
||||
query->counters =
|
||||
|
|
Loading…
Reference in New Issue