Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp433197ybz; Wed, 22 Apr 2020 00:50:24 -0700 (PDT) X-Google-Smtp-Source: APiQypK9YHFGipFI25Ku3nzmEkQu1aKyzekZunc1Avfs7dwjab88TkXGge5LOstbNVboVH9U4hX2 X-Received: by 2002:a17:906:2a86:: with SMTP id l6mr25223279eje.273.1587541823890; Wed, 22 Apr 2020 00:50:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1587541823; cv=none; d=google.com; s=arc-20160816; b=X32BZDUSQ+fznYOL4xEr9cLLcq6bSjV7JwuLMbR6dcLKg4jwd+i7JOUe9sUCvtPUjd UlJvdLkMEqUa3XW/tvXTY2AoJP3gtZ42cjFMWKGeeXlYvTHpYevbZvf5Gv9wP0PmZk+f d/mdhaVcnDFQB6aNRTEjIiab01PCoaX8/ker3XUrVfs5sNDz+V3LXZFD7dGYN9N39qNH 2hMNzWuHHSh1GGmExmCHYKCNxlQH4GP5OTXW1UAzspTbRi9cS/FgfkgOjO+EzpLYPt3L 5hAksqvU+8FkSWgtkj/B9IX/G+hYToZSpWSAzfK/6twVYkiXZU8+20mQftHfaU0RgbIU BCvQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:from:subject:mime-version :message-id:date:dkim-signature; bh=9HUq00N6jmzIo0+nRmNO3NIJIF03YhOq9io6sQiHkEA=; b=hZiOyl2+KvAIOSdC2AUwgFZc1a0T/oxsQrz93L7cTHN2YRq9ATVzAsZoSQtSa7vEzW 1PuY1XZI/Ye03tjBk0FRCSrvjIja7HSbrN9B1FK/9700HIo+bY7gJsi8ikuSp72O679N XWKf5R/ap1xvF6eejQq29fKevPGmzjCb5s6mWJWz79VaJepgAHE58hkTTe0qPd7UXqRB RUXcD/RZlS6ZaTWtfC/26ue/zJ22+63UWyyjMtSqRh2sgH+pD6z8dP+AyjxYWHl+7eRJ IdgWOmmIYg1NEwxIAy9pRWtb2XHuRBhda/2LKZj9+D/VqkHTJaQj52INlOGvuNYInMfX MZ/g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=Ayqn1vfE; 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 v15si3086309edq.394.2020.04.22.00.50.00; Wed, 22 Apr 2020 00:50:23 -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=Ayqn1vfE; 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 S1726499AbgDVHsO (ORCPT + 99 others); Wed, 22 Apr 2020 03:48:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39678 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1725842AbgDVHsO (ORCPT ); Wed, 22 Apr 2020 03:48:14 -0400 Received: from mail-pf1-x449.google.com (mail-pf1-x449.google.com [IPv6:2607:f8b0:4864:20::449]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 17431C03C1A6 for ; Wed, 22 Apr 2020 00:48:14 -0700 (PDT) Received: by mail-pf1-x449.google.com with SMTP id c190so1363197pfc.10 for ; Wed, 22 Apr 2020 00:48:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:message-id:mime-version:subject:from:to:cc; bh=9HUq00N6jmzIo0+nRmNO3NIJIF03YhOq9io6sQiHkEA=; b=Ayqn1vfEmsn47YwBswhWoVXmXdRP/hQR9tPrzb9dQTfMlPK5PWPROXnwuzjTnrLeqF uVOPdSYVquV3+hwARpMVKcvEb1Y9D7P4H/b7RfnpksCrA+wpMtZg7hLNCMkC3IPrgFMv rPesoFKWyvLpFvxjdLf/4XTD7A7XNqwLUiM7ifqvcPlWJmHsDMV8hAYjcSUn3zEdHCIQ Gg3SzoZ+fs8Xs86EM/9LlxtAtft3U2ZS1TSBciZLJpKlbbwSnIgKTI5BGjoA4UQuYNYg X5/+27Lno7soggC2PcGeSO5aR30P204PSdNUlzzbeRL9xjtwpsx7SBdnoZ0J5I4iIdBp kLQw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:message-id:mime-version:subject:from:to:cc; bh=9HUq00N6jmzIo0+nRmNO3NIJIF03YhOq9io6sQiHkEA=; b=OPJaEZiakeYo189A+MnxH2MnBqqowHTjhGN48dM6B6QLj7LYaCJj0AbRlLVFgF2Dwl 9VeKQYTu3rKOOGKIC9rK1ro7ZxFxYHNTJdGnLw0VKj/hpq/0vSUUofc2ihfiKzr8xmY1 6HuwwclPqshFsZoKhkZsIwzMxcsOXH5jY/CL1e1Yw6lqfRYwSPxpsSDYeSXbcszIJGaf /uMlAfFf243Y63YEcmckMcMOI8iLfQB1kRUJazTmDK10EmnZLmbAAf/zFr0FEIr7yMow hy35bBsQv2TjxPF1vl76LI95DKL1+p8NKeGexdyD0+De6L/ZnjjeDea6P4QVYNvPE2a6 pB4g== X-Gm-Message-State: AGi0PuYgdKyBIYIg0+Xsza6yREzIl59KLkIY+IvlmcZRQmg5jk0coRNW IeoRLPdGxb+G2YSok6b53NDJH+UMIk28 X-Received: by 2002:a17:90a:65c5:: with SMTP id i5mr10189197pjs.18.1587541693454; Wed, 22 Apr 2020 00:48:13 -0700 (PDT) Date: Wed, 22 Apr 2020 00:48:01 -0700 Message-Id: <20200422074809.160248-1-irogers@google.com> Mime-Version: 1.0 X-Mailer: git-send-email 2.26.2.303.gf8c07b1a785-goog Subject: [PATCH 0/8] perf metric fixes and test From: Ian Rogers To: Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Jiri Olsa , Namhyung Kim , Kan Liang , Andi Kleen , Haiyan Song , Jin Yao , Ravi Bangoria , John Garry , Leo Yan , Adrian Hunter , linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org Cc: Stephane Eranian , Ian Rogers 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 Add a test that all perf metrics (for your architecture) are parsable. Fix bugs in the expr parser and in x86 metrics. Untested on architectures other than x86. Ian Rogers (8): perf expr: unlimited escaped characters in a symbol perf metrics: fix parse errors in cascade lake metrics perf metrics: fix parse errors in skylake metrics perf expr: allow ',' to be an other token perf expr: increase max other perf expr: parse numbers as doubles perf expr: debug lex if debugging yaxx perf test: add expr test for pmu metrics .../arch/x86/cascadelakex/clx-metrics.json | 10 +- .../arch/x86/skylakex/skx-metrics.json | 4 +- tools/perf/tests/builtin-test.c | 5 + tools/perf/tests/expr.c | 91 ++++++++++++++++++- tools/perf/tests/tests.h | 2 + tools/perf/util/expr.c | 1 + tools/perf/util/expr.h | 2 +- tools/perf/util/expr.l | 16 ++-- tools/perf/util/expr.y | 2 +- 9 files changed, 115 insertions(+), 18 deletions(-) -- 2.26.2.303.gf8c07b1a785-goog