linux/arch/x86/kernel/cpu
Robert Richter 450bbd493d perf/x86-ibs: Precise event sampling with IBS for AMD CPUs
This patch adds support for precise event sampling with IBS. There are
two counting modes to count either cycles or micro-ops. If the
corresponding performance counter events (hw events) are setup with
the precise flag set, the request is redirected to the ibs pmu:

 perf record -a -e cpu-cycles:p ...    # use ibs op counting cycle count
 perf record -a -e r076:p ...          # same as -e cpu-cycles:p
 perf record -a -e r0C1:p ...          # use ibs op counting micro-ops

Each ibs sample contains a linear address that points to the
instruction that was causing the sample to trigger. With ibs we have
skid 0. Thus, ibs supports precise levels 1 and 2. Samples are marked
with the PERF_EFLAGS_EXACT flag set. In rare cases the rip is invalid
when IBS was not able to record the rip correctly. Then the
PERF_EFLAGS_EXACT flag is cleared and the rip is taken from pt_regs.

V2:
* don't drop samples in precise level 2 if rip is invalid, instead
  support the PERF_EFLAGS_EXACT flag

Signed-off-by: Robert Richter <robert.richter@amd.com>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/20120502103309.GP18810@erda.amd.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2012-05-09 15:23:14 +02:00
..
mcheck Disintegrate asm/system.h for X86 2012-03-28 18:11:12 +01:00
mtrr Merge branch 'x86-x32-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2012-03-29 18:12:23 -07:00
.gitignore
amd.c x86/sched/perf/AMD: Set sched_clock_stable 2012-02-07 13:12:08 +01:00
bugs.c x86-32, fpu: Fix DNA exception during check_fpu() 2011-06-30 17:29:47 -07:00
bugs_64.c
centaur.c x86, centaur: Enable cx8 for VIA Eden too 2011-12-15 08:04:42 -08:00
common.c Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2012-03-29 14:28:26 -07:00
cpu.h x86, CPU: Drop superfluous get_cpu_cap() prototype 2011-12-09 08:00:53 +01:00
cyrix.c
hypervisor.c x86, hyper: Change hypervisor detection order 2011-07-08 16:22:29 -07:00
intel.c x86: Simplify code by removing a !SMP #ifdefs from 'struct cpuinfo_x86' 2011-12-21 09:25:09 +01:00
intel_cacheinfo.c x86/amd: Fix L1i and L2 cache sharing information for AMD family 15h processors 2012-02-09 09:38:15 +01:00
Makefile Add driver auto probing for x86 features v4 2012-01-26 16:44:41 -08:00
match.c x86/cpu: Clean up modalias feature matching 2012-02-13 15:24:26 -08:00
mkcapflags.pl
mshyperv.c x86: Hyper-V: Integrate the clocksource with Hyper-V detection code 2011-09-08 10:33:59 +02:00
perf_event.c perf: Pass last sampling period to perf_sample_data_init() 2012-05-09 15:23:12 +02:00
perf_event.h perf: Adding sysfs group format attribute for pmu device 2012-03-16 14:06:06 -03:00
perf_event_amd.c perf/x86-ibs: Precise event sampling with IBS for AMD CPUs 2012-05-09 15:23:14 +02:00
perf_event_amd_ibs.c perf/x86-ibs: Precise event sampling with IBS for AMD CPUs 2012-05-09 15:23:14 +02:00
perf_event_intel.c perf: Pass last sampling period to perf_sample_data_init() 2012-05-09 15:23:12 +02:00
perf_event_intel_ds.c perf: Pass last sampling period to perf_sample_data_init() 2012-05-09 15:23:12 +02:00
perf_event_intel_lbr.c perf/x86: Add LBR software filter support for Intel CPUs 2012-03-05 14:55:42 +01:00
perf_event_p4.c perf: Pass last sampling period to perf_sample_data_init() 2012-05-09 15:23:12 +02:00
perf_event_p6.c perf: Adding sysfs group format attribute for pmu device 2012-03-16 14:06:06 -03:00
perfctr-watchdog.c perf, x86: Add new AMD family 15h msrs to perfctr reservation code 2011-02-16 13:30:50 +01:00
powerflags.c x86: Report cpb and eff_freq_ro flags correctly 2011-12-15 08:14:49 +01:00
proc.c x86: Simplify code by removing a !SMP #ifdefs from 'struct cpuinfo_x86' 2011-12-21 09:25:09 +01:00
rdrand.c x86, random: Verify RDRAND functionality and allow it to be disabled 2011-07-31 14:02:19 -07:00
scattered.c X86: Introduce HW-Pstate scattered cpuid feature 2012-01-26 16:49:06 -08:00
sched.c
topology.c x86, cpu: Split addon_cpuid_features.c 2010-07-19 19:02:41 -07:00
transmeta.c
umc.c
vmware.c x86: Fix common misspellings 2011-03-18 10:39:30 +01:00