Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1622323imu; Wed, 12 Dec 2018 01:06:49 -0800 (PST) X-Google-Smtp-Source: AFSGD/W6K2qJxixjhzPsTleWCKyaiCP5gHXaAoYKx6O73NwzCOUwJJqStyJamOZ2Pmtnd1AXasVZ X-Received: by 2002:a65:534b:: with SMTP id w11mr17670708pgr.125.1544605609830; Wed, 12 Dec 2018 01:06:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1544605609; cv=none; d=google.com; s=arc-20160816; b=Th5fwW7FIY93J69HFpC9mWoRpne9Opc/pKwyv+Fg5NtUKIo8czRT0ZbxaLzzYgZmo+ OU7rPynri6zCINBKGSOStl7s6zJfIQMYA67RNmKScAAxNFWMvPdVDt4SUXaeQtI1c6qt s1qiQJqFZy7i9dpF7q7/DvBADCqR2EjR1Q2kwvjpSZH4cNSwqxTPk7rt1fSPqQVTX4Vf SWd4aihKu/B6+P5udLaXmZc1/mPJYbgjJVTwSCEGEqa0/Tpw8EPCG3ZYBb138pfmTO8B zcp7vLZuB4Kpf4dElhbB4Oj2+/ueJQfSk9IeiDYcS9aOmsDb4B+rLnbgESckYlsDOlcH OrCg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version; bh=ZLUMX2Z5QbQOp6WiQd4rGPS91CISvdgemPwmTI9cz1I=; b=qwgsPYCFt39GbkYBdqzRgYS0UJNnQvL2JedGSXKhv/cLlH6iEmfMdZ24ZDb3irFZLZ 9x2J23Dq6iMyhHN4o+Qdav4sv8pcMfKPtIGWUe5FHjGFUDXw8EtZd9461i7Fe6f6QM7s Cc2+bo24LviRBs1CPsb1WU4a6HPGifzERgfZQhQEYGuJ3eiO5zmecpleh/R/Auuj1apN B+8sAD26mLEG9ILKknngqQ6/UjymXMSJnvdHeeu7LWKwsEAGximWpNZpoX36wp+IWFu2 RLKd8GX5khaQebBBEE4h7gLm3FVDmzuh//bH+E4mjU4Pi+u69upEv5TJhzPBlajVX0Jv /Jxw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id bj2si13900653plb.27.2018.12.12.01.06.33; Wed, 12 Dec 2018 01:06:49 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726840AbeLLJFO convert rfc822-to-8bit (ORCPT + 99 others); Wed, 12 Dec 2018 04:05:14 -0500 Received: from mail-qt1-f193.google.com ([209.85.160.193]:33670 "EHLO mail-qt1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726728AbeLLJFO (ORCPT ); Wed, 12 Dec 2018 04:05:14 -0500 Received: by mail-qt1-f193.google.com with SMTP id l11so19692759qtp.0; Wed, 12 Dec 2018 01:05:12 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=Pe2hX+my2Rep6sFBugNFkpZL8ollwFC2yHQLZVYCr1w=; b=Ua0cQNcMbeXzXEL49nycFKRXn1s5vI84CN7oKfBB12oHh01h9BoThcUw7M2PGAFhXz 9RHH4NPYc1x4FjLGnE3g4ZF/NseVKnFvfbc7usYfzvocl+3aXtvsyiQSLMahaf3b9Zwz KJH1DhZK6QklOX0dO6+165Y21EKI7n4cL6UCS/D0dDA41pDKPUDdc9DfSMvb1RkmCwbX T3m1ZJyZKKeIuDqk/TN1sC0rU7jEZ+3jgBptOrhGUoVdiwiMvEsCk1cDgehNp9PP/Yyi dM8/fQ1DFeh7agN3p+uyfwsvWRuje1p8Pp30+xgh1MP1r4FiT8xntsS87eu0STNHZKw4 6pIA== X-Gm-Message-State: AA+aEWZhbMDrsf+b74KQSzrsDpPPbGCRX+T2v+jMFShaMmO2dWV/iTu5 hJyjdUeV69I2qJ28zAA3xFaPwznoPp6Esp9q8dpSvyUW X-Received: by 2002:aed:35c5:: with SMTP id d5mr18850332qte.212.1544605512042; Wed, 12 Dec 2018 01:05:12 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Arnd Bergmann Date: Wed, 12 Dec 2018 10:04:53 +0100 Message-ID: Subject: Re: Can we drop upstream Linux x32 support? To: tg@mirbsd.de Cc: Andy Lutomirski , Linus Torvalds , "the arch/x86 maintainers" , Linux Kernel Mailing List , Linux API , "H. Peter Anvin" , Peter Zijlstra , Borislav Petkov , Florian Weimer , vapier@gentoo.org, "H.J. Lu" , Rich Felker , x32@buildd.debian.org, Will Deacon , Catalin Marinas Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Dec 12, 2018 at 3:38 AM Thorsten Glaser wrote: > > Andy Lutomirski dixit: > > >That’s the thing, though: the whole generic kernel compat > >infrastructure assumes there are at most two ABIs: native and, if > >enabled and relevant, compat. x32 breaks this entirely. > > MIPS had o32, n32, n64 since like forever. o32 and n32 are practically the same, the only difference on the syscall ABI that I can see are the actual syscall numbers, and the 'struct sigcontext' definition. > ARM has old ABI, EABI and now 64-bit. arm64 intentionally did not attempt to support OABI user space because of this, and as I said the ilp32 ABI follows what MIPS n32 does using the same data structures as aarch32 (corresponding to mips o32). > >How hard would it be to have __attribute__((ilp64)), with an optional > >warning if any embedded structs are not ilp64? This plus a wrapper to > > You mean LP64. Impossible, because LP64 vs. ILP32 is not the only > difference between amd64 and x32. I think the above is what Intel's compiler does, and similar to what they do for mixing big-endian and little-endian code (!). Generally possible yes, but a lot of work, as well as error-prone and not particular appealing for the GNU toolchain IMHO. Arnd