From mboxrd@z Thu Jan 1 00:00:00 1970 From: "H. Peter Anvin" Subject: Re: [PATCH v4 1/5] getcpu_cache system call: cache CPU number of running thread Date: Mon, 29 Feb 2016 10:19:17 -0800 Message-ID: <6F943352-C454-4533-B61C-DF7D828B3B7D@zytor.com> References: <1456270120-7560-1-git-send-email-mathieu.desnoyers@efficios.com> <1082926946.10326.1456619994590.JavaMail.zimbra@efficios.com> <20160229103221.GI6356@twins.programming.kicks-ass.net> <3364335.Bqf8sAzlTS@wuerfel> <1811549980.11849.1456749709589.JavaMail.zimbra@efficios.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Return-path: In-Reply-To: <1811549980.11849.1456749709589.JavaMail.zimbra-vg+e7yoeK/dWk0Htik3J/w@public.gmane.org> Sender: linux-api-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Mathieu Desnoyers , Arnd Bergmann Cc: Peter Zijlstra , Linus Torvalds , Ben Maurer , Thomas Gleixner , Ingo Molnar , Russell King , linux-api , Andrew Morton , Michael Kerrisk , Dave Watson , rostedt , Andy Lutomirski , Will Deacon , "Paul E. McKenney" , Chris Lameter , Andi Kleen , Josh Triplett , Paul Turner , Linux Kernel Mailing List , Catalin Marinas , Andrew Hunter List-Id: linux-api@vger.kernel.org On February 29, 2016 4:41:49 AM PST, Mathieu Desnoyers wrote: > >Agreed that many architectures issue slower instructions when reading >from packed structures, which is unwanted. > And detrimental to atomicity. >Could we require that each field be naturally aligned and require that >they are placed so _no_ padding whatsoever should ever be added by the >compiler ? If that's possible, then we could remove the packed. What people have been trying to tell you is that we *must* do this, and no compiler truck like packed will help. -- Sent from my Android device with K-9 Mail. Please excuse brevity and formatting.