[v4,0/4] perf: Add more syscalls to benchmark

Message ID 1667982547-22331-1-git-send-email-yangtiezhu@loongson.cn
Headers
Series perf: Add more syscalls to benchmark |

Message

Tiezhu Yang Nov. 9, 2022, 8:29 a.m. UTC
  Tiezhu Yang (4):
  tools x86: Keep list sorted by number in unistd_{32,64}.h
  perf bench syscall: Introduce bench_syscall_common()
  perf bench syscall: Add getpgrp syscall benchmark
  perf bench syscall: Add execve syscall benchmark

 tools/arch/x86/include/uapi/asm/unistd_32.h | 23 ++++++---
 tools/arch/x86/include/uapi/asm/unistd_64.h | 23 ++++++---
 tools/perf/bench/bench.h                    |  2 +
 tools/perf/bench/syscall.c                  | 76 +++++++++++++++++++++++++++--
 tools/perf/builtin-bench.c                  |  2 +
 5 files changed, 108 insertions(+), 18 deletions(-)
  

Comments

Namhyung Kim Nov. 9, 2022, 6:15 p.m. UTC | #1
Hello,

On Wed, Nov 9, 2022 at 12:29 AM Tiezhu Yang <yangtiezhu@loongson.cn> wrote:
>
> Tiezhu Yang (4):
>   tools x86: Keep list sorted by number in unistd_{32,64}.h
>   perf bench syscall: Introduce bench_syscall_common()
>   perf bench syscall: Add getpgrp syscall benchmark
>   perf bench syscall: Add execve syscall benchmark

Have you tested it on non-x86 too?  It seems you only added the syscall
numbers to x86.

Thanks,
Namhyung


>
>  tools/arch/x86/include/uapi/asm/unistd_32.h | 23 ++++++---
>  tools/arch/x86/include/uapi/asm/unistd_64.h | 23 ++++++---
>  tools/perf/bench/bench.h                    |  2 +
>  tools/perf/bench/syscall.c                  | 76 +++++++++++++++++++++++++++--
>  tools/perf/builtin-bench.c                  |  2 +
>  5 files changed, 108 insertions(+), 18 deletions(-)
>
> --
> 2.1.0
>
  
Tiezhu Yang Nov. 10, 2022, 1:58 a.m. UTC | #2
On 11/10/2022 02:15 AM, Namhyung Kim wrote:
> Hello,
>
> On Wed, Nov 9, 2022 at 12:29 AM Tiezhu Yang <yangtiezhu@loongson.cn> wrote:
>>
>> Tiezhu Yang (4):
>>   tools x86: Keep list sorted by number in unistd_{32,64}.h
>>   perf bench syscall: Introduce bench_syscall_common()
>>   perf bench syscall: Add getpgrp syscall benchmark
>>   perf bench syscall: Add execve syscall benchmark
>
> Have you tested it on non-x86 too?  It seems you only added the syscall
> numbers to x86.
>

Hi Namhyung,

Thank you for your reply.

I tested only on x86, when build on arm64, there exists
the following build error:

error: ‘__NR_getpgrp’ undeclared (first use in this function)

this is because __NR_getpgrp is deprecated on some archs.

Sorry for that, let me use getpgid, I will test on x86_64, arm64,
mips64 and loongarch64, and then send v5, thank you.

Thanks,
Tiezhu