intel/perf: create a vtable for low-level driver functions
authorMark Janes <mark.a.janes@intel.com>
Tue, 2 Jul 2019 21:21:57 +0000 (14:21 -0700)
committerMark Janes <mark.a.janes@intel.com>
Thu, 8 Aug 2019 04:33:55 +0000 (21:33 -0700)
commit439d5a3eff188b4e0be42fd6da3a4d233fffcbf3
treece7860263b99a1e80828c6a47c001dadec48aafd
parentea66484e8604edf75df9f95c9e94b73f1e80639d
intel/perf: create a vtable for low-level driver functions

Performance metrics collections requires several actions (eg bo_map())
that have different implementations for Iris and i965.  The perf
subsystem needs a vtable for each of these actions, so it can invoke
the corresponding implementation for each driver.

The first call to be added to the table is bo_alloc.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/intel/perf/gen_perf.h
src/mesa/drivers/dri/i965/brw_performance_query.c