From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.4 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: (qmail 3900 invoked from network); 16 Apr 2020 03:41:47 -0000 Received-SPF: pass (mother.openwall.net: domain of lists.openwall.com designates 195.42.179.200 as permitted sender) receiver=inbox.vuxu.org; client-ip=195.42.179.200 envelope-from= Received: from mother.openwall.net (195.42.179.200) by inbox.vuxu.org with UTF8ESMTPZ; 16 Apr 2020 03:41:47 -0000 Received: (qmail 13964 invoked by uid 550); 16 Apr 2020 03:41:45 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Reply-To: musl@lists.openwall.com Received: (qmail 13944 invoked from network); 16 Apr 2020 03:41:45 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:subject:to:cc:references:in-reply-to:mime-version :message-id:content-transfer-encoding; bh=Z9O0pZ2p7ciHcWf3QNrxtPlkP1qSZEC8S5OBGgW/IQw=; b=TFhYteRHDpRvimovB/R0iOhrSXoupEpMjsur++qOeh/i5avnxQ6f638jdv2FfO7p+x aWyno9oxqo2EiB2GCZXcLWW8FhnEqIjdWN6DuOLKejdYQzhXtWYkWTRQ53oE21r6CqhF 4vOsm040nKu4vx6Z01yff2S+dcGCawUNisBBMC9cEeRytvnLMzy7H0Wu+TRsyaguTirX Ytf1UxTbkwweGjwXpjJTi2nnKA4qnnBi+ur7g9PJNCyCXVYxJEEW5ZxfBw4PbIaNi0Tc 5KQCxQg1RHpGCWoq3gjos0ot5YkgBy+6nbjowvb/dvE/VB9gPVVdw83KFgRNTIrUffg3 kDag== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:subject:to:cc:references:in-reply-to :mime-version:message-id:content-transfer-encoding; bh=Z9O0pZ2p7ciHcWf3QNrxtPlkP1qSZEC8S5OBGgW/IQw=; b=H7IUFPjoA+Vd2YwArU9ziyffN8jlzjdGv8tAhxIIeZOG32t2jTye4pE5Anb+H8CPfy r1zFPqwXrHniTVAXt2NYbdywNWPpJyfB6vgaGJY0ElU1oGLHzho7FFhX5jXbhz5fuUa7 jNxN0GTJ1OQH3nDOBESfET3L+da9ogi1MxsSHJZG3Uy45a/QnfKSwgNEQCiIgE/fsUJi ZmtTz+xocU/O2NrYtcJro2DVB/7udcLtVJpsmbvD4ncyOXEcyuG5JkSzpqz3f2VIgVzE 0+ErFngBEyxtYsI1wWA+orXWPPvu3V/p2tJQq1sOu3aztsjIdhhTeS1tukbP12RZ5RZT rJtQ== X-Gm-Message-State: AGi0PuYduJQA7J6qvo3Euhq0opOds6HUFAocSQlAWHOlxJYP6slqxUwS HgQGioauJ9yZjYNKVr3tdz8= X-Google-Smtp-Source: APiQypKeMiEyos0BNu9CFePCNQutY2CaDFVyj6RZIFFZMby2BpaivbNPl5pWflF6yjbXZswcULoU3g== X-Received: by 2002:a63:7b1a:: with SMTP id w26mr28207212pgc.298.1587008493091; Wed, 15 Apr 2020 20:41:33 -0700 (PDT) Date: Thu, 16 Apr 2020 13:41:01 +1000 From: Nicholas Piggin To: Rich Felker Cc: libc-alpha@sourceware.org, libc-dev@lists.llvm.org, linuxppc-dev@lists.ozlabs.org, musl@lists.openwall.com, Segher Boessenkool References: <1586931450.ub4c8cq8dj.astroid@bobo.none> <20200415225539.GL11469@brightrain.aerifal.cx> <1586994952.nnxigedbu2.astroid@bobo.none> <20200416004843.GO11469@brightrain.aerifal.cx> <1587002854.f0slo0111r.astroid@bobo.none> <20200416023542.GP11469@brightrain.aerifal.cx> <1587004907.ioxh0bxsln.astroid@bobo.none> <20200416030304.GQ11469@brightrain.aerifal.cx> In-Reply-To: <20200416030304.GQ11469@brightrain.aerifal.cx> MIME-Version: 1.0 Message-Id: <1587007359.3k5vvojlfu.astroid@bobo.none> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [musl] Powerpc Linux 'scv' system call ABI proposal take 2 Excerpts from Rich Felker's message of April 16, 2020 1:03 pm: > On Thu, Apr 16, 2020 at 12:53:31PM +1000, Nicholas Piggin wrote: >> > Not to mention the dcache line to access >> > __hwcap or whatever, and the icache lines to setup access TOC-relative >> > access to it. (Of course you could put a copy of its value in TLS at a >> > fixed offset, which would somewhat mitigate both.) >> >=20 >> >> And finally, the HWCAP test can eventually go away in future. A vdso >> >> call can not. >> >=20 >> > We support nearly arbitrarily old kernels (with limited functionality) >> > and hardware (with full functionality) and don't intend for that to >> > change, ever. But indeed glibc might want too eventually drop the >> > check. >>=20 >> Ah, cool. Any build-time flexibility there? >>=20 >> We may or may not be getting a new ABI that will use instructions not=20 >> supported by old processors. >>=20 >> https://sourceware.org/legacy-ml/binutils/2019-05/msg00331.html >>=20 >> Current ABI continues to work of course and be the default for some=20 >> time, but building for new one would give some opportunity to drop >> such support for old procs, at least for glibc. >=20 > What does "new ABI" entail to you? In the terminology I use with musl, > "new ABI" and "new ISA level" are different things. You can compile > (explicit -march or compiler default) binaries that won't run on older > cpus due to use of new insns etc., but we consider it the same ABI if > you can link code for an older/baseline ISA level with the > newer-ISA-level object files, i.e. if the interface surface for > linkage remains compatible. We also try to avoid gratuitous > proliferation of different ABIs unless there's a strong underlying > need (like addition of softfloat ABIs for archs that usually have FPU, > or vice versa). Yeah it will be a new ABI type that also requires a new ISA level. As far as I know (and I'm not on the toolchain side) there will be some call compatibility between the two, so it may be fine to continue with existing ABI for libc. But it just something that comes to mind as a build-time cutover where we might be able to assume particular features. > In principle the same could be done for kernels except it's a bigger > silent gotcha (possible ENOSYS in places where it shouldn't be able to > happen rather than a trapping SIGILL or similar) and there's rarely > any serious performance or size benefit to dropping support for older > kernels. Right, I don't think it'd be a huge problem whatever way we go, compared with the cost of the system call. Thanks, Nick