From mboxrd@z Thu Jan 1 00:00:00 1970 From: Florian Weimer Subject: Re: Can we drop upstream Linux x32 support? Date: Thu, 13 Dec 2018 17:04:59 +0100 Message-ID: <87o99pl8es.fsf@oldenburg2.str.redhat.com> References: <20181212165237.GT23599@brightrain.aerifal.cx> <20181213124025.bczxzj6ez34joo6v@localhost> <20181213155744.GU23599@brightrain.aerifal.cx> Mime-Version: 1.0 Content-Type: text/plain Return-path: In-Reply-To: <20181213155744.GU23599@brightrain.aerifal.cx> (Rich Felker's message of "Thu, 13 Dec 2018 10:57:44 -0500") Sender: linux-kernel-owner@vger.kernel.org To: Rich Felker Cc: Catalin Marinas , Andy Lutomirski , tg@mirbsd.de, Linus Torvalds , X86 ML , LKML , Linux API , "H. Peter Anvin" , Peter Zijlstra , Borislav Petkov , Mike Frysinger , "H. J. Lu" , x32@buildd.debian.org, Arnd Bergmann , Will Deacon List-Id: linux-api@vger.kernel.org * Rich Felker: >> If the compiler can handle the zeroing, that would be great, though not >> sure how (some __attribute__((zero)) which generates a type constructor >> for such structure; it kind of departs from what the C language offers). > > The compiler fundamentally can't. At the very least it would require > effective type tracking, which requires shadow memory and is even more > controversial than -fstrict-aliasing (because in a sense it's a > stronger version thereof). It's possible to do it with the right types. See _Bool on 32-bit Darwin PowerPC for an example, which is four bytes instead of the usual one. Similarly, we could have integer types with trap representations. Whether it is a good idea is a different matter, but the amount of compiler magic required is actually limited. Thanks, Florian