Received: by 2002:a05:6358:c692:b0:131:369:b2a3 with SMTP id fe18csp946909rwb; Fri, 28 Jul 2023 02:15:09 -0700 (PDT) X-Google-Smtp-Source: APBJJlGCqPAjIcnA0CRIoQDlvVgMhBBrvXTqX24MfD187DZY2TxI6i8xXyXX1sFSvD737BGzkqSF X-Received: by 2002:a17:906:779d:b0:99b:5085:42a2 with SMTP id s29-20020a170906779d00b0099b508542a2mr1908513ejm.40.1690535708773; Fri, 28 Jul 2023 02:15:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690535708; cv=none; d=google.com; s=arc-20160816; b=LIbhhOTjOrjhZXvA0B4C0XZi+BjsmQ8tubRAxYuGK+uS8cxENrppbap2lzkLVFaq+N Tf7HGdzPyExfXRvpGxP6L/lrNuFu9aqJawKhQPi3dZo+Qmr7/Kw8H5TJZq11uclXpBx9 DizJCtqPHWzvsqipvt25BZcaWurVOx7PBe+LZAtiF2qn/smFXIgcOemxVt4HrNjHCnIQ vq1ZQz5SoF7RLDydG5L2KOfMFPjiJ0Kwq0MF8zQ+lfsESfeylGyHEJsHLo+/bCjwSteb Nf0BgXLq3TDwnlHyc1Q1mIAVNRDsUvGC8AEDGP33gxZQySFEIdS/zzMmQBochEKTsz6B 19lw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from:cc :references:to:content-language:subject:user-agent:mime-version:date :message-id; bh=ngSWm2Mq2Am2Rm4OFfWEJJkmX912C7uopqduYOYSLBA=; fh=IV2eg7m2u5JQ7fqTLeIvC5s8kjpEmjr80Fgc1Cpu4Zk=; b=SP3yADRQreZAlX+WbNV6YTvidTg3r4GDWcZmGtrCnDqU24cJ/BW+PhQNpPuL9cyR+2 sUplVMrpNIoq8goDdoAs3TL2/XBu8ZMAKOcJL0zjxl4Sa4YqhxXSF9m5Oigq809v1Jrh j2wI5j2nY81F79FeT/FoWrVLhT1c7QMVg1axMRaaYRms3gIE4MM6UZr3QIW2bLwsu2b5 bCHM/SRSJOOqo3mtE1dF3T6f7BkZhiDDoQrYHM6ONRFnqgQ4Y3gYwWJSxsMcqaL7Gfex iM0/71wnLbmZ6Fwvs8erBvGYJQxKblLA1jYXOI6t8PMLAFX+IB281unWIz2weUHQMQZj BzOA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id cf15-20020a170906b2cf00b009930ef7f05dsi2520421ejb.908.2023.07.28.02.14.36; Fri, 28 Jul 2023 02:15:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234392AbjG1I5E (ORCPT + 99 others); Fri, 28 Jul 2023 04:57:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49118 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234095AbjG1I4t (ORCPT ); Fri, 28 Jul 2023 04:56:49 -0400 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 7E36E3A9B; Fri, 28 Jul 2023 01:56:48 -0700 (PDT) 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 43993D75; Fri, 28 Jul 2023 01:57:31 -0700 (PDT) Received: from [10.57.0.116] (unknown [10.57.0.116]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 271683F67D; Fri, 28 Jul 2023 01:56:45 -0700 (PDT) Message-ID: Date: Fri, 28 Jul 2023 09:56:43 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.9.0 Subject: Re: [PATCH v1 2/6] perf build: Don't always set -funwind-tables and -ggdb3 Content-Language: en-US To: Ian Rogers References: <20230728064917.767761-1-irogers@google.com> <20230728064917.767761-3-irogers@google.com> Cc: Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Jiri Olsa , Namhyung Kim , Adrian Hunter , Nathan Chancellor , Nick Desaulniers , Tom Rix , Kan Liang , Eduard Zingerman , Andrii Nakryiko , Gaosheng Cui , Rob Herring , linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org, bpf@vger.kernel.org, llvm@lists.linux.dev From: James Clark In-Reply-To: <20230728064917.767761-3-irogers@google.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.3 required=5.0 tests=BAYES_00,NICE_REPLY_A, RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 28/07/2023 07:49, Ian Rogers wrote: > Commit 6a40cd90f5de ("perf tools: Add libunwind dependency for DWARF > CFI unwinding") added libunwind support but also -funwind-tables and > -ggdb3 to the standard build. These build flags aren't necessary so > remove, set -g when DEBUG is enabled for the build. > > Signed-off-by: Ian Rogers > --- > tools/perf/Makefile.config | 7 +++---- > 1 file changed, 3 insertions(+), 4 deletions(-) > > diff --git a/tools/perf/Makefile.config b/tools/perf/Makefile.config > index a9cfe83638a9..14709a6bd622 100644 > --- a/tools/perf/Makefile.config > +++ b/tools/perf/Makefile.config > @@ -246,6 +246,9 @@ ifeq ($(CC_NO_CLANG), 0) > else > CORE_CFLAGS += -O6 > endif > +else > + CORE_CFLAGS += -g > + CXXFLAGS += -g > endif > > ifdef PARSER_DEBUG > @@ -324,8 +327,6 @@ FEATURE_CHECK_LDFLAGS-disassembler-four-args = -lbfd -lopcodes -ldl > FEATURE_CHECK_LDFLAGS-disassembler-init-styled = -lbfd -lopcodes -ldl > > CORE_CFLAGS += -fno-omit-frame-pointer > -CORE_CFLAGS += -ggdb3 > -CORE_CFLAGS += -funwind-tables > CORE_CFLAGS += -Wall > CORE_CFLAGS += -Wextra > CORE_CFLAGS += -std=gnu11 > @@ -333,8 +334,6 @@ CORE_CFLAGS += -std=gnu11 > CXXFLAGS += -std=gnu++14 -fno-exceptions -fno-rtti > CXXFLAGS += -Wall > CXXFLAGS += -fno-omit-frame-pointer > -CXXFLAGS += -ggdb3 > -CXXFLAGS += -funwind-tables > CXXFLAGS += -Wno-strict-aliasing > > HOSTCFLAGS += -Wall Acked-by: James Clark