Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp5223608rwb; Mon, 14 Nov 2022 00:53:01 -0800 (PST) X-Google-Smtp-Source: AA0mqf6qh3kPDQAk6FyWsI9LGlCxD96QAvu/mts1yOHvfHABMObqWSUt7m5WAc48moLHNFGrwwZC X-Received: by 2002:a63:4d60:0:b0:46e:c052:a6b0 with SMTP id n32-20020a634d60000000b0046ec052a6b0mr11058641pgl.91.1668415981284; Mon, 14 Nov 2022 00:53:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668415981; cv=none; d=google.com; s=arc-20160816; b=j/yIgGUNpDWZlzCGgQ4a7m0r8X+Bs+DJUN3r0skeg2VTUdWBbPt1GtngM5pA2RrguQ ScWv2O8Yqur3dmMM5zn23w2K8u53/Z12GvkmDEbVBhVhOEQSqpne4oGIUV6jGVJSvpTT yT3Mk1YudLME/eYNVrm+F8MZB6Yak64k0UNUvjTkA8vhKjgP6ajRicPffrT9jkghciwR 9yegTt2Yo3DKeV6KuMRX8ltKpIF2hS5e1XifCnMaPhTMZxtAd5r49qGHq6U1zca/oS2N RA/e5EpYVj4B/F4PjrZKa/1LVH581tTgMlMTZTsLO1JoBlU941P/D8BskvmxsCp1VO5X UlPQ== 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:references:in-reply-to :message-id:date:subject:cc:to:from; bh=gHUShCpzxEhQRzXKjeLf/UDkymSDV3Ewt0XRKDRrIN4=; b=lPzSAvYAjb+0l0vTGXQIHafdqhVHvUNRUbxzBYsS0qzSCYDXYembpf+uXqeXIB5E2M bDJcMznhLae6jvPXoG+o1VGCgtWioWQJZ35qfnTpCJ/NAEnWpIN7FdSD/pKzuXMe51hB fWkkDmVxRSemBDI+Wo0mwzTXYqhC+7zQFWBWhvAzKes2w4ZYPhWhKm7tEDs2/Pda3b4/ 1bMFIU7pBSfr9AcqFMx9XNEKDcIUp1vSzuV85nQOngy8Bor5H7xQsakTNGO5bXt66q/I uNR3hVMCKjh+ZYFBeK98F2bw2HaQhDOQ3hzWAB02M8jZcxOqQx3ZaL2TD+dSf+WjP0Fu phbQ== 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 w18-20020a63c112000000b0047014fb1e75si9212260pgf.523.2022.11.14.00.52.50; Mon, 14 Nov 2022 00:53:01 -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 S235975AbiKNHmw (ORCPT + 89 others); Mon, 14 Nov 2022 02:42:52 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37626 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235946AbiKNHmo (ORCPT ); Mon, 14 Nov 2022 02:42:44 -0500 Received: from out30-131.freemail.mail.aliyun.com (out30-131.freemail.mail.aliyun.com [115.124.30.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E7D97140A2; Sun, 13 Nov 2022 23:42:42 -0800 (PST) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R121e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018046049;MF=renyu.zj@linux.alibaba.com;NM=1;PH=DS;RN=19;SR=0;TI=SMTPD_---0VUjWi1j_1668411759; Received: from j66e01291.sqa.eu95.tbsite.net(mailfrom:renyu.zj@linux.alibaba.com fp:SMTPD_---0VUjWi1j_1668411759) by smtp.aliyun-inc.com; Mon, 14 Nov 2022 15:42:40 +0800 From: Jing Zhang To: linux-arm-kernel@lists.infradead.org, linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org, John Garry , Will Deacon , James Clark , Mike Leach , Leo Yan Cc: 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: [RFC PATCH v2 3/6] perf vendor events arm64: Add cache metrics for neoverse-n2 Date: Mon, 14 Nov 2022 15:41:57 +0800 Message-Id: <1668411720-3581-4-git-send-email-renyu.zj@linux.alibaba.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1668411720-3581-1-git-send-email-renyu.zj@linux.alibaba.com> References: <1668411720-3581-1-git-send-email-renyu.zj@linux.alibaba.com> In-Reply-To: <1667214694-89839-1-git-send-email-renyu.zj@linux.alibaba.com> References: <1667214694-89839-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_DNSWL_NONE,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 --- .../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 324ca12..1690ef6 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 @@ -54,5 +54,82 @@ "BriefDescription": "The rate of DTLB Walks to the overall TLB lookups", "MetricGroup": "TLB", "MetricName": "dtlb_walk_rate" + }, + { + "MetricExpr": "L1I_CACHE_REFILL / INST_RETIRED * 1000", + "PublicDescription": "The rate of L1 I-Cache misses per kilo instructions", + "BriefDescription": "The rate of L1 I-Cache misses per kilo instructions", + "MetricGroup": "Cache", + "MetricName": "l1i_cache_mpki" + }, + { + "MetricExpr": "L1I_CACHE_REFILL / L1I_CACHE", + "PublicDescription": "The rate of L1 I-Cache misses to the overall L1 I-Cache", + "BriefDescription": "The rate of L1 I-Cache misses to the overall L1 I-Cache", + "MetricGroup": "Cache", + "MetricName": "l1i_cache_miss_rate" + }, + { + "MetricExpr": "L1D_CACHE_REFILL / INST_RETIRED * 1000", + "PublicDescription": "The rate of L1 D-Cache misses per kilo instructions", + "BriefDescription": "The rate of L1 D-Cache misses per kilo instructions", + "MetricGroup": "Cache", + "MetricName": "l1d_cache_mpki" + }, + { + "MetricExpr": "L1D_CACHE_REFILL / L1D_CACHE", + "PublicDescription": "The rate of L1 D-Cache misses to the overall L1 D-Cache", + "BriefDescription": "The rate of L1 D-Cache misses to the overall L1 D-Cache", + "MetricGroup": "Cache", + "MetricName": "l1d_cache_miss_rate" + }, + { + "MetricExpr": "L2D_CACHE_REFILL / INST_RETIRED * 1000", + "PublicDescription": "The rate of L2 D-Cache misses per kilo instructions", + "BriefDescription": "The rate of L2 D-Cache misses per kilo instructions", + "MetricGroup": "Cache", + "MetricName": "l2d_cache_mpki" + }, + { + "MetricExpr": "L2D_CACHE_REFILL / L2D_CACHE", + "PublicDescription": "The rate of L2 D-Cache misses to the overall L2 D-Cache", + "BriefDescription": "The rate of L2 D-Cache misses to the overall L2 D-Cache", + "MetricGroup": "Cache", + "MetricName": "l2d_cache_miss_rate" + }, + { + "MetricExpr": "L3D_CACHE_REFILL / INST_RETIRED * 1000", + "PublicDescription": "The rate of L3 D-Cache misses per kilo instructions", + "BriefDescription": "The rate of L3 D-Cache misses per kilo instructions", + "MetricGroup": "Cache", + "MetricName": "l3d_cache_mpki" + }, + { + "MetricExpr": "L3D_CACHE_REFILL / L3D_CACHE", + "PublicDescription": "The rate of L3 D-Cache misses to the overall L3 D-Cache", + "BriefDescription": "The rate of L3 D-Cache misses to the overall L3 D-Cache", + "MetricGroup": "Cache", + "MetricName": "l3d_cache_miss_rate" + }, + { + "MetricExpr": "LL_CACHE_MISS_RD / INST_RETIRED * 1000", + "PublicDescription": "The rate of LL Cache read misses per kilo instructions", + "BriefDescription": "The rate of LL Cache read misses per kilo instructions", + "MetricGroup": "Cache", + "MetricName": "ll_cache_read_mpki" + }, + { + "MetricExpr": "LL_CACHE_MISS_RD / LL_CACHE_RD", + "PublicDescription": "The rate of LL Cache read misses to the overall LL Cache read", + "BriefDescription": "The rate of LL Cache read misses to the overall LL Cache read", + "MetricGroup": "Cache", + "MetricName": "ll_cache_read_miss_rate" + }, + { + "MetricExpr": "(LL_CACHE_RD - LL_CACHE_MISS_RD) / LL_CACHE_RD", + "PublicDescription": "The rate of LL Cache read hit to the overall LL Cache read", + "BriefDescription": "The rate of LL Cache read hit to the overall LL Cache read", + "MetricGroup": "Cache", + "MetricName": "ll_cache_read_hit_rate" } ] \ No newline at end of file -- 1.8.3.1