* [PATCH] trace: reorder perf_event_context to remove alignment padding on 64 bit builds
@ 2011-03-07 15:46 Richard Kennedy
2011-03-16 13:59 ` [tip:perf/urgent] perf: Reorder & optimize " tip-bot for Richard Kennedy
0 siblings, 1 reply; 2+ messages in thread
From: Richard Kennedy @ 2011-03-07 15:46 UTC (permalink / raw)
To: Peter Zijlstra; +Cc: lkml, Ingo Molnar, Paul Mackerras
Remove 8 bytes of alignment padding from perf_event_context on 64 bit
builds which shrinks its size to 192 bytes allowing it to fit into one
fewer cache lines and into a smaller slab.
Signed-off-by: Richard Kennedy <richard@rsk.demon.co.uk>
---
patch against v2.6.38-rc7
compiled and tested on x86_64
regards
Richard
diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h
index dda5b0a..59792fe 100644
--- a/include/linux/perf_event.h
+++ b/include/linux/perf_event.h
@@ -846,8 +846,8 @@ enum perf_event_context_type {
* Used as a container for task events and CPU events as well:
*/
struct perf_event_context {
- enum perf_event_context_type type;
struct pmu *pmu;
+ enum perf_event_context_type type;
/*
* Protect the states of the events in the list,
* nr_active, and the list:
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [tip:perf/urgent] perf: Reorder & optimize perf_event_context to remove alignment padding on 64 bit builds
2011-03-07 15:46 [PATCH] trace: reorder perf_event_context to remove alignment padding on 64 bit builds Richard Kennedy
@ 2011-03-16 13:59 ` tip-bot for Richard Kennedy
0 siblings, 0 replies; 2+ messages in thread
From: tip-bot for Richard Kennedy @ 2011-03-16 13:59 UTC (permalink / raw)
To: linux-tip-commits
Cc: linux-kernel, hpa, mingo, a.p.zijlstra, richard, tglx, mingo
Commit-ID: ee643c4179c3a18b018de3a4c07a7bb3a75c8e4e
Gitweb: http://git.kernel.org/tip/ee643c4179c3a18b018de3a4c07a7bb3a75c8e4e
Author: Richard Kennedy <richard@rsk.demon.co.uk>
AuthorDate: Mon, 7 Mar 2011 15:46:59 +0000
Committer: Ingo Molnar <mingo@elte.hu>
CommitDate: Wed, 16 Mar 2011 14:04:14 +0100
perf: Reorder & optimize perf_event_context to remove alignment padding on 64 bit builds
Remove 8 bytes of alignment padding from perf_event_context on 64 bit
builds which shrinks its size to 192 bytes allowing it to fit into one
fewer cache lines and into a smaller slab.
Signed-off-by: Richard Kennedy <richard@rsk.demon.co.uk>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
LKML-Reference: <1299512819.2039.5.camel@castor.rsk>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
---
include/linux/perf_event.h | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h
index 614615b..f495c01 100644
--- a/include/linux/perf_event.h
+++ b/include/linux/perf_event.h
@@ -878,8 +878,8 @@ enum perf_event_context_type {
* Used as a container for task events and CPU events as well:
*/
struct perf_event_context {
- enum perf_event_context_type type;
struct pmu *pmu;
+ enum perf_event_context_type type;
/*
* Protect the states of the events in the list,
* nr_active, and the list:
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-03-16 13:59 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-03-07 15:46 [PATCH] trace: reorder perf_event_context to remove alignment padding on 64 bit builds Richard Kennedy
2011-03-16 13:59 ` [tip:perf/urgent] perf: Reorder & optimize " tip-bot for Richard Kennedy
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox