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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id ABC5AC433EF for ; Wed, 11 May 2022 13:57:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243136AbiEKN5U (ORCPT ); Wed, 11 May 2022 09:57:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40530 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244327AbiEKN5N (ORCPT ); Wed, 11 May 2022 09:57:13 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5978D4755F; Wed, 11 May 2022 06:57:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=8bafPVpeXgttnp0NnvgkWAZnnHNGWJEw+q1LuEA1XVE=; b=PgtUhcQVkIAqRO3ULeZVr6yhOc wbqqsexomZ6YO/UDSDcR6QdG4PWCjGeBfHnk7Z5/OuUccmJGygI+1sPteJruESD5+f6ql6e1jMmO9 rcO1nQjJdVkiOYpjKvlbrWWw04gD5r2eiwmgOJ5sBgc6Ees+sS78Pvo2hHqR2oFyoMI8cNOTYbizB EJjBmeWHyDpAwTgSQFsORs6149JstbAP8DCjV3ef1O4mcir+lDt4wZNrkBN2k5TSa8VJtZUigAEuf MR7fHiL4nwGs2Qc4r157vdGRY6rGA2nsegya5rPg6uCY7KQwXhKvX4CmyhmH6qcWdKVrxfTeP7wsz O4Tx9Tpw==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=worktop.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nomox-005UpG-Qv; Wed, 11 May 2022 13:56:07 +0000 Received: by worktop.programming.kicks-ass.net (Postfix, from userid 1000) id 69200980E5D; Wed, 11 May 2022 15:56:05 +0200 (CEST) Date: Wed, 11 May 2022 15:56:05 +0200 From: Peter Zijlstra To: Ian Rogers Cc: Ingo Molnar , Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Jiri Olsa , Namhyung Kim , John Garry , Kan Liang , Andi Kleen , Zhengjun Xing , Felix Fietkau , Qi Liu , Like Xu , linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org, Nick Forrington , Kajol Jain , James Clark , Andrew Kilroy , "Paul A . Clarke" , Will Deacon , Mathieu Poirier , ananth.narayan@amd.com, ravi.bangoria@amd.com, santosh.shukla@amd.com, sandipan.das@amd.com, Caleb Biggers , Perry Taylor , Kshipra Bopardikar , Stephane Eranian Subject: Re: [PATCH 0/7] Rewrite jevents program in python Message-ID: <20220511135605.GA76023@worktop.programming.kicks-ass.net> References: <20220511070133.710721-1-irogers@google.com> <20220511073501.GW76023@worktop.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, May 11, 2022 at 06:50:59AM -0700, Ian Rogers wrote: > On Wed, May 11, 2022 at 12:35 AM Peter Zijlstra wrote: > > > > On Wed, May 11, 2022 at 12:01:26AM -0700, Ian Rogers wrote: > > > > > The changes here switch from jevents.c to a rewrite in python called > > > jevents.py. This means there is a build time dependency on python, but > > > such a dependency already exists for asciidoc (used to generate perf's > > > man pages). > > > > You mean just building perf (not the docs) will now require snake stuff? > > > > That's very tedious :/ I don't typically have snakes on my machines. > > Hi Peter, > > You're right that after these changes python is a build requirement > for jevents. We could keep the C code around for the case that python > isn't there, but I want to do things like remove the string > relocations, sort the events by name so we don't linearly search, etc. > which would be a massive chore to keep alive on the C side. An > alternative would be to have an empty pmu-events.c file that is used > for this case. If you wanted to keep things in C and have jevents like > event names, you could use the empty version and link in libpfm4. I'm not normally linking to libpfm4. All I really care about is that I can still build a bare cli perf (not even tui). If all the snake stuff is purely optional and it just disables some features, but I do get a perf out at the end, then I'm all good.