perf: Optimize some swcounter attr.sample_period==1 paths
authorPeter Zijlstra <a.p.zijlstra@chello.nl>
Fri, 20 Nov 2009 21:19:44 +0000 (22:19 +0100)
committerIngo Molnar <mingo@elte.hu>
Sat, 21 Nov 2009 13:11:35 +0000 (14:11 +0100)
commit0cff784ae41cc125368ae77f1c01328ae2fdc6b3
tree54e6f387d945d724c00bb33118ef138831a68d10
parent453f19eea7dbad837425e9b07d84568d14898794
perf: Optimize some swcounter attr.sample_period==1 paths

Avoid the rather expensive perf_swevent_set_period() if we know
we have to sample every single event anyway.

Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Paul Mackerras <paulus@samba.org>
LKML-Reference: <20091120212508.299508332@chello.nl>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
kernel/perf_event.c