Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp616377pxb; Thu, 15 Apr 2021 02:26:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyMLBfkMZmiGYz9Wg3iuUB9ytgGddQ0e2NmjhabP5idUhcXIua9zuJFm6Igy97uSX31xe1J X-Received: by 2002:a17:906:170d:: with SMTP id c13mr2371037eje.491.1618478804777; Thu, 15 Apr 2021 02:26:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618478804; cv=none; d=google.com; s=arc-20160816; b=xgKxH7IAN1Wkc+WEbEjzFC2mVwj3y9PGbE02imUXNrGMNW3JtQyTsdpGgIdxCekCZP By0MnO2LRMqkvm8TNI1ScWMRi6Nxh6PiwfcimI8tS/TBucy9CaAQcGSwosc+7sQB9NLu jCGjD7nWSbdCUdKx35X1hHlAImKUsrb1svjSlmigd5/L+9Nl172rGZeOenMeSidAZlhR wEP2AQqFnIt2NYL6vsON9A72QcPRNkr5NmzY4ahUhYUbzlOHCsp5jYaV8KxhPfoinPqT 9V8FXsRFfTkxx5V9GCXEQd9FdWfyWXFjEMUqjLPEDo8LLghHHCgwtoR6+KL0gYbrdUHH yJig== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=Jh/Z5CsbLDJ2dUT0D1FkWWjNfW/phW/5c5MUZ/JUzbg=; b=GKjKgNRisrMfYQWhPqWVbP9U2QNvg8VG1LHUOERvFipQ1E3f9zZFAmB+oRxOx0/EED rsgkv4H1FJa41O1JnFMyOxFYDjlX0lylZxjWxMn3BRvSu7z/J4C6BWxTFj5uLvGcISic 6Lm2KUF0pf9+EsZcPFKhv8B71KGdp5vKZOgO+mBKbakRoBGqhJTVHQVXd6HpQmc/jfiY QediapyH5O69IvtsMnBEFeZ0iQo+PFXEP74cm3P6iVYpJh1RbUvYcWeQWk6qe7WviiT7 aSsA0xtm+mpwWeY/khfuZ27b0mOxjSWUi77qUtndluPP6+pHMzUl8nJjW9wK4WE5L//j zkCA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=cDY0sm51; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h18si1900437eds.422.2021.04.15.02.26.16; Thu, 15 Apr 2021 02:26:44 -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=@infradead.org header.s=desiato.20200630 header.b=cDY0sm51; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231610AbhDOJZQ (ORCPT + 99 others); Thu, 15 Apr 2021 05:25:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55868 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229820AbhDOJZP (ORCPT ); Thu, 15 Apr 2021 05:25:15 -0400 Received: from desiato.infradead.org (desiato.infradead.org [IPv6:2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6DEE7C061574 for ; Thu, 15 Apr 2021 02:24:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=Jh/Z5CsbLDJ2dUT0D1FkWWjNfW/phW/5c5MUZ/JUzbg=; b=cDY0sm51fhBJRR6G9i2mGcml2O W2RDobY5wE7VwT8Ddao16wlAOeiErRp7CTi5iDFWw5AGIGtnehByPJCJMhEGbFnnPE1dpCo7NrrXb rdAyfEZGhmMjpasWmKKEn9yRGxoR7Yh/Kc3K5yvwFrEGbGpc60KKjKscKowfaFuJ2RrQ3LerXXldL c72etaYasPgMqKXHWJrXg80p2QuNb7IU8FnAt26OeyNAbCdP107hkuyUT8SH24vCeaPHGi2nQgX0B KDOC4/6xrL/Tji8+5ZjIpVIiGIMzAHqfmBIkVEydHzj3LYCYKnZVeJVoDfBV371SUmwUYqzCAhNGV /WPX/Atg==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=noisy.programming.kicks-ass.net) by desiato.infradead.org with esmtpsa (Exim 4.94 #2 (Red Hat Linux)) id 1lWyEs-00FVmx-VT; Thu, 15 Apr 2021 09:24:43 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 344C2300209; Thu, 15 Apr 2021 11:24:42 +0200 (CEST) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id E6C982022421A; Thu, 15 Apr 2021 11:24:41 +0200 (CEST) Date: Thu, 15 Apr 2021 11:24:41 +0200 From: Peter Zijlstra To: Catalin Marinas Cc: Stafford Horne , Guo Ren , Christoph =?iso-8859-1?Q?M=FCllner?= , Palmer Dabbelt , Anup Patel , linux-riscv , Linux Kernel Mailing List , Guo Ren , Will Deacon , Arnd Bergmann , jonas@southpole.se, stefan.kristiansson@saunalahti.fi Subject: Re: [RFC][PATCH] locking: Generic ticket-lock Message-ID: References: <20210414204734.GJ3288043@lianli.shorne-pla.net> <20210415090215.GA1015@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210415090215.GA1015@arm.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 15, 2021 at 10:02:18AM +0100, Catalin Marinas wrote: > IIRC, one issue we had with ticket spinlocks on arm64 was on big.LITTLE > systems where the little CPUs were always last to get a ticket when > racing with the big cores. That was with load/store exclusives (LR/SC > style) and would have probably got better with atomics but we moved to > qspinlocks eventually (the Juno board didn't have atomics). That sounds like a fundamental LL/SC fail, and I'm not sure qspinlock will help with that at all. The big cores can still hog the lock word and starve the little ones. And those things not having AMOs there's really not much you can do. You want the big cores to back off, but they're having success, not failure. I suppose you can add a delay after a successful LL/SC, but that sucks. I suppose modern big.little things will have AMOs, so maybe nobody still cares about those systems.