Received: by 2002:a05:7412:1703:b0:e2:908c:2ebd with SMTP id dm3csp782435rdb; Fri, 25 Aug 2023 00:22:29 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHRhb6vqOSEtWtT9UW1Y1FPKWzlKDYcOImZg0LhxdYeEWG8t5JptOHZjMN1uRo4NZqsSG/j X-Received: by 2002:aa7:de12:0:b0:525:4471:6b53 with SMTP id h18-20020aa7de12000000b0052544716b53mr14382038edv.19.1692948148960; Fri, 25 Aug 2023 00:22:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1692948148; cv=none; d=google.com; s=arc-20160816; b=TvYnB/+URGaKSjvLRyPGS/PH/IbnuokOSBkNEVp4TL8D1YymfiC53cgfiV8SzSI1jw eqJmB4LzpaNsnf/XSsZseHK5pCbdH0K6mv0kVZt+6cuMHDdpeQdnbQd20IcXp66Vwazi O8vQ553v+YrYyDhdXVaDjNmEWbkZ17krljG63EXao8/LaXh1ix8CIeEAY44hVtQu726V oqZohbXtKKPZkqJ99ZeTmpRSsBMykD6Vn5RE68opinZaNnGZVuroTeZqinqgRHKXax9Z RUa+5ohtgZUTtfY+rOKxvwhjwVisInhMid6mXE+zXVe2L0q6ycZmTTeaAGe7f138psnh gHCA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject; bh=h4T1RsNomY51nSHku7hlftRrEjGNQd7bLhCSgt+z4cM=; fh=xo9tINpoVzO9DZPTaVEGY70vsewaMyY6lTu17nLBmWs=; b=zaO3b80ibHpgz1/nBSNcA3OGAarPviIoEP/RhewG8GdCHTbpsOCshIKYkeyXOFPVCP udNodjagEvjfcvlpWrNsXqxZWsoqSw99aJoxIrN4uRYF6aCVObokixZ6Gr+cv1mI6GT9 ytpOCTwjubtLbtICWDUrrF7NbwxNPH4K4hJn29Pv9abs3qqsWsm3gYVpYMGjTxwPBBsq aGaVTEtHHhsdA6EZd5sPj38Ixhp+HVdMETPN1enj6eudcg42soPxsMrVXbKJrpjfIi9G M39JHv3QGoIw/yl8F8K8rnapsNQ+NPfkJKkKZX1ynUV2hsTdNEfPibuaHSBcvSKKUGLZ gMNg== 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r24-20020aa7c158000000b0052a135a736csi714617edp.579.2023.08.25.00.22.00; Fri, 25 Aug 2023 00:22:28 -0700 (PDT) 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239622AbjHYF7A (ORCPT + 99 others); Fri, 25 Aug 2023 01:59:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45250 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239639AbjHYF6g (ORCPT ); Fri, 25 Aug 2023 01:58:36 -0400 Received: from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E502419B5; Thu, 24 Aug 2023 22:58:33 -0700 (PDT) Received: from kwepemm600003.china.huawei.com (unknown [172.30.72.54]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4RX8NT64B8zrSVf; Fri, 25 Aug 2023 13:56:57 +0800 (CST) Received: from [10.67.111.205] (10.67.111.205) by kwepemm600003.china.huawei.com (7.193.23.202) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.31; Fri, 25 Aug 2023 13:58:29 +0800 Subject: Re: [PATCH v6 2/7] perf evlist: Add evlist__findnew_tracking_event() helper To: Ian Rogers CC: , , , , , , , , , , , , , , References: <20230821012734.18241-1-yangjihong1@huawei.com> <20230821012734.18241-3-yangjihong1@huawei.com> From: Yang Jihong Message-ID: Date: Fri, 25 Aug 2023 13:58:29 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.6.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8"; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-Originating-IP: [10.67.111.205] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To kwepemm600003.china.huawei.com (7.193.23.202) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.8 required=5.0 tests=BAYES_00,NICE_REPLY_A, RCVD_IN_DNSWL_BLOCKED,RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL, SPF_HELO_NONE,SPF_PASS 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 Hello, On 2023/8/25 12:55, Ian Rogers wrote: > On Sun, Aug 20, 2023 at 6:30 PM Yang Jihong wrote: >> >> Currently, intel-bts, intel-pt, and arm-spe may add a dummy event for >> tracking to the evlist. We may need to search for the dummy event for >> some settings. Therefore, add evlist__findnew_tracking_event() helper. > > Given the first two sentences I don't understand why this is > evlist__findnew_tracking_event and not evlist__findnew_dummy_event? > Are you setting tracking on other events other than dummy? If so, then > the commit message isn't right. If not then I'd prefer not to use > tracking event in the function name. > Yes, add this helper to find tracking event for some setting, will modify commit message, like as follows: Currently, intel-bts, intel-pt, and arm-spe may add tracking event to the evlist. We may need to search for the tracking event for some settings. Therefore, add evlist__findnew_tracking_event() helper. >> >> evlist__findnew_tracking_event() also deal with system_wide maps if >> system_wide is true. > > Could you fix the explanation here, what does "deal with system_wide" > mean? A kerneldoc comment and explanation of the system_wide argument > would be useful. > In the next version, details will be described as follows: If system_wide is true, evlist__findnew_tracking_event() set the cpu map of the evsel to all online CPUs. Is such an explanation okay? Thanks, Yang