perf parse-events: Remove unused header files
Subsystems (2)
Ian Rogers
reviewerPATCH 1/5 perf parse-events: Remove unused header files
The fnmatch header is now used in the PMU matching logic in pmu.c.
--- tools/perf/util/parse-events.y | 3 --- 1 file changed, 3 deletions(-)
tools/perf/util/parse-events.y +0 -3
@@ -9,11 +9,8 @@ #define YYDEBUG 1 #include <errno.h> -#include <fnmatch.h> -#include <stdio.h> #include <linux/compiler.h> #include <linux/types.h> -#include <linux/zalloc.h> #include "pmu.h" #include "pmus.h" #include "evsel.h"
Signature · 1 line
2.42.0.283.g2d96d420d3-goog
Ian Rogers
reviewerPATCH 2/5 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.
--- tools/perf/util/parse-events.y | 2 ++ 1 file changed, 2 insertions(+)
tools/perf/util/parse-events.y +2 -0
@@ -6,7 +6,9 @@ %{ +#ifndef NDEBUG #define YYDEBUG 1 +#endif #include <errno.h> #include <linux/compiler.h>
Signature · 1 line
2.42.0.283.g2d96d420d3-goog
Re: [PATCH v1 2/5] perf parse-events: Make YYDEBUG dependent on doing a debug build
Quoted 6 lines · Ian Rogers
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 <[email protected]>
Thanks,
Namhyung
Quoted 21 lines
--- tools/perf/util/parse-events.y | 2 ++ 1 file changed, 2 insertions(+)tools/perf/util/parse-events.y +2
-1@@ -6,7 +6,9 @@ %{ +#ifndef NDEBUG #define YYDEBUG 1 +#endif #include <errno.h> #include <linux/compiler.h> --2.42.0.283.g2d96d420d3-goog
Ian Rogers
reviewerPATCH 3/5 perf expr: Make YYDEBUG dependent on doing a debug build
In reply to Ian RogersYYDEBUG enables line numbers and other error helpers in the generated expr-bison.c. These shouldn't be generated when debugging isn't enabled.
--- tools/perf/util/expr.y | 2 ++ 1 file changed, 2 insertions(+)
tools/perf/util/expr.y +2 -0
@@ -1,6 +1,8 @@ /* Simple expression parser */ %{ +#ifndef NDEBUG #define YYDEBUG 1 +#endif #include <assert.h> #include <math.h> #include <stdlib.h>
Signature · 1 line
2.42.0.283.g2d96d420d3-goog
Re: [PATCH v1 3/5] perf expr: Make YYDEBUG dependent on doing a debug build
Quoted 6 lines · Ian Rogers
YYDEBUG enables line numbers and other error helpers in the generated
expr-bison.c. These shouldn't be generated when debugging isn't enabled.Signed-off-by Ian Rogers <[email protected]>
Thanks,
Namhyung
Quoted 20 lines
--- tools/perf/util/expr.y | 2 ++ 1 file changed, 2 insertions(+)tools/perf/util/expr.y +2
-1@@ -1,6 +1,8 @@ /* Simple expression parser */ %{ +#ifndef NDEBUG #define YYDEBUG 1 +#endif #include <assert.h> #include <math.h> #include <stdlib.h> --2.42.0.283.g2d96d420d3-goog
Ian Rogers
reviewerPATCH 4/5 perf pmu: Add YYDEBUG
In reply to Ian RogersYYDEBUG enables line numbers and other error helpers in the generated pmu-bison.c. Conditionally enabled only for debug builds.
--- tools/perf/util/pmu.y | 4 ++++ 1 file changed, 4 insertions(+)
tools/perf/util/pmu.y +4 -0
@@ -5,6 +5,10 @@ %{ +#ifndef NDEBUG +#define YYDEBUG 1 +#endif + #include <linux/compiler.h> #include <linux/list.h> #include <linux/bitmap.h>
Signature · 1 line
2.42.0.283.g2d96d420d3-goog
Re: [PATCH v1 4/5] perf pmu: Add YYDEBUG
Quoted 5 lines · Ian Rogers
YYDEBUG enables line numbers and other error helpers in the generated
pmu-bison.c. Conditionally enabled only for debug builds.Signed-off-by Ian Rogers <[email protected]>
Thanks,
Namhyung
Quoted 22 lines
--- tools/perf/util/pmu.y | 4 ++++ 1 file changed, 4 insertions(+)tools/perf/util/pmu.y +4
-1@@ -5,6 +5,10 @@ %{ +#ifndef NDEBUG +#define YYDEBUG 1 +#endif + #include <linux/compiler.h> #include <linux/list.h> #include <linux/bitmap.h> --2.42.0.283.g2d96d420d3-goog
Ian Rogers
reviewerPATCH 5/5 perf bpf-filter: Add YYDEBUG
In reply to Ian RogersYYDEBUG enables line numbers and other error helpers in the generated bpf-filter-bison.c. Conditionally enabled only for debug builds.
--- tools/perf/util/bpf-filter.y | 4 ++++ 1 file changed, 4 insertions(+)
tools/perf/util/bpf-filter.y +4 -0
@@ -3,6 +3,10 @@ %{ +#ifndef NDEBUG +#define YYDEBUG 1 +#endif + #include <stdio.h> #include <string.h> #include <linux/compiler.h>
Signature · 1 line
2.42.0.283.g2d96d420d3-goog
Re: [PATCH v1 5/5] perf bpf-filter: Add YYDEBUG
Quoted 5 lines · Ian Rogers
YYDEBUG enables line numbers and other error helpers in the generated
bpf-filter-bison.c. Conditionally enabled only for debug builds.Signed-off-by Ian Rogers <[email protected]>
Thanks,
Namhyung
Quoted 22 lines
--- tools/perf/util/bpf-filter.y | 4 ++++ 1 file changed, 4 insertions(+)tools/perf/util/bpf-filter.y +4
-1@@ -3,6 +3,10 @@ %{ +#ifndef NDEBUG +#define YYDEBUG 1 +#endif + #include <stdio.h> #include <string.h> #include <linux/compiler.h> --2.42.0.283.g2d96d420d3-goog
Quoted 4 lines · Ian Rogers
The fnmatch header is now used in the PMU matching logic in
pmu.c.Signed-off-by Ian Rogers <[email protected]>
Thanks,
Namhyung
Quoted 23 lines
--- tools/perf/util/parse-events.y | 3 --- 1 file changed, 3 deletions(-)tools/perf/util/parse-events.y +0
-4@@ -9,11 +9,8 @@ #define YYDEBUG 1 #include <errno.h> -#include <fnmatch.h> -#include <stdio.h> #include <linux/compiler.h> #include <linux/types.h> -#include <linux/zalloc.h> #include "pmu.h" #include "pmus.h" #include "evsel.h" --2.42.0.283.g2d96d420d3-goog
Em Mon, Sep 11, 2023 at 10:58:18PM -0700, Namhyung Kim escreveu:
Quoted 7 lines · Ian Rogers
Quoted 4 lines
The fnmatch header is now used in the PMU matching logic in
pmu.c.Signed-off-by Ian Rogers <[email protected]>Acked-by Namhyung Kim <[email protected]>
Thanks, applied the series.
- Arnaldo
Quoted 26 lines
Thanks,
NamhyungQuoted 23 lines
--- tools/perf/util/parse-events.y | 3 --- 1 file changed, 3 deletions(-)tools/perf/util/parse-events.y +0
-4@@ -9,11 +9,8 @@ #define YYDEBUG 1 #include <errno.h> -#include <fnmatch.h> -#include <stdio.h> #include <linux/compiler.h> #include <linux/types.h> -#include <linux/zalloc.h> #include "pmu.h" #include "pmus.h" #include "evsel.h" --2.42.0.283.g2d96d420d3-goog
Signature · 1 line
- Arnaldo