All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] Script style improvements in lib/coresight.sh
@ 2023-02-01 21:49 Diederik de Haas
  2023-02-01 21:49 ` [PATCH 1/2] perf test: Replace 'grep | wc -l' with 'grep -c' Diederik de Haas
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Diederik de Haas @ 2023-02-01 21:49 UTC (permalink / raw)
  To: Carsten Haitzler, Peter Zijlstra, Ingo Molnar,
	Arnaldo Carvalho de Melo
  Cc: Mark Rutland, Alexander Shishkin, Jiri Olsa, Namhyung Kim,
	linux-perf-users, linux-kernel, Diederik de Haas

These 2 patches improve the efficiency and quality of the
lib/coresight.sh script.

The first one uses grep's `-c` parameter to count the results instead of
piping it to `wc -l`.
The second one replaces the use of backticks (`...`) with $(...) as the
former has several potential issues while the latter does not.

Diederik de Haas (2):
  perf test: Replace 'grep | wc -l' with 'grep -c'
  perf test: Replace legacy `...` with $(...)

 tools/perf/tests/shell/lib/coresight.sh | 18 +++++++++---------
 1 file changed, 9 insertions(+), 9 deletions(-)

-- 
2.39.1


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2023-02-02 13:02 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-02-01 21:49 [PATCH 0/2] Script style improvements in lib/coresight.sh Diederik de Haas
2023-02-01 21:49 ` [PATCH 1/2] perf test: Replace 'grep | wc -l' with 'grep -c' Diederik de Haas
2023-02-01 21:49 ` [PATCH 2/2] perf test: Replace legacy `...` with $(...) Diederik de Haas
2023-02-02  1:53 ` [PATCH 0/2] Script style improvements in lib/coresight.sh Arnaldo Carvalho de Melo
2023-02-02  8:38 ` Carsten Haitzler
2023-02-02 13:00   ` Arnaldo Carvalho de Melo

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.