diff options
author | Kan Liang <kan.liang@linux.intel.com> | 2020-07-03 05:49:12 -0700 |
---|---|---|
committer | Peter Zijlstra <peterz@infradead.org> | 2020-07-08 11:38:52 +0200 |
commit | f42be8651a7a9d5cb165e5d176fc0b09621b4f4d (patch) | |
tree | 34920f9367f679edb7efc4e00637633b69b54444 /arch/x86/include/asm/msr-index.h | |
parent | 530bfff6480307d210734222a54d56af7f908957 (diff) | |
download | linux-f42be8651a7a9d5cb165e5d176fc0b09621b4f4d.tar.bz2 |
perf/x86/intel/lbr: Use dynamic data structure for task_ctx
The type of task_ctx is hardcoded as struct x86_perf_task_context,
which doesn't apply for Architecture LBR. For example, Architecture LBR
doesn't have the TOS MSR. The number of LBR entries is variable. A new
struct will be introduced for Architecture LBR. Perf has to determine
the type of task_ctx at run time.
The type of task_ctx pointer is changed to 'void *', which will be
determined at run time.
The generic LBR optimization can be shared between Architecture LBR and
model-specific LBR. Both need to access the structure for the generic
LBR optimization. A helper task_context_opt() is introduced to retrieve
the pointer of the structure at run time.
Signed-off-by: Kan Liang <kan.liang@linux.intel.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/1593780569-62993-7-git-send-email-kan.liang@linux.intel.com
Diffstat (limited to 'arch/x86/include/asm/msr-index.h')
0 files changed, 0 insertions, 0 deletions