kernel_optimize_test/arch/sh/kernel
Peter Zijlstra a4eaf7f146 perf: Rework the PMU methods
Replace pmu::{enable,disable,start,stop,unthrottle} with
pmu::{add,del,start,stop}, all of which take a flags argument.

The new interface extends the capability to stop a counter while
keeping it scheduled on the PMU. We replace the throttled state with
the generic stopped state.

This also allows us to efficiently stop/start counters over certain
code paths (like IRQ handlers).

It also allows scheduling a counter without it starting, allowing for
a generic frozen state (useful for rotating stopped counters).

The stopped state is implemented in two different ways, depending on
how the architecture implemented the throttled state:

 1) We disable the counter:
    a) the pmu has per-counter enable bits, we flip that
    b) we program a NOP event, preserving the counter state

 2) We store the counter state and ignore all read/overflow events

Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: paulus <paulus@samba.org>
Cc: stephane eranian <eranian@googlemail.com>
Cc: Robert Richter <robert.richter@amd.com>
Cc: Will Deacon <will.deacon@arm.com>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Cyrill Gorcunov <gorcunov@gmail.com>
Cc: Lin Ming <ming.m.lin@intel.com>
Cc: Yanmin <yanmin_zhang@linux.intel.com>
Cc: Deng-Cheng Zhu <dengcheng.zhu@gmail.com>
Cc: David Miller <davem@davemloft.net>
Cc: Michael Cree <mcree@orcon.net.nz>
LKML-Reference: <new-submission>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
2010-09-09 20:46:30 +02:00
..
cpu
vsyscall
.gitignore
asm-offsets.c
clkdev.c
cpufreq.c
crash_dump.c
debugtraps.S
disassemble.c
dma-nommu.c
dumpstack.c
dwarf.c
entry-common.S
ftrace.c
head_32.S
head_64.S
hw_breakpoint.c
idle.c
init_task.c
io_generic.c
io_trapped.c
io.c
irq_32.c
irq_64.c
irq.c
kgdb.c
kprobes.c
localtimer.c
machine_kexec.c lmb: rename to memblock 2010-07-14 17:14:00 +10:00
machvec.c
Makefile
module.c
nmi_debug.c
perf_callchain.c perf: Factorize callchain context handling 2010-08-19 01:32:11 +02:00
perf_event.c perf: Rework the PMU methods 2010-09-09 20:46:30 +02:00
process_32.c Make do_execve() take a const filename pointer 2010-08-17 18:07:43 -07:00
process_64.c Make do_execve() take a const filename pointer 2010-08-17 18:07:43 -07:00
process.c
ptrace_32.c
ptrace_64.c
reboot.c
relocate_kernel.S
return_address.c
setup.c lmb: rename to memblock 2010-07-14 17:14:00 +10:00
sh_bios.c
sh_ksyms_32.c
sh_ksyms_64.c
signal_32.c
signal_64.c
smp.c
stacktrace.c
swsusp.c
sys_sh32.c Make do_execve() take a const filename pointer 2010-08-17 18:07:43 -07:00
sys_sh64.c Make do_execve() take a const filename pointer 2010-08-17 18:07:43 -07:00
sys_sh.c
syscalls_32.S
syscalls_64.S
time.c
topology.c
traps_32.c
traps_64.c
traps.c
unwinder.c
vmlinux.lds.S