From d4ce60190e08d84f88937019defa5e3d23409ac1 Mon Sep 17 00:00:00 2001 From: Ian Rogers Date: Mon, 11 Sep 2023 10:05:56 -0700 Subject: [PATCH] perf parse-events: Make YYDEBUG dependent on doing a debug build YYDEBUG enables line numbers and other error helpers in the generated parse-events-bison.c. These shouldn't be generated when debugging isn't enabled. Signed-off-by: Ian Rogers Acked-by: Namhyung Kim Cc: Adrian Hunter Cc: Alexander Shishkin Cc: Gaosheng Cui Cc: Ingo Molnar Cc: James Clark Cc: Jiri Olsa Cc: Kan Liang Cc: Mark Rutland Cc: Peter Zijlstra Cc: Rob Herring Cc: bpf@vger.kernel.org Link: https://lore.kernel.org/r/20230911170559.4037734-2-irogers@google.com Signed-off-by: Arnaldo Carvalho de Melo --- tools/perf/util/parse-events.y | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tools/perf/util/parse-events.y b/tools/perf/util/parse-events.y index dcadf08f840a..c4ce888a2550 100644 --- a/tools/perf/util/parse-events.y +++ b/tools/perf/util/parse-events.y @@ -6,7 +6,9 @@ %{ +#ifndef NDEBUG #define YYDEBUG 1 +#endif #include #include