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=-3.8 required=3.0 tests=BAYES_00, 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 8392FC49EA2 for ; Tue, 22 Jun 2021 09:29:50 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 72A97608FC for ; Tue, 22 Jun 2021 09:29:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229940AbhFVJcE (ORCPT ); Tue, 22 Jun 2021 05:32:04 -0400 Received: from foss.arm.com ([217.140.110.172]:45192 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229490AbhFVJcD (ORCPT ); Tue, 22 Jun 2021 05:32:03 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 6DFD46D; Tue, 22 Jun 2021 02:29:47 -0700 (PDT) Received: from C02TD0UTHF1T.local (unknown [10.57.10.229]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 9C2B03F718; Tue, 22 Jun 2021 02:29:40 -0700 (PDT) Date: Tue, 22 Jun 2021 10:29:37 +0100 From: Mark Rutland To: Catalin Marinas Cc: Nick Desaulniers , Bill Wendling , Masahiro Yamada , Will Deacon , Ard Biesheuvel , Heiko Carstens , Vasily Gorbik , Christian Borntraeger , Peter Oberparleiter , Kees Cook , Peter Zijlstra , Bill Wendling , Sami Tolvanen , Miguel Ojeda , Nathan Chancellor , Luc Van Oostenryck , Arnd Bergmann , Andrew Morton , Rasmus Villemoes , LKML , clang-built-linux , "maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT)" , Borislav Petkov , Martin Liska , Jonathan Corbet , Fangrui Song , Linux Doc Mailing List , Linux Kbuild mailing list , Dmitry Vyukov , Johannes Berg , linux-toolchains@vger.kernel.org, Marco Elver , Linux ARM , linux-s390 Subject: Re: [PATCH 2/2] Kconfig: CC_HAS_NO_PROFILE_FN_ATTR, depend on for GCOV and PGO Message-ID: <20210622092937.GB67232@C02TD0UTHF1T.local> References: <20210618233023.1360185-1-ndesaulniers@google.com> <20210618233023.1360185-3-ndesaulniers@google.com> <20210622092533.GB3555@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210622092533.GB3555@arm.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 22, 2021 at 10:25:34AM +0100, Catalin Marinas wrote: > On Mon, Jun 21, 2021 at 01:43:54PM -0700, Nick Desaulniers wrote: > > We need to be able to express via Kconfig "GCOV should not be enabled > > for architectures that use noinstr when the toolchain does not support > > __attribute__((no_profile_instrument_function))." > > > > Where "architectures that use noinstr" are currently arm64, s390, and > > x86. So I guess we could do: > > > > + depends on !ARM64 || !S390 || !X86 || CC_HAS_NO_PROFILE_FN_ATTR > > I think you want: > > depends on !(ARM64 || S390 || X86) || CC_HAS_NO_PROFILE_FN_ATTR > > > (We could add a Kconfig for ARCH_WANTS_NO_INSTR, which might be more > > informative than listed out architectures which might be non-obvious > > to passers-by). > > That would probably look better. It does; see: https://lore.kernel.org/r/20210621231822.2848305-1-ndesaulniers@google.com :) Thanks, Mark.