Received: by 2002:a25:ca44:0:0:0:0:0 with SMTP id a65csp256370ybg; Tue, 28 Jul 2020 05:22:41 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzjm/XcTM5d59+8OzosXOUuI/ZJJA47DgTSVZtJnui+iMf3u3Hf5aiJV4Dc2Qyd238eSb56 X-Received: by 2002:a05:6402:1544:: with SMTP id p4mr26316011edx.334.1595938961613; Tue, 28 Jul 2020 05:22:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595938961; cv=none; d=google.com; s=arc-20160816; b=XqSenpmxzfKvtfpo4CdVcSrkvjVHTcfF1ZLE1uSzdv58zSBYO0XCVxe5NQ0/Hh83TC 4zCUevv+IdNR6Gd86jZPgPGtZNS0jKtiEJJ2qohWjH4a6/ynwdGYxD0FqTQgUIQ81O6G w7KnrGMO2uX/GVDkhTo3HWv5j7UXxL3BjbGwiPxSmVK+kFw/WN0KKLMz3aGKUrfqjaSN lHoqzcFst3kE+TLZoAE+xDcnlzC4UJ2V0meTEDK2DhPy7bl6vmBd3eGkPmSFlJghAWlX yENYElj+wIelSYpyU7LGYXj4x/eTp7EwyIFOiBZS/iABTeOR0JlqeHHDanjO5dqD+hDb uMMQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=WRPt4rJHJt0IsUpT0uK4G5kiaHx8YsfnbzelYhQ7I4Y=; b=r22ozlSNJ0uaaX3E7XfBTUeXZcxkyncY/bi97Y+XBP9vbRJ3sgpWsk9GVrPQ3BCmIH KovpCWdVWUdn124Ngd/aZSJqT6v6csGZNXrldP/xwVsSEwsjXlz+OSVkLchp+caH5U1r xq0VNtdEEYfmC8T1sqtDe2YgL6WSZgMCd2Axldf5MjorWMqvdDoZTjoDoqlRPM7UdUrJ GtdPYAotQK2j9qqFW1fEBlk4/xFihfB9eRtFJR5bMrCf6cxbddh1gUsetsPLdbHv9jRw 9uY5F4TPShKzsqvL5tPLWn3dyEti4mLKlf9GzMNFe3bGWV4U6lyc+9EzDto4HvYvv7Fg mn3A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=b7AfZRRW; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c1si2712442ejm.377.2020.07.28.05.22.19; Tue, 28 Jul 2020 05:22:41 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=b7AfZRRW; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728741AbgG1MR0 (ORCPT + 99 others); Tue, 28 Jul 2020 08:17:26 -0400 Received: from mail.kernel.org ([198.145.29.99]:36408 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728300AbgG1MRZ (ORCPT ); Tue, 28 Jul 2020 08:17:25 -0400 Received: from quaco.ghostprotocols.net (179.176.1.55.dynamic.adsl.gvt.net.br [179.176.1.55]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 96272206D8; Tue, 28 Jul 2020 12:17:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1595938644; bh=PsfBZPvm8C6J4L11gPAZ+Mfo5hkustU/Edw7NUR2XJs=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=b7AfZRRWRt5Xd0N8GNWDyRYXhCuyHeBQaSB9x8d8+zuBKv6O0WaFBb7Fzxrvp6Bvc FwIe0kbWnh6gpc0CtwOw3K/CWDJ+utFGx8eC8JCPJ5QzFbjrS8PEeBaRBDHKjphnnv oaBEWsojgjDu0DIamsbPRB0IzOhVJd1NPZqEYQZU= Received: by quaco.ghostprotocols.net (Postfix, from userid 1000) id A24A7404B1; Tue, 28 Jul 2020 09:17:22 -0300 (-03) Date: Tue, 28 Jul 2020 09:17:22 -0300 From: Arnaldo Carvalho de Melo To: "Jin, Yao" Cc: Jiri Olsa , lkml , Ingo Molnar , Namhyung Kim , Alexander Shishkin , Peter Zijlstra , Michael Petlan , Ian Rogers , Stephane Eranian , Andi Kleen , Thomas Richter Subject: Re: [PATCHv2 2/2] perf tools: Fix term parsing for raw syntax Message-ID: <20200728121722.GF40195@kernel.org> References: <20200726075244.1191481-1-jolsa@kernel.org> <20200726075244.1191481-2-jolsa@kernel.org> <4d30edad-8df1-ac9d-c70d-9019935c4d4c@linux.intel.com> <003c9419-4396-6ad6-b934-ec04bf9f8a63@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <003c9419-4396-6ad6-b934-ec04bf9f8a63@linux.intel.com> X-Url: http://acmel.wordpress.com Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Em Mon, Jul 27, 2020 at 08:26:27AM +0800, Jin, Yao escreveu: > > > On 7/27/2020 8:21 AM, Jin, Yao wrote: > > > > > > On 7/26/2020 3:52 PM, Jiri Olsa wrote: > > > Jin Yao reported issue with possible conflict between raw > > > events and term values in pmu event syntax. > > > > > > Currently following syntax is resolved as raw event with > > > 0xead value: > > > ?? uncore_imc_free_running/read/ > > > > > > instead of using 'read' term from uncore_imc_free_running pmu, > > > because 'read' is correct raw event syntax with 0xead value. > > > > > > To solve this issue we do following: > > > ?? - check existing terms during rXXXX syntax processing > > > ???? and make them priority in case of conflict > > > ?? - allow pmu/r0x1234/ syntax to be able to specify conflicting > > > ???? raw event (implemented in previous patch) > > > > > > Also adding automated tests for this and perf_pmu__parse_cleanup > > > call to parse_events_terms, so the test gets properly cleaned up. > > > > > > Reported-by: Jin Yao > > > Signed-off-by: Jiri Olsa > > > --- > > > v2 changes: > > > ? - added comment to perf_pmu__test_parse_init > > > > Acked-by: Jin Yao > > > > Thanks > > Jin Yao > > Also added with: > Fixes: 3a6c51e4d66c ("perf parser: Add support to specify rXXX event with pmu")? Thanks, applied. - Arnaldo