Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp615641rdh; Thu, 23 Nov 2023 13:15:29 -0800 (PST) X-Google-Smtp-Source: AGHT+IHwzqRDoDMv3S5A/ntIdJvTtJPWD6GnHQLcYQA9yqV+JMdDQL/8Mm/iLY021NN1gdjK2894 X-Received: by 2002:a05:6808:f08:b0:3a7:5557:16c2 with SMTP id m8-20020a0568080f0800b003a7555716c2mr784354oiw.0.1700774128932; Thu, 23 Nov 2023 13:15:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700774128; cv=none; d=google.com; s=arc-20160816; b=Rbe35IPyMf0JH08pNP+mvU0hIeAOOGf+syUShK7n9aCXMCVGvjChanCOSAMpH5lDc2 CgUHa/43y78EdIZqCSpcMTta5fLrm4Sg4BZqqdes9jKZhiIv9wr+OmMM8H4owJD4tvt3 jJdam2jg3wYCmriEMK3sPF7ij1/wwUCNMM1k+ho0XEWDbo8jMwMPlW9v0HLZ07UjAV2x APuEwRSzSj9dFFtZhnGdv421+FCfLAzUA7+TAjPrLUt4fhdIabfttKlmBQa0Tsl5wFnI kctCwzzpwZafzzTxQSafZqQYYaC9BYOLdyL7E4Y54/jkDWC9nynZ3OfHnTORRxdApXsW dgvQ== 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=y3M3fQ/4++kZU0DSTp2SrLMQVr2wCxnIiOxpofn5abw=; fh=vhwA6XT+9ncfUd7yctAL0YPGkntv4GVUHLux6DIUkWk=; b=n+g/rj9k+BIiP9ZLvU/T0Odo9RDuP0upRhgxqpQnnfoRUXcPNbhFyDySbYn3hH3zl3 gwX+IbvrQdiOlqX/5MZl5k2hbTADlCeAlQQ+xP+/JCMghf2cowPNR5ctdHb+7QS7h+mS rfiEgAPg06OK/ZEF8h2YpNiLbBMsCKcJ6gJSBzEv875ThYuRIKu75a1TzlhOP+H6aSfC pgixC5EkxvPrHb7rLNCq9ASJmlaye3Gi1zkMwHve7OT5JTvKuEhXYMnuX0KogRgmSeeQ tANmfnYt19M3oQnI10cgEMChPF7V2p7ZRCAdBFgAzvm6OsdYzIzozw1vdNAcRG8tV5Hj 1hIg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=IYWXp6jw; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from howler.vger.email (howler.vger.email. [2620:137:e000::3:4]) by mx.google.com with ESMTPS id y35-20020a631823000000b005893b7094easi1981024pgl.554.2023.11.23.13.15.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Nov 2023 13:15:28 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) client-ip=2620:137:e000::3:4; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=IYWXp6jw; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id D24D38092905; Thu, 23 Nov 2023 13:15:23 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229478AbjKWVPH (ORCPT + 99 others); Thu, 23 Nov 2023 16:15:07 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48654 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229453AbjKWVPG (ORCPT ); Thu, 23 Nov 2023 16:15:06 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1B8481A5 for ; Thu, 23 Nov 2023 13:15:13 -0800 (PST) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 74259C433C7; Thu, 23 Nov 2023 21:15:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1700774112; bh=tPDvNTF6lQgs9PwbaY+2NnDjcoV4Bkdql130mx3he5M=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=IYWXp6jws2n5+lhs66eOrghIpdRqwujIZ0d1v0m7OuQbWAkGnFzuAOJDAIy+C4L1a vVU9MhIPf9NzkYY0F0p+lMXkbG2ZIhtjIllki7jNYch4MKxKNU0CMiHgcPALLL/ds/ 1K4AViDU/I3YVTaJiLo5SZFx8CzDtYEQ6kDuWQMxUQzc4rsGGh5B/GR4hlB9ZDD2RT mN8kxB5/ANc1tCpPXYb0CF8A63knqKpHYpCgKeU95fgo0kRgDrtzhi4l3FAYoXlKAu H65qQOtV14MHk1VZ5ZZrcpkXjQCTm3BqII/mAIamf6txGQHjJSCXebQFsLAv9p4HeX 5FG6Ri7FNdlaQ== Received: by quaco.ghostprotocols.net (Postfix, from userid 1000) id E6BC540094; Thu, 23 Nov 2023 18:15:09 -0300 (-03) Date: Thu, 23 Nov 2023 18:15:09 -0300 From: Arnaldo Carvalho de Melo To: Hector Martin Cc: Mark Rutland , Ian Rogers , Marc Zyngier , Namhyung Kim , Peter Zijlstra , Ingo Molnar , Alexander Shishkin , Jiri Olsa , Adrian Hunter , Kan Liang , James Clark , linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [RFC PATCH v1] perf parse-events: Make legacy events lower priority than sysfs/json Message-ID: References: <20231123042922.834425-1-irogers@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Url: http://acmel.wordpress.com X-Spam-Status: No, score=-1.3 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, NUMERIC_HTTP_ADDR,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on howler.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Thu, 23 Nov 2023 13:15:24 -0800 (PST) Em Thu, Nov 23, 2023 at 11:18:22AM -0300, Arnaldo Carvalho de Melo escreveu: > Em Thu, Nov 23, 2023 at 05:45:19PM +0900, Hector Martin escreveu: > > On 2023/11/23 13:29, Ian Rogers wrote: > > > The bulk of this change is updating all of the parse-events test > > > expectations so that if a sysfs/json event exists for a PMU the test > > > doesn't fail - a further sign, if it were needed, that the legacy > > > event priority was a known and tested behavior of the perf tool. > > > > Signed-off-by: Ian Rogers > > > --- > > > This is a large behavioral change: > > > 1) the scope of the change means it should bake on linux-next and I > > > don't believe should be a 6.7-rc fix. > > > 2) a fixes tag and stable backport I don't think are appropriate. The > > > real reported issue is with the PMU driver. A backport would bring the > > > risk that later fixes, due to the large behavior change, wouldn't be > > > backported and past releases get regressed in scenarios like > > > hybrid. Backports for the perf tool are also less necessary than say a > > > buggy PMU driver, as distributions should be updating to the latest > > > perf tool regardless of what Linux kernel is being run (the perf tool > > > is backward compatible). > > > > Tested-by: Hector Martin > > Thanks, applied locally, doing some tests and then will push for > linux-next to pick it up. > > Mark, can I have your Reviewed-by or Acked-by? I'll collect those, but only after addressing these: [perfbuilder@five ~]$ export BUILD_TARBALL=http://192.168.86.5/perf/perf-6.6.0-rc1.tar.xz [perfbuilder@five ~]$ time dm 1 100.09 almalinux:8 : FAIL clang version 15.0.7 (Red Hat 15.0.7-1.module_el8.8.0+3466+dfcbc058) util/parse-events.c:1461:6: error: variable 'alias_rewrote_terms' is used uninitialized whenever '&&' condition is false [-Werror,-Wsometimes-uninitialized] if (!parse_state->fake_pmu && perf_pmu__check_alias(pmu, &parsed_terms, ^~~~~~~~~~~~~~~~~~~~~~ util/parse-events.c:1477:6: note: uninitialized use occurs here if (alias_rewrote_terms && ^~~~~~~~~~~~~~~~~~~ util/parse-events.c:1461:6: note: remove the '&&' if its condition is always true if (!parse_state->fake_pmu && perf_pmu__check_alias(pmu, &parsed_terms, ^~~~~~~~~~~~~~~~~~~~~~~~~ util/parse-events.c:1401:26: note: initialize the variable 'alias_rewrote_terms' to silence this warning bool alias_rewrote_terms; ^ = false 1 error generated. make[3]: *** [/git/perf-6.6.0-rc1/tools/build/Makefile.build:158: util] Error 2 2 114.29 almalinux:9 : FAIL clang version 15.0.7 (Red Hat 15.0.7-2.el9) util/parse-events.c:1461:6: error: variable 'alias_rewrote_terms' is used uninitialized whenever '&&' condition is false [-Werror,-Wsometimes-uninitialized] if (!parse_state->fake_pmu && perf_pmu__check_alias(pmu, &parsed_terms, ^~~~~~~~~~~~~~~~~~~~~~ util/parse-events.c:1477:6: note: uninitialized use occurs here if (alias_rewrote_terms && ^~~~~~~~~~~~~~~~~~~ util/parse-events.c:1461:6: note: remove the '&&' if its condition is always true if (!parse_state->fake_pmu && perf_pmu__check_alias(pmu, &parsed_terms, ^~~~~~~~~~~~~~~~~~~~~~~~~ util/parse-events.c:1401:26: note: initialize the variable 'alias_rewrote_terms' to silence this warning bool alias_rewrote_terms; ^ = false 1 error generated. make[3]: *** [/git/perf-6.6.0-rc1/tools/build/Makefile.build:158: util] Error 2