summaryrefslogtreecommitdiffstats
path: root/tools/perf/util/session.h
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2010-11-30 17:49:55 +0000
committerArnaldo Carvalho de Melo <acme@redhat.com>2010-11-30 20:05:25 -0200
commit5c891f3840a7a330c96d7203d4bb5be6fa033724 (patch)
treebf8fdacde9410f396e382eebfdb924be479e8d7e /tools/perf/util/session.h
parent020bb75a6deeca5ebeae531dc7378c157affc8fd (diff)
downloadblackbird-op-linux-5c891f3840a7a330c96d7203d4bb5be6fa033724.tar.gz
blackbird-op-linux-5c891f3840a7a330c96d7203d4bb5be6fa033724.zip
perf session: Allocate chunks of sample objects
The ordered sample code allocates singular reference objects struct sample_queue which have 48byte size on 64bit and 20 bytes on 32bit. That's silly. Allocate ~64k sized chunks and hand them out. Performance gain: ~ 15% Cc: Ingo Molnar <mingo@elte.hu> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Frederic Weisbecker <fweisbec@gmail.com> LKML-Reference: <20101130163820.398713983@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/session.h')
-rw-r--r--tools/perf/util/session.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/tools/perf/util/session.h b/tools/perf/util/session.h
index e4a7ff2ba8d5..5bf6efa3788a 100644
--- a/tools/perf/util/session.h
+++ b/tools/perf/util/session.h
@@ -19,7 +19,10 @@ struct ordered_samples {
u64 max_timestamp;
struct list_head samples;
struct list_head sample_cache;
+ struct list_head to_free;
+ struct sample_queue *sample_buffer;
struct sample_queue *last_sample;
+ int sample_buffer_idx;
};
struct perf_session {
OpenPOWER on IntegriCloud