diff options
author | Peter Zijlstra <a.p.zijlstra@chello.nl> | 2009-06-10 07:40:57 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-06-10 10:55:26 -0400 |
commit | bd2b5b12849a3446abad0b25e920f86f5480b309 (patch) | |
tree | b0eacf6002f2015c0483390619a3f874bcb7e7d2 /include | |
parent | dc81081b2d9a6a9d64dad1bef1e5fc9fb660e53e (diff) |
perf_counter: More aggressive frequency adjustment
Also employ the overflow handler to adjust the frequency, this results
in a stable frequency in about 40~50 samples, instead of that many ticks.
This also means we can start sampling at a sample period of 1 without
running head-first into the throttle.
It relies on sched_clock() to accurately measure the time difference
between the overflow NMIs.
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
LKML-Reference: <new-submission>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/perf_counter.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/perf_counter.h b/include/linux/perf_counter.h index 3586df840f69..282d8cc48980 100644 --- a/include/linux/perf_counter.h +++ b/include/linux/perf_counter.h | |||
@@ -371,6 +371,7 @@ struct hw_perf_counter { | |||
371 | 371 | ||
372 | u64 freq_count; | 372 | u64 freq_count; |
373 | u64 freq_interrupts; | 373 | u64 freq_interrupts; |
374 | u64 freq_stamp; | ||
374 | #endif | 375 | #endif |
375 | }; | 376 | }; |
376 | 377 | ||