From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B0C51C4743E for ; Sun, 6 Jun 2021 18:54:14 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 89FD761220 for ; Sun, 6 Jun 2021 18:54:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229894AbhFFS4C (ORCPT ); Sun, 6 Jun 2021 14:56:02 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50498 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229738AbhFFS4B (ORCPT ); Sun, 6 Jun 2021 14:56:01 -0400 Received: from mail-lf1-x135.google.com (mail-lf1-x135.google.com [IPv6:2a00:1450:4864:20::135]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 79198C061766 for ; Sun, 6 Jun 2021 11:54:10 -0700 (PDT) Received: by mail-lf1-x135.google.com with SMTP id r5so22392346lfr.5 for ; Sun, 06 Jun 2021 11:54:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=w5VchHZ9HNMBKb35UdCCE6Gr/vCI3h3rPMpf00kyqNs=; b=R2WObvngmVBGf8fkmSu/raDi70MtimjnPeoLsRpzIZ/QqlhRT9W729qtXgs0y+YRgE RccuCLSCbjRdauVYzc5HtTIUl0hU4XX6sAN+eohhsDMHfJe3SgfHLry/97Z55h4vRb9s IIm7AvmNxOb4EStL6EMtVKwNqWcgL8ls8QUQo= 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; bh=w5VchHZ9HNMBKb35UdCCE6Gr/vCI3h3rPMpf00kyqNs=; b=fSyAtX7kuIGonIpHk6wlCKqz6KpF7oGV5ygSNp+4RVV0+pmQ12Q6l4cSEX22eHwHBN uT4GaCQqKtZuditFovmyR1GMi4LcMsE1R9tlNhtDcY7PCyNRQXo/HDg3VybA9SRUDFjJ mstzvwAh0bjRjdayDx4YlxkqEi4cFqnGLB9YnedrHI7j1Hyo8jKe0JJ+nRMQHxueOYd7 grJptn3lRuybdOtMYpx3sA6JqW8bbZwLiToARSZw6qwjMjl7JIp7Gs+G01NWx19+NaDc Wqhf5EKST4lbqisvVtRX84DuA+cLmggpgAdshfOhsk3fh+ZSWgpULe3CXuA0TH1fbKiI kI2g== X-Gm-Message-State: AOAM532s0Y5KjOyjwe/rv1YYo36z84bbmB1/mbJbn2DhY4S/XkzXdvM4 Z1AC9Pl+T0IQgvtuh8yjt4fklKfQWU2MGEIpsR0= X-Google-Smtp-Source: ABdhPJwVstRrKld/gONEKaIcZ6rqxdmaqRZPo5MdiDx4WT+YF0Ddvm/u4w8aQQd6V6PgcxUEjPQlZg== X-Received: by 2002:a19:4083:: with SMTP id n125mr9357269lfa.585.1623005648367; Sun, 06 Jun 2021 11:54:08 -0700 (PDT) Received: from mail-lj1-f170.google.com (mail-lj1-f170.google.com. [209.85.208.170]) by smtp.gmail.com with ESMTPSA id h8sm1225249lfd.73.2021.06.06.11.54.07 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 06 Jun 2021 11:54:07 -0700 (PDT) Received: by mail-lj1-f170.google.com with SMTP id w15so18898885ljo.10 for ; Sun, 06 Jun 2021 11:54:07 -0700 (PDT) X-Received: by 2002:a05:651c:333:: with SMTP id b19mr11965516ljp.61.1623005647379; Sun, 06 Jun 2021 11:54:07 -0700 (PDT) MIME-Version: 1.0 References: <20210604205600.GB4397@paulmck-ThinkPad-P17-Gen-1> <20210604214010.GD4397@paulmck-ThinkPad-P17-Gen-1> <20210605145739.GB1712909@rowland.harvard.edu> <20210606001418.GH4397@paulmck-ThinkPad-P17-Gen-1> <20210606012903.GA1723421@rowland.harvard.edu> <20210606115336.GS18427@gate.crashing.org> <20210606184021.GY18427@gate.crashing.org> In-Reply-To: From: Linus Torvalds Date: Sun, 6 Jun 2021 11:53:51 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [RFC] LKMM: Add volatile_if() To: Segher Boessenkool Cc: Alan Stern , "Paul E. McKenney" , Peter Zijlstra , Will Deacon , Andrea Parri , Boqun Feng , Nick Piggin , David Howells , Jade Alglave , Luc Maranget , Akira Yokosawa , Linux Kernel Mailing List , linux-toolchains@vger.kernel.org, linux-arch Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Jun 6, 2021 at 11:48 AM Linus Torvalds wrote: > And to work well, it needs "asm goto", which is so recent that a lot > of compilers don't support it (thank God for clang dragging gcc > kicking and screaming to implement it at all - I'd asked for it over a > decade ago). Oh, actually, I'm wrong on this. We don't need an output from the asm (the output ends up being in the targets), so we can use the old-style asm goto that we've been relying on for a long time. So the main code generation problem is just (a) all the architectures and (b) we'd have to use a fixed conditional against zero. Linus