[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <1299512819.2039.5.camel@castor.rsk>
Date:	Mon, 07 Mar 2011 15:46:59 +0000
From:	Richard Kennedy <richard@....demon.co.uk>
To:	Peter Zijlstra <a.p.zijlstra@...llo.nl>
Cc:	lkml <linux-kernel@...r.kernel.org>, Ingo Molnar <mingo@...e.hu>,
	Paul Mackerras <paulus@...ba.org>
Subject: [PATCH] trace: reorder 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@....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:
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/
Powered by blists - more mailing lists