[RFC 1/6] perf probe: Do not exclude mangled C++ funcs

From: Holger Freyther
Date: Mon May 14 2018 - 00:28:49 EST


From: Holger Hans Peter Freyther <holgar+kernel@xxxxxxxxxx>

Using --funcs --no-demangle on a C++ binary does not list any of the C++
functions. Change the default filter to not exclude the Common C++ ABI
symbols.

$ ./perf probe -x ./cxx-example --funcs --no-demangle
...
_ZN9__gnu_cxx13new_allocatorIiEC1Ev
...

Signed-off-by: Holger Hans Peter Freyther <holgar+kernel@xxxxxxxxxx>
---
tools/perf/builtin-probe.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/perf/builtin-probe.c b/tools/perf/builtin-probe.c
index c006592..d69f679 100644
--- a/tools/perf/builtin-probe.c
+++ b/tools/perf/builtin-probe.c
@@ -43,7 +43,7 @@
#include "util/probe-file.h"

#define DEFAULT_VAR_FILTER "!__k???tab_* & !__crc_*"
-#define DEFAULT_FUNC_FILTER "!_*"
+#define DEFAULT_FUNC_FILTER "!_* | _Z*"
#define DEFAULT_LIST_FILTER "*"

/* Session management structure */
--
2.7.4