Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp673308ybt; Wed, 8 Jul 2020 08:59:07 -0700 (PDT) X-Google-Smtp-Source: ABdhPJynWA0dQJjdHtIm773us2zgF1pJp/t8f7OYulkgViV9fMVVYbyVkmX3DfpKIk0NePFoiLLG X-Received: by 2002:a17:906:c209:: with SMTP id d9mr28255449ejz.449.1594223947093; Wed, 08 Jul 2020 08:59:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594223947; cv=none; d=google.com; s=arc-20160816; b=yerm3OiIlHfME8EkPwnRtrNz/4AcT355MxGfs4qH2BBzo200Xas0cEdEcG6/ec77ey im2QqagiPtxxEFXlhwINLULfSbnQ3XW5NSaJIdGEl9nCeVDneLVbshLTX0OatXVGUGmz rmNEsa0UcYe/8ls7IRVhIKmnHsNdFAqgeh56injlCLQD6Np8HTW81cjUc4zqaPcV8Bry RdzGLvEmqbrPSzFRd9YOqrEhYOHsjbxjGDBCNDD6x4l1ueV51kN50yU1Eb9sdGgLw9Q0 yD3plXfUmRZi+DdQY56SgAlFcYV1i384G2Egw98rSLlxvVxF+umXrK4fGWrC94dlA4jc moEw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from :dkim-signature:dkim-signature:date; bh=hBBgGGCt/li9DGockH9AHi0xKPYeo4iYHq8uBfnLO+E=; b=B2w42YraOhqNXR/bHGSXSNI5OKEn/4PFFAIK744B+jsH+yRNf8UVBQxyMj6yQ+f6kN e8UuqgxrUOJA9bUaTdF7pSlCokXGU/nxmPi9EkbAu8fpPYaHFqA1u9P+060ITlaa8XhZ oRpKNG2TEF8F9fGEamxzqMQrviwu/Yi3Ko+HK0rC/ds7F9iueX7Rp4jHfr1Xf8a2n8V2 JUGRbHqpQNQv10TCVBYL1Derowz8lF6p43z+kI+wDRvH1Bj7JC5FsINbatm1tq79zJd0 EHvM3YpAMwDvoBj5M8eURAN6JsUP4UWOAXDkdJqm47nOHp5WU7MevLylrIm2E1zryReI aFAA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=ZKSfrh08; dkim=neutral (no key) header.i=@vger.kernel.org header.s=2020e; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m4si146412ejd.630.2020.07.08.08.58.43; Wed, 08 Jul 2020 08:59:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=ZKSfrh08; dkim=neutral (no key) header.i=@vger.kernel.org header.s=2020e; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730259AbgGHP6S (ORCPT + 99 others); Wed, 8 Jul 2020 11:58:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35780 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729022AbgGHP6R (ORCPT ); Wed, 8 Jul 2020 11:58:17 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [IPv6:2a0a:51c0:0:12e:550::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C5B42C061A0B for ; Wed, 8 Jul 2020 08:58:17 -0700 (PDT) Date: Wed, 8 Jul 2020 17:58:13 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1594223895; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=hBBgGGCt/li9DGockH9AHi0xKPYeo4iYHq8uBfnLO+E=; b=ZKSfrh08hX+4yxiF/RyBk7gVBlMjP2EPeOe2MvB7y0tvEx59m9JHg2wmOwuW4yYoHS7nlF sqHj3mzdQVBxCyad/227LTKrofpbNHOM9EGE7PEtqzagjVQCAWPBGzhCHs2sPTy/VruGFm HSjEvYocou73NixpKemfeRt0J4ZilKftSUGrBDlVhjSF32VILCfA7fUgahLpahtf4bm5F8 5HSvj0At6q6H/v1rtmXYXN+w2EQ3Z2Kj5+zl1LzwbxpQtyY7P+nm05BUoZyjP80uo5dHqy Ny39o9LaWDvrGVrSaTNLYpnuqlXulA3i0Ny6SFdbBf7j9CcXFayJDq3/rvbKTA== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1594223895; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=hBBgGGCt/li9DGockH9AHi0xKPYeo4iYHq8uBfnLO+E=; b=5iglhEsWyiEC377p8t3Lp5pHhU7L32NfzceoswF8C7tsnnJgnq8u9BmKvBAjPmuz1yXvXA Sy6+y4kEu/Mh2dCw== From: "Ahmed S. Darwish" To: Peter Zijlstra Cc: Ingo Molnar , Will Deacon , Thomas Gleixner , "Paul E. McKenney" , "Sebastian A. Siewior" , Steven Rostedt , LKML Subject: Re: [PATCH v3 06/20] seqlock: Extend seqcount API with associated locks Message-ID: <20200708155813.GA147953@debian-buster-darwi.lab.linutronix.de> References: <20200630054452.3675847-1-a.darwish@linutronix.de> <20200630054452.3675847-7-a.darwish@linutronix.de> <20200706212148.GE5523@worktop.programming.kicks-ass.net> <20200707084024.GA4097637@debian-buster-darwi.lab.linutronix.de> <20200707130410.GO4800@hirez.programming.kicks-ass.net> <20200707143726.GO117543@hirez.programming.kicks-ass.net> <20200708103314.GB4151780@debian-buster-darwi.lab.linutronix.de> <20200708122938.GQ4800@hirez.programming.kicks-ass.net> <20200708150930.GA147323@debian-buster-darwi.lab.linutronix.de> <20200708153522.GR4800@hirez.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200708153522.GR4800@hirez.programming.kicks-ass.net> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jul 08, 2020 at 05:35:22PM +0200, Peter Zijlstra wrote: ... > > And while the gcc-4.8 code is horrendous crap, the rest should be pretty > straight forward and concentrates on the pieces where there are > differences. > Is there any possibility of upgrading the minimum gcc version to 4.9? Is there any supported architecture that is still stuck on 4.8? ... > I even considered: > > #define __SEQPROP(name, prop, expr) \ > static __always_inline __seqprop_##prop##_t \ > __seqprop##name##_##prop(seqcount##name##_t *s) \ > { \ > expr; \ > } > > Such that we could write: > > __SEQPROP(, ptr, return s) > __SEQPROP(, preempt, return false) > __SEQPROP(, assert, ) > > __SEQPROP(_##locktype, ptr, return &s->seqcount) \ > __SEQPROP(_##locktype, preempt, return preempt) \ > __SEQPROP(_##locktype, assert, __SEQCOUNT_LOCKDEP(lockdep_assert_held(s->lockmember))) \ > > But I figured _that_ might've been one step too far ;-) Initially I implemented something like this during internal, pre-upstream, versions of this patch series. We've decided afterwards that the macro compression level is so high that the whole thing is not so easily understandable. Thanks, -- Ahmed S. Darwish Linutronix GmbH