From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2EFF5C001DB for ; Mon, 14 Aug 2023 06:09:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232367AbjHNGIi (ORCPT ); Mon, 14 Aug 2023 02:08:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39076 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233679AbjHNGId (ORCPT ); Mon, 14 Aug 2023 02:08:33 -0400 Received: from out30-124.freemail.mail.aliyun.com (out30-124.freemail.mail.aliyun.com [115.124.30.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E5CE6F4; Sun, 13 Aug 2023 23:08:31 -0700 (PDT) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R161e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018046050;MF=renyu.zj@linux.alibaba.com;NM=1;PH=DS;RN=20;SR=0;TI=SMTPD_---0VpgUTN2_1691993304; Received: from 30.221.149.204(mailfrom:renyu.zj@linux.alibaba.com fp:SMTPD_---0VpgUTN2_1691993304) by smtp.aliyun-inc.com; Mon, 14 Aug 2023 14:08:26 +0800 Message-ID: <099acfd1-b32f-e325-ccd1-cfeff6667c58@linux.alibaba.com> Date: Mon, 14 Aug 2023 14:08:24 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 Subject: Re: [PATCH v6 3/7] perf jevents: Support more event fields To: Ian Rogers Cc: John Garry , Will Deacon , James Clark , Arnaldo Carvalho de Melo , Mark Rutland , Mike Leach , Leo Yan , Namhyung Kim , Peter Zijlstra , Ingo Molnar , Alexander Shishkin , Jiri Olsa , Adrian Hunter , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-perf-users@vger.kernel.org, linux-doc@vger.kernel.org, Zhuo Song , Shuai Xue References: <1691394685-61240-1-git-send-email-renyu.zj@linux.alibaba.com> <1691394685-61240-4-git-send-email-renyu.zj@linux.alibaba.com> <50a8778a-ebe4-5b3b-9367-c8547d6d991d@oracle.com> From: Jing Zhang In-Reply-To: <50a8778a-ebe4-5b3b-9367-c8547d6d991d@oracle.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-perf-users@vger.kernel.org 在 2023/8/7 下午5:24, John Garry 写道: > On 07/08/2023 08:51, Jing Zhang wrote: >> The usual event descriptions are "event=xxx" or "config=xxx", while the >> event descriptions of CMN are "type=xxx, eventid=xxx" or more complex. >> >> $cat /sys/bus/event_source/devices/arm_cmn_0/events/hnf_cache_fill >> type=0x5,eventid=0x3 >> >> When adding aliases for events described as "event=xxx" or "config=xxx", >> EventCode or ConfigCode can be used in the JSON files to describe the >> events. But "eventid=xxx, type=xxx" cannot be supported at present. >> >> If EventCode and ConfigCode is not added in the alias JSON file, the >> event description will add "event=0" by default. So, even if the event >> field is added to supplement "eventid=xxx" and "type=xxx", the final >> parsing result will be "event=0, eventid=xxx, type=xxx". >> >> Therefore, when EventCode and ConfigCode are missing in JSON, "event=0" is >> no longer added by default. EventIdCode and Type are added to the event >> field, and ConfigCode is moved into the event_field array which can also >> guarantee its original function. >> >> Signed-off-by: Jing Zhang > > I'll let Ian check this change as he is more familiar with this code. > Hi Ian, Could you please help to review this change?:) Thanks, Jing