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 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 80AECC43332 for ; Wed, 17 Mar 2021 13:57:06 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 5154A64F6E for ; Wed, 17 Mar 2021 13:57:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231461AbhCQN4f (ORCPT ); Wed, 17 Mar 2021 09:56:35 -0400 Received: from casper.infradead.org ([90.155.50.34]:36766 "EHLO casper.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231431AbhCQNz4 (ORCPT ); Wed, 17 Mar 2021 09:55:56 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; 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=oyq8/UTMFX2svFvS7h/tZWSi3AUrFmAIgDYpVCoWS2E=; b=N/IEnLA769w9TNWclakM6RqUMR HcAAdGZhNTFVNs7UzlrW9lJIHpnPXto612S7aK/m0d7rM81pZzw1SplZNyEgANmAkHsl/B8WRuDfS /cVa1bYt4Up0nWnHIo6y3VjSDDQRDeX93OZU7IY9O0Xp9hm9a8ik77QC+Poktwi6yo2ezQH6dVwdp SnNCZljBChz8XkUnfe0//1wGAOWdmd6rmwzGQVwNVhx62uTxPVnzEClkXfoDL2hwkHLPN1j+uJhUk tJXvcz+7I1Gq4hwReFP7I1h+FQ1+tzIpEMp2NVLAOsFAd1fPUkn6T6/MA792tfpo9OlizqgDytFls WWs/doJQ==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=noisy.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.94 #2 (Red Hat Linux)) id 1lMWe8-001X8Q-Ob; Wed, 17 Mar 2021 13:55:39 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 60596300130; Wed, 17 Mar 2021 14:55:36 +0100 (CET) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 565C620781083; Wed, 17 Mar 2021 14:55:36 +0100 (CET) Date: Wed, 17 Mar 2021 14:55:36 +0100 From: Peter Zijlstra To: Waiman Long Cc: linux-kernel@vger.kernel.org, linux-tip-commits@vger.kernel.org, Ingo Molnar , Davidlohr Bueso , x86@kernel.org Subject: Re: [tip: locking/urgent] locking/ww_mutex: Simplify use_ww_ctx & ww_ctx handling Message-ID: References: <20210316153119.13802-2-longman@redhat.com> <161598470257.398.5006518584847290113.tip-bot2@tip-bot2> <85fbce04-c544-6041-6e7d-76f47b90e263@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <85fbce04-c544-6041-6e7d-76f47b90e263@redhat.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Mar 17, 2021 at 09:43:20AM -0400, Waiman Long wrote: > Using gcc 8.4.1, the generated __mutex_lock function has the same size (with > last instruction at offset +5179) with or without this patch. Well, you can > say that this patch is an no-op wrt generated code. OK, then GCC has gotten better. Because back then I tried really hard but it wouldn't remove the if (ww_ctx) branches unless I had that extra const bool argument.