Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753888Ab1CGPrG (ORCPT ); Mon, 7 Mar 2011 10:47:06 -0500 Received: from anchor-post-3.mail.demon.net ([195.173.77.134]:35130 "EHLO anchor-post-3.mail.demon.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750881Ab1CGPrE (ORCPT ); Mon, 7 Mar 2011 10:47:04 -0500 Subject: [PATCH] trace: reorder perf_event_context to remove alignment padding on 64 bit builds From: Richard Kennedy To: Peter Zijlstra Cc: lkml , Ingo Molnar , Paul Mackerras Content-Type: text/plain; charset="UTF-8" Date: Mon, 07 Mar 2011 15:46:59 +0000 Message-ID: <1299512819.2039.5.camel@castor.rsk> Mime-Version: 1.0 X-Mailer: Evolution 2.32.1 (2.32.1-1.fc14) Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1064 Lines: 35 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 --- 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@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/