Message ID | 20230524221831.1741381-24-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 CC828C77B7A for <linux-arm-kernel@archiver.kernel.org>; Wed, 24 May 2023 23:20:32 +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=HjvXpPDKDW6eMhDksb3Y1v8fvhf1cbU1dDXL5r0UlBA=; b=BZJ3p93caNi1b7 IwS7qaAjpOb43e94iar8r2zdm7OdYYrGkLrn+XUkcrzAwS1hXLq3wUu1NCE99B3WsuDTpf5fXpZ/9 goH9CciyW3c+4EZDydFPp52C35eKFte8jSHiTn5YMsD4eH6wBkOtIP51pFr+Ou75RZtXq2kJ4BKMh trip8kajb2K202DlasctERXvPOvSLsyqkCtIpzvQ5sqgi5ytJnBdZn+6CXykx17HvmLrfMAlyNqxX yZS2GWVNrxKqZOzXrUD3OFl6Sm6wQSXutXaS6RwvpM6oDBIYAPWaMuDUEOlbJO7rHPKUIuOomi2pD xSJy5uAOQfeL7xJ28ozA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1q1xmL-00EvDo-10; Wed, 24 May 2023 23:20:25 +0000 Received: from mail-yb1-xb4a.google.com ([2607:f8b0:4864:20::b4a]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1q1wpN-00Emxm-0X for linux-arm-kernel@lists.infradead.org; Wed, 24 May 2023 22:19:30 +0000 Received: by mail-yb1-xb4a.google.com with SMTP id 3f1490d57ef6-ba83fed5097so3153550276.2 for <linux-arm-kernel@lists.infradead.org>; Wed, 24 May 2023 15:19:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20221208; t=1684966768; x=1687558768; h=to:from:subject:references:mime-version:message-id:in-reply-to:date :from:to:cc:subject:date:message-id:reply-to; bh=xohs+RPxgQPJo1czRcXVjEN6Ep07r6+wQ3n8ob7tftg=; b=IgfaH00zw1PRDkqwd/QwU4Sg5TJxQ7feV/pDX0v7A7dRzdpe13pLIG6GaS/JKXqvvg ev2dtZc04e9KWDyVr2G86au0saClF58Kh2k5UqyhLSFrZRim46pA8475WEW10d+nK7Q8 AuJ5Qrusdz12jpgCcZCwhMqm6k5meHHrATRSwUpNhDNhVd1uq/as7AANV0NTOK0sIDaC ylyZNhgvKKWdgx6eILUv8tsxyqBsW3CbkhNkI5BgQ5mVc2/sMQtqHzkp55NEtG97JRyE PCuklBhHC8GBSKDKsBZoIfEtwM9VGUpouwsQJY4fCBgYF5Cb9M3ZTxkWD9/qm6+pKPCH 27CQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684966768; x=1687558768; 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=xohs+RPxgQPJo1czRcXVjEN6Ep07r6+wQ3n8ob7tftg=; b=lk+GRYMbzu7t4GIevbQeTkShkXHleMQvRgxV/p48jDOnLX8NBp7v+Ho6n/vZ5kb3MV KctcDEKbWBh9DnDpY4NhWsBGAouItWNtnczWl03IF2xfy0aikM1N2zElKqjAlE9Zt7Ap mWGvPADu+E+GwGJEWm1GsxOLcdL3Df7F3UomIB4oHPHiumP6KHw+ALqVrZF6CF6lCQQZ 1rr9liObQ1Xg1emIAbvRW/djtnK0EMtkw0WlI0mNanZ39nxshBIdkNRSTvspnTeCS7o5 z4zIaXTa2FXzoN7ZlxIcdY5eg9bbNgpft/5dCuUVXMCGmZRHhaGAwOIHnwkdC1y72ZSe HcfA== X-Gm-Message-State: AC+VfDwrGXAs22PlkyieVG+wTiH6eEhs/0ahOMoNv0l3GX7DNkvNih+e GvVb32xPSGEt6lOm69lJqREWucAI7mSp X-Google-Smtp-Source: ACHHUZ74qT7vuVNsbtmSv30uJE6ZkJtddOJ2ysembhatAzi/XHx184YwKBpC20/oi8O5XKcLYnGlaUmTM7AH X-Received: from irogers.svl.corp.google.com ([2620:15c:2d4:203:7aa7:3d2d:76ae:8e96]) (user=irogers job=sendgmr) by 2002:a05:6902:4ca:b0:ba8:84fb:6ad with SMTP id v10-20020a05690204ca00b00ba884fb06admr789426ybs.4.1684966767759; Wed, 24 May 2023 15:19:27 -0700 (PDT) Date: Wed, 24 May 2023 15:18:19 -0700 In-Reply-To: <20230524221831.1741381-1-irogers@google.com> Message-Id: <20230524221831.1741381-24-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 23/35] perf stat: Avoid hybrid PMU list 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_151929_199709_5ECBCBCC X-CRM114-Status: GOOD ( 13.38 ) 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/stat-display.c b/tools/perf/util/stat-display.c index ede0477d958a..78ce7095dbcb 100644 --- a/tools/perf/util/stat-display.c +++ b/tools/perf/util/stat-display.c @@ -19,7 +19,7 @@ #include <api/fs/fs.h> #include "util.h" #include "iostat.h" -#include "pmu-hybrid.h" +#include "pmu.h" #define CNTR_NOT_SUPPORTED "<not supported>" #define CNTR_NOT_COUNTED "<not counted>" @@ -680,11 +680,12 @@ static bool evlist__has_hybrid(struct evlist *evlist) { struct evsel *evsel; + if (!perf_pmu__has_hybrid()) + return false; + evlist__for_each_entry(evlist, evsel) { - if (evsel->pmu_name && - perf_pmu__is_hybrid(evsel->pmu_name)) { + if (evsel->core.is_pmu_core) return true; - } } return false;
perf_pmu__is_hybrid implicitly uses the hybrid PMU list. Instead return false if hybrid isn't present, if it is then see if any evsel's PMUs are core. Signed-off-by: Ian Rogers <irogers@google.com> --- tools/perf/util/stat-display.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-)