Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp868126ybz; Wed, 22 Apr 2020 09:20:47 -0700 (PDT) X-Google-Smtp-Source: APiQypIKlDlQtQWBEydVXdrSZT5wtdKzA0hBv14H6S1PkPdHCjdxfjCUmL2XWbO121ksGojWpmyr X-Received: by 2002:a17:906:78c:: with SMTP id l12mr25196714ejc.189.1587572446794; Wed, 22 Apr 2020 09:20:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1587572446; cv=none; d=google.com; s=arc-20160816; b=T5AfCQMOgHQBWv3qomlVOvpLF9EGQcsw3jKubla9DI8NAxkDN3+Cc0Lr5gfjyDZl7f A1/y7Sg2uk5IySaDVPrikY/blJuhnQSXbIoeB7cWlWiaBfykXcg/1Yw1xsU+fkdi1VNs oMVa4cFWqI2X6WprqKGvfv5rGWIZSphuHG1Xmm3f4hRaou8mEcETxtpy1yD0I5jNFKZP dZ4Y4+PodbgFuI1Qy4zuKtgoOAfFutjcF8bf1Z/Qz0fXDD+pqGjqbUZScwRHeV07vNJz eJoIj5E4zn83vlEyfS09XQtCWLsFKHgJOIVadJeJIc/NAgEWARZhBHzvlvWkKpi393zS 3UVQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=MdFV6oxCT5U94DDUA8tMXvti7DUCxcfVIn4legiry/M=; b=HZHF7BzyUTw0+lX1Q1mfPHvw9Idn6h1+gtdkvNjVraE53Hdn9SNfHmn5n6SLGKGJzk RYq8sX5chdqx5FqXDGJKXfm16HzuuiHuxzTkh2RDwEQ45vzFCWm0KBvB5AH1GAgfu3K/ jHdCdSY9rnoYDSrooMGa32UtpdV7GOJDA8ZMIk8vXjAMzAEYok6P7Qip/Cf/tQXxvpuH 5m0uvdA87JOB3IXEEiImrLOSd0aBzltKOy4BzzKGol38wDQxijtg7nqwPlgxqH6RDCdz +6PzV6t+y0f+e+eF/zFY/lK0e6Zj/0X3zRImQmCndFz3c/uDOf3zDXrVoqlSSZeWGmte 3Nyg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=RHKYJuvZ; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dn12si4370110ejc.52.2020.04.22.09.20.19; Wed, 22 Apr 2020 09:20:46 -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=@google.com header.s=20161025 header.b=RHKYJuvZ; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726650AbgDVQTK (ORCPT + 99 others); Wed, 22 Apr 2020 12:19:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34564 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726183AbgDVQTJ (ORCPT ); Wed, 22 Apr 2020 12:19:09 -0400 Received: from mail-yb1-xb42.google.com (mail-yb1-xb42.google.com [IPv6:2607:f8b0:4864:20::b42]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A80D7C03C1A9 for ; Wed, 22 Apr 2020 09:19:09 -0700 (PDT) Received: by mail-yb1-xb42.google.com with SMTP id f13so1465520ybk.7 for ; Wed, 22 Apr 2020 09:19:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=MdFV6oxCT5U94DDUA8tMXvti7DUCxcfVIn4legiry/M=; b=RHKYJuvZpmyAPj3eqmYkeJwOcFp+ks7i8s+GO2DeBExw8MhxvzCBuz1k/2M9wn1MMc SBwb7m6dnbOh7Vq5Hot90q92Ypnx8ZdHgD3rpNJB4dSZmd2BTLIo0y+vElsYinww1uIt xfjKIFwVggOF68sLw+CHknIEK8zxF9VhHXxdH7Vxcl7LdzOJj5m0WI/8r3FpO1vQUgK2 hZo7xEoiHiiMbscFsbHa0lbjZaEKlY0rVKDcQh3BL1NXlQ+Q9Vm0KEObmY9CZOgdv2Fn 84AzYAtBQ5+ROkWXKF5dXXi8PBXPFaerd+4yvRxz5sGmbgu1gTWDOVPiJi5r3cdJMn+l 6Inw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=MdFV6oxCT5U94DDUA8tMXvti7DUCxcfVIn4legiry/M=; b=TcAjUq5mk0aGWe5ntD4qOEJVs5Vq3TNIW9QxjJLWikSCSWB6VUmjHvwDSVcVvvUZqN dQWaITjFrG6/UUv7aBYdbNAArGf4sqD+aKWTH24PD7543UAjxcH6VpGb17tLU6yG+qH2 Y/+zyn1e8xbKKAXWk1Sbjv4cCxzMf3fKXUiVxT4lhz9cD38kTFVoCIB/Y9ajrw8nRTNa ujeZ0z3OTXWjhaodEStp127D+qz1ZXCJmUrqh8O7tjyn7scRktznY91pcNyrU+8ilxJv v5OCp89g5gnt30gEpphHB3NaNrDlmXADzxymWuoSpiaXB1Y46M1thEpHhMv8DCd5uqM+ u3+g== X-Gm-Message-State: AGi0PuY/aoH30O493mr2O2ZO2K5arWL+ueZG/ajTWLAxz1yjAYhZTcMd pKuutucS/B5d8Pnag3bUx0R1ZfLrSPjoK2iVaYaI3A== X-Received: by 2002:a5b:9cb:: with SMTP id y11mr38625798ybq.177.1587572348432; Wed, 22 Apr 2020 09:19:08 -0700 (PDT) MIME-Version: 1.0 References: <20200422074809.160248-1-irogers@google.com> <20200422074809.160248-3-irogers@google.com> <20200422143840.GJ608746@tassilo.jf.intel.com> In-Reply-To: From: Ian Rogers Date: Wed, 22 Apr 2020 09:18:57 -0700 Message-ID: Subject: Re: [PATCH 2/8] perf metrics: fix parse errors in cascade lake metrics To: Andi Kleen Cc: Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Jiri Olsa , Namhyung Kim , Kan Liang , Haiyan Song , Jin Yao , Ravi Bangoria , John Garry , Leo Yan , Adrian Hunter , LKML , linux-perf-users , Stephane Eranian Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Apr 22, 2020 at 8:34 AM Ian Rogers wrote: > > On Wed, Apr 22, 2020 at 7:38 AM Andi Kleen wrote: > > > > On Wed, Apr 22, 2020 at 12:48:03AM -0700, Ian Rogers wrote: > > > Remove over escaping with \\. > > > Remove extraneous if 1 if 0 == 1 else 0 else 0. > > > > So where do these parse errors happen exactly? Some earlier > > patches introduced them as regressions? > > I'll work to track down a Fixes tag. I can repro the Skylakex errors > without the test in this series, by doing: > > $ perf stat -M DRAM_Read_Latency sleep 1 > Error: > The sys_perf_event_open() syscall returned with 22 (Invalid argument) > for event (cha/event=0x36\,uma > sk=0x21/). > /bin/dmesg | grep -i perf may provide additional information. > > This was just the escaping issue. I'm less clear on the other cascade > lake issue, and it is a bit more work for me to test on cascade lake. > What is "if 1 if 0 == 1 else 0 else 0" trying to do? Perhaps hunting > for the Fixes will let me know, but it looks like a copy-paste error. > > > The original metrics worked without parse errors as far as I know. > > The skylake issue above repros on 5.2.17 and so it seems like it is > broken for a while. The test in this series will prevent this in the > future, but without this patch that test fails. The parse errors were introduced with the metrics, so they've never worked: https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git/commit/?id=fd5500989c8f3c3944ac0a144be04bae2506f7ba I will send out a v2 with Fixes in the commit message but wanted to wait in case there was any more feedback. In particular the fixes to the new test and expr parser lex code. The lex code wasn't broken at the time the metrics were added and should be working again after this patch set. Thanks, Ian > > If it fixes something earlier it would need Fixes: tags. > > Working on it. Thanks for the input! > > Ian > > > -Andi