From: Richard Kennedy <richard@rsk.demon.co.uk>
To: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: lkml <linux-kernel@vger.kernel.org>, Ingo Molnar <mingo@elte.hu>,
Paul Mackerras <paulus@samba.org>
Subject: [PATCH] trace: reorder perf_event_context to remove alignment padding on 64 bit builds
Date: Mon, 07 Mar 2011 15:46:59 +0000 [thread overview]
Message-ID: <1299512819.2039.5.camel@castor.rsk> (raw)
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:
next reply other threads:[~2011-03-07 15:47 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-07 15:46 Richard Kennedy [this message]
2011-03-16 13:59 ` [tip:perf/urgent] perf: Reorder & optimize " tip-bot for Richard Kennedy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1299512819.2039.5.camel@castor.rsk \
--to=richard@rsk.demon.co.uk \
--cc=a.p.zijlstra@chello.nl \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=paulus@samba.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®