Message ID | 20230524221831.1741381-23-irogers@google.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id BBD87C7EE31 for <linux-arm-kernel@archiver.kernel.org>; Wed, 24 May 2023 23:20:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:To:From:Subject:References:Mime-Version :Message-Id:In-Reply-To:Date:Reply-To:Cc:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=EvQrG/ODxAXTlclmKZMnv6iKYhkOdDfyCiTFQj2DCOE=; b=0mr1EduLeOviTQ DlbPMYHr/svaCqG3SfhoyIXOs1/DvXc9ZEkxLTkJUlColNj8s98d1E2F5FghPvdrMc+vju0vC2zsm Wmmkpf+At9MG4FhmZ7DhN2ryFCF90QEyXfw/8qfsEmD4l+vAqo86vwrJsFk3imGtOUaddcaxXqOIE BpYUWUTQY57Mpf6ZmCvNPOtJEEkIS9OKtpX7+j3TBrDCpJlhyksCrAAapTTHtCxEUO7aDyd5r9kL1 THvAVfKUgTz43W4cEUXWNhVr9leQBMIEqcJb+vhrwYeGT5AptG9pMv88Sm5vgM/0LHsCtXRW1GxZC D6JiTqnjDTgqKwz6f1rg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1q1xmK-00EvCs-1q; Wed, 24 May 2023 23:20:24 +0000 Received: from mail-yb1-xb49.google.com ([2607:f8b0:4864:20::b49]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1q1wpK-00Emx8-3D for linux-arm-kernel@lists.infradead.org; Wed, 24 May 2023 22:19:28 +0000 Received: by mail-yb1-xb49.google.com with SMTP id 3f1490d57ef6-ba8696637a7so3150542276.3 for <linux-arm-kernel@lists.infradead.org>; Wed, 24 May 2023 15:19:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20221208; t=1684966765; x=1687558765; h=to:from:subject:references:mime-version:message-id:in-reply-to:date :from:to:cc:subject:date:message-id:reply-to; bh=LP27CftfdHYnLweWt0lX22v4lNIGIpmQh1ljDLrV4jA=; b=lYADs1VbYR/2zJtQXymNcu0XOzeLjuk2kW8pz8OEiHhfvUHQJh2Atn4PtH+6mAx8FM iYs86lOXb4OVWuHjuhHOXgtWOs9oKpr9ezh6cskrIOHTv/UssX/i7dMlopbgunerspC7 h2/ymCj6IQ/Lrk9hfyUloxKOsD5s3zG0Iygd+8lhERAnPDD8++D5i7HBtkpxEJ4iC1rg vNCLff8bwWgFpYXRO1lDLFJ/rNciZmDSrji6mjomGnYqBHisbvWLkfnYTBqQ+3K5Naa0 Cvf9AHBTpz+hi/c1c3jRw2tjeSUq3nv8Qm25Ek5YlVHftKpKiDk4+oTPtNBHD0srlDeB Maig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684966765; x=1687558765; h=to:from:subject:references:mime-version:message-id:in-reply-to:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=LP27CftfdHYnLweWt0lX22v4lNIGIpmQh1ljDLrV4jA=; b=lZIVbLWrigvMxkYg5QAyiFC9VNwpJ6QwuCJ/0xwaefJoOgL/yoL/JN5pKvTq/Dd5nl fXmwUPVrYgrFFS0BDfNplRnm9NMWrwrZkzIPXqSVq4P6moHfHjdZrog7/aw+1Amj61tK NRWIR6gj4G52WJdE/VBG83LL9l+yyH7q1I3GF3KeMUrpOqnLD992jKg8nNKdlF6B53ZY bxBVAK8nucf1EoHpCeJqPutE2YUquCqsksxr+MZZsib5FWAc365tx72M7JraRrfvZ67w qHy983EyqtlHzVH5Jm6jC2U+JBU0JOMC/iF0RMYGSK/VxNaTbSZEQfXYKLIFT6GBILSM Yn/A== X-Gm-Message-State: AC+VfDwjNxCgg/5G2pRyWNxaiy5ump+N6aA6wBdXOaHffvnX+jbLLMjQ BWrg4B4LZrrD6xYOaNOFJGSctt9d+3IQ X-Google-Smtp-Source: ACHHUZ665i5nk9ovpEFzjxU1ohjxl63X2v7RPNE5lzH+XoYby7ipz6hZU7xMBGBWZkIBZfe03YbJ3muJ6Bn0 X-Received: from irogers.svl.corp.google.com ([2620:15c:2d4:203:7aa7:3d2d:76ae:8e96]) (user=irogers job=sendgmr) by 2002:a5b:b45:0:b0:ba8:939b:6574 with SMTP id b5-20020a5b0b45000000b00ba8939b6574mr756838ybr.12.1684966765640; Wed, 24 May 2023 15:19:25 -0700 (PDT) Date: Wed, 24 May 2023 15:18:18 -0700 In-Reply-To: <20230524221831.1741381-1-irogers@google.com> Message-Id: <20230524221831.1741381-23-irogers@google.com> Mime-Version: 1.0 References: <20230524221831.1741381-1-irogers@google.com> X-Mailer: git-send-email 2.40.1.698.g37aff9b760-goog Subject: [PATCH v3 22/35] perf metrics: Remove perf_pmu__is_hybrid use From: Ian Rogers <irogers@google.com> To: Suzuki K Poulose <suzuki.poulose@arm.com>, Mike Leach <mike.leach@linaro.org>, Leo Yan <leo.yan@linaro.org>, John Garry <john.g.garry@oracle.com>, Will Deacon <will@kernel.org>, James Clark <james.clark@arm.com>, Peter Zijlstra <peterz@infradead.org>, Ingo Molnar <mingo@redhat.com>, Arnaldo Carvalho de Melo <acme@kernel.org>, Mark Rutland <mark.rutland@arm.com>, Alexander Shishkin <alexander.shishkin@linux.intel.com>, Jiri Olsa <jolsa@kernel.org>, Namhyung Kim <namhyung@kernel.org>, Ian Rogers <irogers@google.com>, Adrian Hunter <adrian.hunter@intel.com>, Kajol Jain <kjain@linux.ibm.com>, Jing Zhang <renyu.zj@linux.alibaba.com>, Kan Liang <kan.liang@linux.intel.com>, Zhengjun Xing <zhengjun.xing@linux.intel.com>, Ravi Bangoria <ravi.bangoria@amd.com>, Madhavan Srinivasan <maddy@linux.ibm.com>, Athira Rajeev <atrajeev@linux.vnet.ibm.com>, Ming Wang <wangming01@loongson.cn>, Huacai Chen <chenhuacai@kernel.org>, Sandipan Das <sandipan.das@amd.com>, Dmitrii Dolgov <9erthalion6@gmail.com>, Sean Christopherson <seanjc@google.com>, Ali Saidi <alisaidi@amazon.com>, Rob Herring <robh@kernel.org>, Thomas Richter <tmricht@linux.ibm.com>, Kang Minchul <tegongkang@gmail.com>, linux-kernel@vger.kernel.org, coresight@lists.linaro.org, linux-arm-kernel@lists.infradead.org, linux-perf-users@vger.kernel.org X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230524_151927_033964_4570C48C X-CRM114-Status: GOOD ( 14.25 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: <linux-arm-kernel.lists.infradead.org> List-Unsubscribe: <http://lists.infradead.org/mailman/options/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=unsubscribe> List-Archive: <http://lists.infradead.org/pipermail/linux-arm-kernel/> List-Post: <mailto:linux-arm-kernel@lists.infradead.org> List-Help: <mailto:linux-arm-kernel-request@lists.infradead.org?subject=help> List-Subscribe: <http://lists.infradead.org/mailman/listinfo/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=subscribe> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" <linux-arm-kernel-bounces@lists.infradead.org> Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org |
Series |
PMU refactoring and improvements
|
expand
|
diff --git a/tools/perf/util/metricgroup.c b/tools/perf/util/metricgroup.c index 7de721e9d895..72583f62eda8 100644 --- a/tools/perf/util/metricgroup.c +++ b/tools/perf/util/metricgroup.c @@ -11,7 +11,6 @@ #include "evsel.h" #include "strbuf.h" #include "pmu.h" -#include "pmu-hybrid.h" #include "print-events.h" #include "smt.h" #include "expr.h" @@ -274,7 +273,7 @@ static int setup_metric_events(const char *pmu, struct hashmap *ids, const char *metric_id; struct evsel *ev; size_t ids_size, matched_events, i; - bool all_pmus = !strcmp(pmu, "all") || !perf_pmu__is_hybrid(pmu); + bool all_pmus = !strcmp(pmu, "all") || !perf_pmu__has_hybrid() || !is_pmu_hybrid(pmu); *out_metric_events = NULL; ids_size = hashmap__size(ids); @@ -288,8 +287,7 @@ static int setup_metric_events(const char *pmu, struct hashmap *ids, struct expr_id_data *val_ptr; /* Don't match events for the wrong hybrid PMU. */ - if (!all_pmus && ev->pmu_name && - perf_pmu__is_hybrid(ev->pmu_name) && + if (!all_pmus && ev->pmu_name && evsel__is_hybrid(ev) && strcmp(ev->pmu_name, pmu)) continue; /*
Switch from perf_pmu__is_hybrid to avoid implicitly using the hybrid PMU list. Signed-off-by: Ian Rogers <irogers@google.com> --- tools/perf/util/metricgroup.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)