perf build: Add -funsigned-char to default CFLAGS
Ian Rogers
reviewerPATCH 1/1 perf build: Add -funsigned-char to default CFLAGS
Commit 3bc753c06dd0 ("kbuild: treat char as always unsigned") made chars unsigned by default in the Linux kernel. To avoid similar kinds of bugs and warnings, make unsigned chars the default for the perf tool.
--- tools/perf/Makefile.config | 1 + 1 file changed, 1 insertion(+)
tools/perf/Makefile.config +1 -0
@@ -349,6 +349,7 @@ CORE_CFLAGS += -fno-omit-frame-pointer CORE_CFLAGS += -Wall CORE_CFLAGS += -Wextra CORE_CFLAGS += -std=gnu11 +CORE_CFLAGS += -funsigned-char CXXFLAGS += -std=gnu++17 -fno-exceptions -fno-rtti CXXFLAGS += -Wall
Signature · 1 line
2.53.0.473.g4a7958ca14-goog
Ian Rogers
reviewerQuoted 6 lines · Ian Rogers
Commit
3bc753c06dd0("kbuild: treat char as always unsigned") made chars unsigned by default in the Linux kernel. To avoid similar kinds of bugs and warnings, make unsigned chars the default for the perf tool.Signed-off-by Ian Rogers <[email protected]>
Ping.
Thanks,
Ian
Quoted 19 lines
--- tools/perf/Makefile.config | 1 + 1 file changed, 1 insertion(+)tools/perf/Makefile.config +1
-1@@ -349,6 +349,7 @@ CORE_CFLAGS += -fno-omit-frame-pointer CORE_CFLAGS += -Wall CORE_CFLAGS += -Wextra CORE_CFLAGS += -std=gnu11 +CORE_CFLAGS += -funsigned-char CXXFLAGS += -std=gnu++17 -fno-exceptions -fno-rtti CXXFLAGS += -Wall --2.53.0.473.g4a7958ca14-goog
Namhyung Kim
maintainerQuoted 7 lines · Ian Rogers
Quoted 6 lines · Ian Rogers
Commit
3bc753c06dd0("kbuild: treat char as always unsigned") made chars unsigned by default in the Linux kernel. To avoid similar kinds of bugs and warnings, make unsigned chars the default for the perf tool.Signed-off-by Ian Rogers <[email protected]>
Do you know what the actual bug was?
Thanks,
Namhyung
Quoted 20 lines
Quoted 20 lines
--- tools/perf/Makefile.config | 1 + 1 file changed, 1 insertion(+)tools/perf/Makefile.config +1
-1@@ -349,6 +349,7 @@ CORE_CFLAGS += -fno-omit-frame-pointer CORE_CFLAGS += -Wall CORE_CFLAGS += -Wextra CORE_CFLAGS += -std=gnu11 +CORE_CFLAGS += -funsigned-char CXXFLAGS += -std=gnu++17 -fno-exceptions -fno-rtti CXXFLAGS += -Wall --2.53.0.473.g4a7958ca14-goog
Ian Rogers
reviewerQuoted 11 lines · Namhyung Kim
Quoted 7 lines · Ian Rogers
Quoted 6 lines · Ian Rogers
Commit
3bc753c06dd0("kbuild: treat char as always unsigned") made chars unsigned by default in the Linux kernel. To avoid similar kinds of bugs and warnings, make unsigned chars the default for the perf tool.Signed-off-by Ian Rogers <[email protected]>Do you know what the actual bug was?
I don't, my motivation was to try to avoid sashiko warnings about issues that occur with signed chars.
Thanks,
Ian
Quoted 23 lines
Thanks,
NamhyungQuoted 20 lines
Quoted 20 lines
--- tools/perf/Makefile.config | 1 + 1 file changed, 1 insertion(+)tools/perf/Makefile.config +1
-1@@ -349,6 +349,7 @@ CORE_CFLAGS += -fno-omit-frame-pointer CORE_CFLAGS += -Wall CORE_CFLAGS += -Wextra CORE_CFLAGS += -std=gnu11 +CORE_CFLAGS += -funsigned-char CXXFLAGS += -std=gnu++17 -fno-exceptions -fno-rtti CXXFLAGS += -Wall --2.53.0.473.g4a7958ca14-goog
Ian Rogers
reviewerQuoted 10 lines · Ian Rogers
Quoted 8 lines · Namhyung Kim
Quoted 6 lines · Ian Rogers
Quoted 5 lines · Ian Rogers
Commit
3bc753c06dd0("kbuild: treat char as always unsigned") made chars unsigned by default in the Linux kernel. To avoid similar kinds of bugs and warnings, make unsigned chars the default for the perf tool.
Quoted 6 lines
Quoted 3 lines
Quoted 1 line
Quoted 1 line
Signed-off-by Ian Rogers <[email protected]>Do you know what the actual bug was?
I don't, my motivation was to try to avoid sashiko warnings about issues that occur with signed chars.
Ping.
Thanks,
Ian
Quoted 26 lines
Thanks,
IanQuoted 23 lines
Thanks,
NamhyungQuoted 20 lines
Quoted 20 lines
--- tools/perf/Makefile.config | 1 + 1 file changed, 1 insertion(+)tools/perf/Makefile.config +1
-1@@ -349,6 +349,7 @@ CORE_CFLAGS += -fno-omit-frame-pointer CORE_CFLAGS += -Wall CORE_CFLAGS += -Wextra CORE_CFLAGS += -std=gnu11 +CORE_CFLAGS += -funsigned-char CXXFLAGS += -std=gnu++17 -fno-exceptions -fno-rtti CXXFLAGS += -Wall --2.53.0.473.g4a7958ca14-goog
Quoted 5 lines · Ian Rogers
Commit
3bc753c06dd0("kbuild: treat char as always unsigned") made chars unsigned by default in the Linux kernel. To avoid similar kinds of bugs and warnings, make unsigned chars the default for the perf tool.
Applied to perf-tools-next, thanks!
Best regards,
Namhyung