perf bench messaging: Fix the formatting issue when printing.
PATCH 1/1 perf bench messaging: Fix the formatting issue when printing.
The unsigned int type should use the %u format specifier when printing with printf or related functions.
--- tools/perf/bench/sched-messaging.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
tools/perf/bench/sched-messaging.c +2 -2
@@ -338,9 +338,9 @@ int bench_sched_messaging(int argc, const char **argv)switch (bench_format) {case BENCH_FORMAT_DEFAULT : -printf ("# %d sender and receiver %s per group\n" , +printf ("# %u sender and receiver %s per group\n" , num_fds, thread_mode ?"threads" :"processes" ); -printf ("# %d groups == %d %s run\n\n" , +printf ("# %u groups == %u %s run\n\n" , num_groups, num_groups *2 * num_fds, thread_mode ?"threads" :"processes" ); printf(" %14s: %lu.%03lu [sec]\n", "Total time",
Signature · 1 line
2.27.0
Ian Rogers
reviewerPATCH 1/1 perf bench messaging: Fix the formatting issue when printing.
From: liujing <[email protected]>
The unsigned int type should use the %u format specifier when printing with printf or related functions.
--- tools/perf/bench/sched-messaging.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
tools/perf/bench/sched-messaging.c +2 -2
@@ -338,9 +338,9 @@ int bench_sched_messaging(int argc, const char **argv)switch (bench_format) {case BENCH_FORMAT_DEFAULT : -printf ("# %d sender and receiver %s per group\n" , +printf ("# %u sender and receiver %s per group\n" , num_fds, thread_mode ?"threads" :"processes" ); -printf ("# %d groups == %d %s run\n\n" , +printf ("# %u groups == %u %s run\n\n" , num_groups, num_groups *2 * num_fds, thread_mode ?"threads" :"processes" ); printf(" %14s: %lu.%03lu [sec]\n", "Total time",
Signature · 1 line
2.55.0.1032.g73a4cd73de-goog
[email protected]
AI reviewSashiko has reviewed this patch and found no issues. It looks great!
Quoted 6 lines
From: liujing <[email protected]>
The unsigned int type should use the %u format specifier when printing with printf or related functions.
Signed-off-by liujing <[email protected]>
Sashiko has reviewed this patch and found no issues. It looks great!
Signature · 1 line
Sashiko AI review · https://sashiko.dev/#/patchset/[email protected]?part=1
Quoted 7 lines · Ian Rogers
From: liujing <[email protected]>
The unsigned int type should use the %u format specifier when printing with printf or related functions.
Signed-off-by liujing <[email protected]>Reviewed-by Ian Rogeres <[email protected]>
s/Rogeres/Rogers/g
Applied,
- Arnaldo
Quoted 22 lines
--- tools/perf/bench/sched-messaging.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)tools/perf/bench/sched-messaging.c +2
-2@@ -338,9 +338,9 @@ int bench_sched_messaging(int argc, const char **argv)switch (bench_format) {case BENCH_FORMAT_DEFAULT : -printf ("# %d sender and receiver %s per group\n" , +printf ("# %u sender and receiver %s per group\n" , num_fds, thread_mode ?"threads" :"processes" ); -printf ("# %d groups == %d %s run\n\n" , +printf ("# %u groups == %u %s run\n\n" , num_groups, num_groups *2 * num_fds, thread_mode ?"threads" :"processes" ); printf(" %14s: %lu.%03lu [sec]\n", "Total time",Signature · 1 line
2.55.0.1032.g73a4cd73de-goog