Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp11740772rwl; Tue, 3 Jan 2023 04:09:28 -0800 (PST) X-Google-Smtp-Source: AMrXdXug4rwcQdgewHBTuap5iNpISoF7C+3gBFJu2hReCYPf7p16OWrN4j2i81DtVfVhOdB0ijUY X-Received: by 2002:a17:906:79d2:b0:7ae:987d:d7f9 with SMTP id m18-20020a17090679d200b007ae987dd7f9mr34211685ejo.17.1672747768648; Tue, 03 Jan 2023 04:09:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1672747768; cv=none; d=google.com; s=arc-20160816; b=fCzxehyM43wK5bTlQcJqH+dGfvMTxLvhmOlTYxl3ojse1uBal5ebr4M9j1OGa0vdvO 3vR0khheio97I7Pxm/X+9P/qFDwOQcJXOyvdiJ0DEdzjVCAdyNhd4bVo0KFAVnh0w6nJ /Cp88eOncewpb+k/tlWiWFJ3YOaW7k1FUpnETaLu3N1EEl9Tb9lZ3r+oAStpaUROJv8g cGRrGWySFlN65u/lbMkxSm/VdD2OqDY4xXT2Oi5CpQ55kXMMzdsWL0YOw5Q90hTXArF1 D90305uPcVgBS3TydmHFs+R4JOKFJn34Pd0K1xknK1A8sLRKsdC11WgFI9yZuGScqO98 OS9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:in-reply-to:message-id:date:subject :cc:to:from; bh=/KUcbcHeG8v+tsfD5Nq1c3GLsNiLJYx62zBT4s7ls7M=; b=o1LxlsmSz9Hqsj4MGQPqvsXbnmuf1du7YI2mstM7X7YqloRPLIQ3Md4BEk65fA/Rvy OlzmodT9+rjo6BJcFtxaLLW+mkIa6vQN5b+xy6bxTLZUDawqtwWwuDN5LeahkJDsZawb F1oxgfuxxT6FMabhSFAbmePQaXIyEj1yoMo1o1D2nd9hjagrYany9zxaxEJpy9DnIDuu 7Jex7Eu94e2dkaY1RIbGtLX32Gkvw0dwZK7tGqAhfnA09zmtENKFQCAeGEVQhgEDeuiO Tkebd/fTxGo/DmQqKr/kLG36SEPikkSOJ6VE4+FdXvnbwLM1qQLKcONH2I1v1B5uiHFq 36WA== 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=alibaba.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ji5-20020a170907980500b007addbdb9fbbsi29005236ejc.558.2023.01.03.04.09.14; Tue, 03 Jan 2023 04:09:28 -0800 (PST) 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=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232910AbjACLkG (ORCPT + 60 others); Tue, 3 Jan 2023 06:40:06 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36652 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236816AbjACLj7 (ORCPT ); Tue, 3 Jan 2023 06:39:59 -0500 Received: from out30-7.freemail.mail.aliyun.com (out30-7.freemail.mail.aliyun.com [115.124.30.7]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EB9D1BEE; Tue, 3 Jan 2023 03:39:56 -0800 (PST) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R171e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018045170;MF=renyu.zj@linux.alibaba.com;NM=1;PH=DS;RN=21;SR=0;TI=SMTPD_---0VYn6ldT_1672745992; Received: from srmbuffer011165236051.sqa.eu95(mailfrom:renyu.zj@linux.alibaba.com fp:SMTPD_---0VYn6ldT_1672745992) by smtp.aliyun-inc.com; Tue, 03 Jan 2023 19:39:53 +0800 From: Jing Zhang To: John Garry , Ian Rogers , Xing Zhengjun , Will Deacon , James Clark , Mike Leach , Leo Yan Cc: linux-arm-kernel@lists.infradead.org, linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org, Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Jiri Olsa , Namhyung Kim , Andrew Kilroy , Shuai Xue , Zhuo Song , Jing Zhang Subject: [PATCH v5 3/6] perf vendor events arm64: Add cache metrics for neoverse-n2 Date: Tue, 3 Jan 2023 19:39:33 +0800 Message-Id: <1672745976-2800146-4-git-send-email-renyu.zj@linux.alibaba.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1672745976-2800146-1-git-send-email-renyu.zj@linux.alibaba.com> References: <1672745976-2800146-1-git-send-email-renyu.zj@linux.alibaba.com> X-Spam-Status: No, score=-9.9 required=5.0 tests=BAYES_00, ENV_AND_HDR_SPF_MATCH,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS, UNPARSEABLE_RELAY,USER_IN_DEF_SPF_WL 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 Add cache related metrics. Signed-off-by: Jing Zhang Acked-by: Ian Rogers --- .../arch/arm64/arm/neoverse-n2/metrics.json | 77 ++++++++++++++++++++++ 1 file changed, 77 insertions(+) diff --git a/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/metrics.json b/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/metrics.json index 8a74e07..f81b40d 100644 --- a/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/metrics.json +++ b/tools/perf/pmu-events/arch/arm64/arm/neoverse-n2/metrics.json @@ -75,5 +75,82 @@ "MetricGroup": "TLB", "MetricName": "itlb_walk_rate", "ScaleUnit": "100%" + }, + { + "MetricExpr": "L1I_CACHE_REFILL / INST_RETIRED * 1000", + "BriefDescription": "The rate of L1 I-Cache misses per kilo instructions", + "MetricGroup": "Cache", + "MetricName": "l1i_cache_mpki", + "ScaleUnit": "MPKI" + }, + { + "MetricExpr": "L1I_CACHE_REFILL / L1I_CACHE", + "BriefDescription": "The rate of L1 I-Cache misses to the overall L1 I-Cache", + "MetricGroup": "Cache", + "MetricName": "l1i_cache_miss_rate", + "ScaleUnit": "100%" + }, + { + "MetricExpr": "L1D_CACHE_REFILL / INST_RETIRED * 1000", + "BriefDescription": "The rate of L1 D-Cache misses per kilo instructions", + "MetricGroup": "Cache", + "MetricName": "l1d_cache_mpki", + "ScaleUnit": "MPKI" + }, + { + "MetricExpr": "L1D_CACHE_REFILL / L1D_CACHE", + "BriefDescription": "The rate of L1 D-Cache misses to the overall L1 D-Cache", + "MetricGroup": "Cache", + "MetricName": "l1d_cache_miss_rate", + "ScaleUnit": "100%" + }, + { + "MetricExpr": "L2D_CACHE_REFILL / INST_RETIRED * 1000", + "BriefDescription": "The rate of L2 D-Cache misses per kilo instructions", + "MetricGroup": "Cache", + "MetricName": "l2d_cache_mpki", + "ScaleUnit": "MPKI" + }, + { + "MetricExpr": "L2D_CACHE_REFILL / L2D_CACHE", + "BriefDescription": "The rate of L2 D-Cache misses to the overall L2 D-Cache", + "MetricGroup": "Cache", + "MetricName": "l2d_cache_miss_rate", + "ScaleUnit": "100%" + }, + { + "MetricExpr": "L3D_CACHE_REFILL / INST_RETIRED * 1000", + "BriefDescription": "The rate of L3 D-Cache misses per kilo instructions", + "MetricGroup": "Cache", + "MetricName": "l3d_cache_mpki", + "ScaleUnit": "MPKI" + }, + { + "MetricExpr": "L3D_CACHE_REFILL / L3D_CACHE", + "BriefDescription": "The rate of L3 D-Cache misses to the overall L3 D-Cache", + "MetricGroup": "Cache", + "MetricName": "l3d_cache_miss_rate", + "ScaleUnit": "100%" + }, + { + "MetricExpr": "LL_CACHE_MISS_RD / INST_RETIRED * 1000", + "BriefDescription": "The rate of LL Cache read misses per kilo instructions", + "MetricGroup": "Cache", + "MetricName": "ll_cache_read_mpki", + "ScaleUnit": "MPKI" + }, + { + "MetricExpr": "LL_CACHE_MISS_RD / LL_CACHE_RD", + "BriefDescription": "The rate of LL Cache read misses to the overall LL Cache read", + "MetricGroup": "Cache", + "MetricName": "ll_cache_read_miss_rate", + "ScaleUnit": "100%" + }, + { + "MetricExpr": "(LL_CACHE_RD - LL_CACHE_MISS_RD) / LL_CACHE_RD", + "BriefDescription": "The rate of LL Cache read hit to the overall LL Cache read", + "MetricGroup": "Cache", + "MetricName": "ll_cache_read_hit_rate", + "ScaleUnit": "100%" } ] -- 1.8.3.1