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=-2.3 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 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 73B83C4360C for ; Sat, 12 Oct 2019 10:21:32 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 3FC7C2087E for ; Sat, 12 Oct 2019 10:21:32 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=gmx.net header.i=@gmx.net header.b="SSmm4n4E" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728940AbfJLKVN (ORCPT ); Sat, 12 Oct 2019 06:21:13 -0400 Received: from mout.gmx.net ([212.227.17.22]:50579 "EHLO mout.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726555AbfJLKVM (ORCPT ); Sat, 12 Oct 2019 06:21:12 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1570875346; bh=9yiK8dnG219CaruOwHyidlZwNGKUyzDo3y7vSy6Xm+w=; h=X-UI-Sender-Class:Subject:To:Cc:References:From:Date:In-Reply-To; b=SSmm4n4E1YOoH8/09Mupot5T4KQ1hfoUjsgffqCF3wlIgLO86ZFn73VjpMVF2ad67 nsPAGCMbilg9NTSfZgyWmhCPlAntHDrrseTJc2bjHAz3mp1mbTK1+HQn+QjI2MB9f3 EgR/79TeswaxeCGF7GoWy4DHgFPIU/nG7jBtXKGs= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from [192.168.1.162] ([37.4.249.112]) by mail.gmx.com (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MQMyf-1if2Xb0z9l-00MHaq; Sat, 12 Oct 2019 12:15:46 +0200 Subject: Re: [PATCH] compiler: enable CONFIG_OPTIMIZE_INLINING forcibly To: Will Deacon , Linus Torvalds Cc: Geert Uytterhoeven , Nick Desaulniers , Russell King - ARM Linux admin , Masahiro Yamada , Nicolas Saenz Julienne , Andrew Morton , Ingo Molnar , Borislav Petkov , Miguel Ojeda , linux-arch , LKML , Catalin Marinas , Kees Cook , Arnd Bergmann , clang-built-linux References: <20191001092823.z4zhlbwvtwnlotwc@willie-the-truck> <20191001170142.x66orounxuln7zs3@willie-the-truck> <20191001175512.GK25745@shell.armlinux.org.uk> <20191001181438.GL25745@shell.armlinux.org.uk> <20191003163606.iqzcxvghaw7hdqb5@willie-the-truck> From: Stefan Wahren Message-ID: <35643c7e-94e9-e410-543b-a7de17b59a32@gmx.net> Date: Sat, 12 Oct 2019 12:15:42 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.9.0 MIME-Version: 1.0 In-Reply-To: <20191003163606.iqzcxvghaw7hdqb5@willie-the-truck> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Content-Language: en-US X-Provags-ID: V03:K1:iNPi0emfRc2oUZROqqK4veOxMGlI1mxOV8QIg+mTL89EDO4EH7+ 2lPiQqrhfyLQf3Vg7Nx2BonaDOVup6w6ynu05PFl4ZaypAEedCbmvWH/e0gaOPDqtB12rE0 scCifOpESngb1/ghKnIoQ7qmU2S/fCwI+DV8bqUvbiMV16JH+HdFb3Y8KCPac6jdrjFKUTi aEhBSH51ecKaJn9oRDSDA== X-UI-Out-Filterresults: notjunk:1;V03:K0:k56ojK+HK+c=:YYXDWCMArL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B8RZIDRN4j0wXdjS3oLj0Nh6+psRA9NW/XUBoo7f8k54 DLECtGLWTFBTDUgqSNYwbgK22G+x6jrPmzxVEWl3shvusvQ3p+wLgEoE7Q9N40xJo4Z5FBv/5 Lx/jJBMkpP8cGQEkXNjIHNI0XvRCSzAGA37GVTeeoQ/lu3OZ0sfm38qQsIBPAuUpdtv6H8bNF EGNi1EQC/OJXevzquoGPEByZ7wqgOXccV+P2DmJibaBVDBof5bLfdIP8dsfE= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, Am 03.10.19 um 18:36 schrieb Will Deacon: > On Wed, Oct 02, 2019 at 01:39:40PM -0700, Linus Torvalds wrote: >> On Wed, Oct 2, 2019 at 5:56 AM Geert Uytterhoeven wrote: >>>> Then use the C preprocessor to force the inlining. I'm sorry it's not >>>> as pretty as static inline functions. >>> Which makes us lose the baby^H^H^H^Htype checking performed >>> on function parameters, requiring to add more ugly checks. >> I'm 100% agreed on this. >> >> If the inline change is being pushed by people who say "you should >> have used macros instead if you wanted inlining", then I will just >> revert that stupid commit that is causing problems. >> >> No, the preprocessor is not the answer. >> >> That said, code that relies on inlining for _correctness_ should use >> "__always_inline" and possibly even have a comment about why. >> >> But I am considering just undoing commit 9012d011660e ("compiler: >> allow all arches to enable CONFIG_OPTIMIZE_INLINING") entirely. The >> advantages are questionable, and when the advantages are balanced >> against actual regressions and the arguments are "use macros", that >> just shows how badly thought out this was. > It's clear that opinions are divided on this issue, but you can add > an enthusiastic: > > Acked-by: Will Deacon > > if you go ahead with the revert. I'm all for allowing the compiler to > make its own inlining decisions, but not when the potential for > miscompilation isn't fully understood and the proposed alternatives turn > the source into an unreadable mess. Perhaps we can do something different > for 5.5 (arch opt-in? clang only? invert the logic? work to move functions > over to __always_inline /before/ flipping the CONFIG option? ...?) what's the status on this? In need to prepare my pull requests for 5.5 and all recent kernelci targets (including linux-next) with bcm2835_defconfig are still broken. Stefan > > Will