[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Z4alwvqYithaVLSL@x1>
Date: Tue, 14 Jan 2025 14:58:26 -0300
From: Arnaldo Carvalho de Melo <acme@...nel.org>
To: Charlie Jenkins <charlie@...osinc.com>
Cc: Peter Zijlstra <peterz@...radead.org>, Ingo Molnar <mingo@...hat.com>,
Namhyung Kim <namhyung@...nel.org>,
Mark Rutland <mark.rutland@....com>,
Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
Jiri Olsa <jolsa@...nel.org>, Ian Rogers <irogers@...gle.com>,
Adrian Hunter <adrian.hunter@...el.com>,
Paul Walmsley <paul.walmsley@...ive.com>,
Palmer Dabbelt <palmer@...belt.com>,
Mickaël Salaün <mic@...ikod.net>,
Günther Noack <gnoack@...gle.com>,
Christian Brauner <brauner@...nel.org>, Guo Ren <guoren@...nel.org>,
John Garry <john.g.garry@...cle.com>, Will Deacon <will@...nel.org>,
James Clark <james.clark@...aro.org>,
Mike Leach <mike.leach@...aro.org>, Leo Yan <leo.yan@...ux.dev>,
Jonathan Corbet <corbet@....net>, Arnd Bergmann <arnd@...db.de>,
linux-kernel@...r.kernel.org, linux-perf-users@...r.kernel.org,
linux-riscv@...ts.infradead.org,
linux-security-module@...r.kernel.org, bpf@...r.kernel.org,
linux-csky@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-doc@...r.kernel.org
Subject: Re: [PATCH v6 00/16] perf tools: Use generic syscall scripts for all
archs
On Mon, Jan 13, 2025 at 11:55:05AM -0300, Arnaldo Carvalho de Melo wrote:
> On Fri, Jan 10, 2025 at 11:31:01AM -0800, Charlie Jenkins wrote:
> > On Thu, Jan 09, 2025 at 03:00:59PM -0800, Charlie Jenkins wrote:
> > > Ooh okay I see, the quiet commands were being ignored as-is. We could
> > > add the lines to handle this to Makefile.syscalls, but I think the
> > > better solution is to move the lines from Makefile.build to
> > > Makefile.perf to be more generically available. Here is a patch for
> > > that. I also added the comment from the kernel Makefile describing what
> > > this does.
>
> > > From 8dcec7f5d937ede3d33c687573dc2f1654ddc59e Mon Sep 17 00:00:00 2001
> > > From: Charlie Jenkins <charlie@...osinc.com>
> > > Date: Thu, 9 Jan 2025 14:36:40 -0800
> > > Subject: [PATCH] perf tools: Expose quiet/verbose variables in Makefile.perf
> > >
> > > The variables to make builds silent/verbose live inside
> > > tools/build/Makefile.build. Move those variables to the top-level
> > > Makefile.perf to be generally available.
>
> <SNIP applied patch>
>
> > Let me know how you want to handle this, I can send this out as a
> > separate patch if that's better.
>
> I used the patch you provided above after hand editing the message
> before feeding it to 'git am', added these comments:
Somehow this is causing some trouble:
⬢ [acme@...lbox perf-tools-next]$ make -C tools/perf build-test
make: Entering directory '/home/acme/git/perf-tools-next/tools/perf'
- tarpkg: ./tests/perf-targz-src-pkg .
/bin/sh: line 1: @make: command not found
make[4]: *** [Makefile:27: clean-asm_pure_loop] Error 127
make[3]: *** [Makefile.perf:764: tests-coresight-targets-clean] Error 2
make[2]: *** [Makefile:96: clean] Error 2
make[1]: *** [tests/make:330: make_static] Error 2
make: *** [Makefile:109: build-test] Error 2
make: Leaving directory '/home/acme/git/perf-tools-next/tools/perf'
⬢ [acme@...lbox perf-tools-next]$
Can you please try fixing it as I'm busy now (I'll be on vacation from
tomorrow till early February)? This is what I extracted:
commit c199fd785d18121ffd0ba5758e23a42ba2984e11
Author: Charlie Jenkins <charlie@...osinc.com>
Date: Mon Jan 13 11:50:55 2025 -0300
perf tools: Expose quiet/verbose variables in Makefile.perf
The variables to make builds silent/verbose live inside
tools/build/Makefile.build. Move those variables to the top-level
Makefile.perf to be generally available.
Committer testing:
See the SYSCALL lines, now they are consistent with the other
operations in other lines:
SYSTBL /tmp/build/perf-tools-next/arch/x86/include/generated/asm/syscalls_32.h
SYSTBL /tmp/build/perf-tools-next/arch/x86/include/generated/asm/syscalls_64.h
GEN /tmp/build/perf-tools-next/common-cmds.h
GEN /tmp/build/perf-tools-next/arch/arm64/include/generated/asm/sysreg-defs.h
PERF_VERSION = 6.13.rc2.g3d94bb6ed1d0
GEN perf-archive
MKDIR /tmp/build/perf-tools-next/jvmti/
MKDIR /tmp/build/perf-tools-next/jvmti/
MKDIR /tmp/build/perf-tools-next/jvmti/
MKDIR /tmp/build/perf-tools-next/jvmti/
GEN perf-iostat
CC /tmp/build/perf-tools-next/jvmti/libjvmti.o
CC /tmp/build/perf-tools-next/jvmti/jvmti_agent.o
Reported-by: Arnaldo Carvalho de Melo <acme@...hat.com>
Signed-off-by: Charlie Jenkins <charlie@...osinc.com>
Tested-by: Arnaldo Carvalho de Melo <acme@...hat.com>
Cc: Adrian Hunter <adrian.hunter@...el.com>
Cc: Alexander Shishkin <alexander.shishkin@...ux.intel.com>
Cc: Arnd Bergmann <arnd@...db.de>
Cc: Christian Brauner <brauner@...nel.org>
Cc: Guo Ren <guoren@...nel.org>
Cc: Günther Noack <gnoack@...gle.com>
Cc: Ian Rogers <irogers@...gle.com>
Cc: Ingo Molnar <mingo@...hat.com>
Cc: James Clark <james.clark@...aro.org>
Cc: Jiri Olsa <jolsa@...nel.org>
Cc: John Garry <john.g.garry@...cle.com>
Cc: Jonathan Corbet <corbet@....net>
Cc: Leo Yan <leo.yan@...ux.dev>
Cc: Mark Rutland <mark.rutland@....com>
Cc: Mickaël Salaün <mic@...ikod.net>
Cc: Mike Leach <mike.leach@...aro.org>
Cc: Namhyung Kim <namhyung@...nel.org>
Cc: Palmer Dabbelt <palmer@...belt.com>
Cc: Paul Walmsley <paul.walmsley@...ive.com>
Cc: Peter Zijlstra <peterz@...radead.org>
Cc: Will Deacon <will@...nel.org>
Link: http://lore.kernel.org/lkml/None
Signed-off-by: Arnaldo Carvalho de Melo <acme@...hat.com>
diff --git a/tools/build/Makefile.build b/tools/build/Makefile.build
index 5fb3fb3d97e0fd11..e710ed67a1b49d9f 100644
--- a/tools/build/Makefile.build
+++ b/tools/build/Makefile.build
@@ -12,26 +12,6 @@
PHONY := __build
__build:
-ifeq ($(V),1)
- quiet =
- Q =
-else
- quiet=quiet_
- Q=@
-endif
-
-# If the user is running make -s (silent mode), suppress echoing of commands
-# make-4.0 (and later) keep single letter options in the 1st word of MAKEFLAGS.
-ifeq ($(filter 3.%,$(MAKE_VERSION)),)
-short-opts := $(firstword -$(MAKEFLAGS))
-else
-short-opts := $(filter-out --%,$(MAKEFLAGS))
-endif
-
-ifneq ($(findstring s,$(short-opts)),)
- quiet=silent_
-endif
-
build-dir := $(srctree)/tools/build
# Define $(fixdep) for dep-cmd function
diff --git a/tools/perf/Makefile.perf b/tools/perf/Makefile.perf
index a449d00155364422..55d6ce9ea52fb2a5 100644
--- a/tools/perf/Makefile.perf
+++ b/tools/perf/Makefile.perf
@@ -161,12 +161,47 @@ export VPATH
SOURCE := $(shell ln -sf $(srctree)/tools/perf $(OUTPUT)/source)
endif
+# Beautify output
+# ---------------------------------------------------------------------------
+#
+# Most of build commands in Kbuild start with "cmd_". You can optionally define
+# "quiet_cmd_*". If defined, the short log is printed. Otherwise, no log from
+# that command is printed by default.
+#
+# e.g.)
+# quiet_cmd_depmod = DEPMOD $(MODLIB)
+# cmd_depmod = $(srctree)/scripts/depmod.sh $(DEPMOD) $(KERNELRELEASE)
+#
+# A simple variant is to prefix commands with $(Q) - that's useful
+# for commands that shall be hidden in non-verbose mode.
+#
+# $(Q)$(MAKE) $(build)=scripts/basic
+#
+# To put more focus on warnings, be less verbose as default
+# Use 'make V=1' to see the full commands
+
ifeq ($(V),1)
+ quiet =
Q =
else
- Q = @
+ quiet=quiet_
+ Q=@
endif
+# If the user is running make -s (silent mode), suppress echoing of commands
+# make-4.0 (and later) keep single letter options in the 1st word of MAKEFLAGS.
+ifeq ($(filter 3.%,$(MAKE_VERSION)),)
+short-opts := $(firstword -$(MAKEFLAGS))
+else
+short-opts := $(filter-out --%,$(MAKEFLAGS))
+endif
+
+ifneq ($(findstring s,$(short-opts)),)
+ quiet=silent_
+endif
+
+export quiet Q
+
# Do not use make's built-in rules
# (this improves performance and avoids hard-to-debug behaviour);
MAKEFLAGS += -r
Powered by blists - more mailing lists