mirror-linux/tools/perf/arch
Thomas Falcon 6b9c0261b3 perf record: Add ratio-to-prev term
Provide ratio-to-prev term which allows the user to
set the event sample period of two events corresponding
to a desired ratio.

If using on an Intel x86 platform with Auto Counter Reload support, also
set corresponding event's config2 attribute with a bitmask which
counters to reset and which counters to sample if the desired ratio is
met or exceeded.

On other platforms, only the sample period is affected by the
ratio-to-prev term.

Reviewed-by: Ian Rogers <irogers@google.com>
Signed-off-by: Thomas Falcon <thomas.falcon@intel.com>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Dapeng Mi <dapeng1.mi@linux.intel.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Kan Liang <kan.liang@linux.intel.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
2025-10-03 16:49:51 -03:00
..
alpha perf build: Remove Makefile.syscalls 2025-03-20 22:58:20 -07:00
arc/annotate perf build: Remove Makefile.syscalls 2025-03-20 22:58:20 -07:00
arm tools headers: Sync syscall tables with the kernel source 2025-08-18 13:49:25 -07:00
arm64 perf arm_spe: Add "event_filter" entry in meta data 2025-09-19 12:14:28 -03:00
csky perf build: Remove Makefile.syscalls 2025-03-20 22:58:20 -07:00
loongarch perf build: Remove Makefile.syscalls 2025-03-20 22:58:20 -07:00
mips tools headers: Sync syscall tables with the kernel source 2025-08-18 13:49:25 -07:00
parisc perf build: Remove Makefile.syscalls 2025-03-20 22:58:20 -07:00
powerpc perf powerpc: Add basic CONFIG_AUXTRACE support for VPA pmu on powerpc 2025-10-01 11:22:04 -03:00
riscv RISC-V: perf/kvm: Add reporting of interrupt events 2025-07-28 22:28:25 +05:30
riscv64/annotate perf disasm: Add e_machine/e_flags to struct arch 2024-11-09 08:39:13 -08:00
s390 tools headers: Sync syscall tables with the kernel source 2025-08-18 13:49:25 -07:00
sh tools headers: Sync syscall tables with the kernel source 2025-08-18 13:49:25 -07:00
sparc tools headers: Sync syscall tables with the kernel source 2025-08-18 13:49:25 -07:00
x86 perf record: Add ratio-to-prev term 2025-10-03 16:49:51 -03:00
xtensa tools headers: Sync syscall tables with the kernel source 2025-08-18 13:49:25 -07:00
Build perf util: Make util its own library 2024-06-26 11:07:42 -07:00
common.c perf tools riscv: Add support for riscv lookup_binutils_path 2023-05-12 15:21:48 -03:00
common.h perf annotate: Own objdump_path and disassembler_style strings 2023-04-04 09:39:56 -03:00