All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] perf parse: Allow names to start with digits
@ 2022-06-12  6:15 Dominique Martinet
  2022-07-02  9:49 ` Dominique Martinet
  2022-07-04 21:39 ` Ian Rogers
  0 siblings, 2 replies; 11+ messages in thread
From: Dominique Martinet @ 2022-06-12  6:15 UTC (permalink / raw)
  To: Peter Zijlstra, Ingo Molnar, Arnaldo Carvalho de Melo,
	Mark Rutland, Alexander Shishkin, Jiri Olsa, Namhyung Kim
  Cc: Dominique Martinet, linux-perf-users, linux-kernel

Tracepoints can start with digits, although we don't have many of these:

$ rg -g '*.h' '\bTRACE_EVENT\([0-9]'
net/mac802154/trace.h
53:TRACE_EVENT(802154_drv_return_int,
...

net/ieee802154/trace.h
66:TRACE_EVENT(802154_rdev_add_virtual_intf,
...

include/trace/events/9p.h
124:TRACE_EVENT(9p_client_req,
...

Just allow names to start with digits too so e.g. perf probe -e '9p:*'
works

Signed-off-by: Dominique Martinet <asmadeus@codewreck.org>
---
 tools/perf/util/parse-events.l | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/perf/util/parse-events.l b/tools/perf/util/parse-events.l
index 5b6e4b5249cf..4133d6950d29 100644
--- a/tools/perf/util/parse-events.l
+++ b/tools/perf/util/parse-events.l
@@ -211,7 +211,7 @@ bpf_source	[^,{}]+\.c[a-zA-Z0-9._]*
 num_dec		[0-9]+
 num_hex		0x[a-fA-F0-9]+
 num_raw_hex	[a-fA-F0-9]+
-name		[a-zA-Z_*?\[\]][a-zA-Z0-9_*?.\[\]!]*
+name		[a-zA-Z0-9_*?\[\]][a-zA-Z0-9_*?.\[\]!]*
 name_tag	[\'][a-zA-Z_*?\[\]][a-zA-Z0-9_*?\-,\.\[\]:=]*[\']
 name_minus	[a-zA-Z_*?][a-zA-Z0-9\-_*?.:]*
 drv_cfg_term	[a-zA-Z0-9_\.]+(=[a-zA-Z0-9_*?\.:]+)?
-- 
2.36.1


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

end of thread, other threads:[~2022-10-10 14:06 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-12  6:15 [PATCH] perf parse: Allow names to start with digits Dominique Martinet
2022-07-02  9:49 ` Dominique Martinet
2022-07-02 12:24   ` Arnaldo Carvalho de Melo
2022-07-02 15:48     ` Jiri Olsa
2022-07-02 23:51       ` Dominique Martinet
2022-07-03 13:46         ` Jiri Olsa
2022-07-03 23:58           ` Dominique Martinet
2022-07-04 11:25             ` Jiri Olsa
2022-10-10  5:38               ` Dominique Martinet
2022-10-10 14:05                 ` Jiri Olsa
2022-07-04 21:39 ` Ian Rogers

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.