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 X-Spam-Level: X-Spam-Status: No, score=-13.4 required=3.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, MENTIONS_GIT_HOSTING,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_IN_DEF_DKIM_WL autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7F129C4CECE for ; Wed, 11 Mar 2020 19:32:43 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 6F39420736 for ; Wed, 11 Mar 2020 19:32:44 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="ZRa0WWvz" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731218AbgCKTck (ORCPT ); Wed, 11 Mar 2020 15:32:40 -0400 Received: from mail-yw1-f67.google.com ([209.85.161.67]:40498 "EHLO mail-yw1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731200AbgCKTcj (ORCPT ); Wed, 11 Mar 2020 15:32:39 -0400 Received: by mail-yw1-f67.google.com with SMTP id c15so3166974ywn.7 for ; Wed, 11 Mar 2020 12:32:38 -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=LKraGJ30l6Da9gHXvZPSp4wo2q6s17TXGOTZwSnizRM=; b=ZRa0WWvzWQ7vbhoCUSCiE+Xpnyn0r9X4j+VOZY5z0moAgoqNi7XrIrbvdOGZLoPStZ t73/+8vK2zz/7Sh+YYuj8fHZZ3FvfEkXr6S9rYt7Ocx5uwZ/jttu0ZmY6lDF4hBC0sXu RTFy9i9geyhj4B0j0J1TMco4guXl0g6ScFtbUdddNz65nOwp+Tj4KuGah5rZn7yD5Rip nEJhat4np3znLve8DajoGUAaFw8E/zVSfQ8ONil21IEam4PVvzEjr7iYRP+6KxiOUnLs Khqge9cA25XyxZdxn421HLHv3XL3BJR/eI7EJ1GdIvQIWL5pL6/nNTdMvucoFOejfkzH yvNw== 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=LKraGJ30l6Da9gHXvZPSp4wo2q6s17TXGOTZwSnizRM=; b=D+RPBThXgh+J5du0/6xdydkdLuEi55ALjCQc0WKPsXcgMnaGFElovE5auzGty89ZX0 uPcRPIQca3F71TTr7IFX244ZwkVugFE9XXF9HSnwW1Vs6k8hQIH6TD4xo9VtOvbXKoi6 tkJaWxZE3X/+aISspgV8wgSshrQyuPOhOvuwbqiQfbbDbDkvUIEGGuMyd641PewYzIfz Z1fqyISgbzhu68cypITcUSxD1XnMvvQrp+8HyNOAIkSiJZWhymWFl5wceIV8pzQiR3Ux YNyWLHBuuyiToOSf87haqvwx0yV8WKRFQjiUD21VcVXjcDt3Mn/l73tlgA+WrGYYCXw0 dOPw== X-Gm-Message-State: ANhLgQ1q9FZOm0QKRsHKwpFW8a6BYMmZYTpTxbnXk7taMYhQ0ArSwEYy I6R81MtYlRHhBFR/482qUdGHVWgRlw7ezJF1gWbQfg== X-Google-Smtp-Source: ADFU+vuV0D3QIjqPpw7rA21p5bLAVNUkr3pTXiahSyMXLJ3IuwPm7ousgUlGjlBoJJ8eQPNDhN9e5l4QTnhzSuuZwbw= X-Received: by 2002:a25:c482:: with SMTP id u124mr4859412ybf.286.1583955157918; Wed, 11 Mar 2020 12:32:37 -0700 (PDT) MIME-Version: 1.0 References: <20200310185003.57344-1-irogers@google.com> <20200310195915.GA1676879@tassilo.jf.intel.com> <20200311161320.GA254105@krava> In-Reply-To: <20200311161320.GA254105@krava> From: Ian Rogers Date: Wed, 11 Mar 2020 12:32:26 -0700 Message-ID: Subject: Re: [PATCH] perf tools: add support for lipfm4 To: Jiri Olsa Cc: Stephane Eranian , Andi Kleen , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Namhyung Kim , Alexei Starovoitov , Daniel Borkmann , Martin KaFai Lau , Yonghong Song , Andrii Nakryiko , Greg Kroah-Hartman , Thomas Gleixner , Igor Lubashev , Alexey Budankov , Florian Fainelli , Adrian Hunter , Jiwei Sun , yuzhoujian , Kan Liang , Jin Yao , Leo Yan , John Garry , LKML , netdev@vger.kernel.org, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Sender: bpf-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: bpf@vger.kernel.org On Wed, Mar 11, 2020 at 9:13 AM Jiri Olsa wrote: > > On Tue, Mar 10, 2020 at 02:39:23PM -0700, Stephane Eranian wrote: > > On Tue, Mar 10, 2020 at 12:59 PM Andi Kleen wrote: > > > > > > On Tue, Mar 10, 2020 at 11:50:03AM -0700, Ian Rogers wrote: > > > > This patch links perf with the libpfm4 library. > > > > This library contains all the hardware event tables for all > > > > processors supported by perf_events. This is a helper library > > > > that help convert from a symbolic event name to the event > > > > encoding required by the underlying kernel interface. This > > > > library is open-source and available from: http://perfmon2.sf.net. > > > > > > For most CPUs the builtin perf JSON event support should make > > > this redundant. > > > > > We decided to post this patch to propose an alternative to the JSON > > file approach. It could be an option during the build. > > The libpfm4 library has been around for 15 years now. Therefore, it > > supports a lot of processors core and uncore and it is very portable. > > The key value add I see is that this is a library that can be, and has > > been, used by tool developers directly in their apps. It can > > work with more than Linux perf_events interface. It is not tied to the > > interface. It has well defined and documented entry points. > > We do use libpfm4 extensively at Google in both the perf tool and > > applications. The PAPI toolkit also relies on this library. > > > > I don't see this as competing with the JSON approach. It is just an > > option I'd like to offer to users especially those familiar > > with it in their apps. > > I dont mind having it, in fact I found really old email where I'm > asking Peter about that ;-) and he wasn't very keen about that: > https://lore.kernel.org/lkml/1312806326.10488.30.camel@twins/ > > not sure what was the actual reason at that time and if anything > changed since.. Peter? > > btw I can't apply even that v2 on latest Arnaldo's branch > > jirka Thanks Jiri, the patches were done on tip.git/master, perhaps there is a conflict with the Documents Makefile due to adding better man page dates? I'll try to repro building on https://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git/ on the perf/core branch unless you have a different suggestion? I also noticed a warning crept into the Makefile.config in the v2 patch set that should be removed. Ian