Running prlimit on either arm64 or ppc64[le] gets this WARNING: ==19848== Command: prlimit ==19848== --19848-- WARNING: unhandled arm64-linux syscall: 261 --19848-- You may be able to write your own handler. --19848-- Read the file README_MISSING_SYSCALL_OR_IOCTL. --19848-- Nevertheless we consider this a bug. Please report --19848-- it at http://valgrind.org/support/bug_reports.html. prlimit: failed to get the AS resource limit: Function not implemented ==14990== Command: prlimit ==14990== --14990-- WARNING: unhandled ppc64le-linux syscall: 325 --14990-- You may be able to write your own handler. --14990-- Read the file README_MISSING_SYSCALL_OR_IOCTL. --14990-- Nevertheless we consider this a bug. Please report --14990-- it at http://valgrind.org/support/bug_reports.html. prlimit: failed to get the AS resource limit: Function not implemented The fix is simply to hook both syscalls to the already existing wrapper: diff --git a/coregrind/m_syswrap/syswrap-arm64-linux.c b/coregrind/m_syswrap/syswrap-arm64-linux.c index 1be6629..f8b5b7c 100644 --- a/coregrind/m_syswrap/syswrap-arm64-linux.c +++ b/coregrind/m_syswrap/syswrap-arm64-linux.c @@ -868,6 +868,7 @@ static SyscallTableEntry syscall_main_table[] = { LINXY(__NR_recvmmsg, sys_recvmmsg), // 243 GENXY(__NR_wait4, sys_wait4), // 260 + LINXY(__NR_prlimit64, sys_prlimit64), // 261 LINXY(__NR_name_to_handle_at, sys_name_to_handle_at), // 264 LINXY(__NR_open_by_handle_at, sys_open_by_handle_at), // 265 diff --git a/coregrind/m_syswrap/syswrap-ppc64-linux.c b/coregrind/m_syswrap/syswrap-ppc64-linux.c index f90140d..ce5cbbb 100644 --- a/coregrind/m_syswrap/syswrap-ppc64-linux.c +++ b/coregrind/m_syswrap/syswrap-ppc64-linux.c @@ -905,6 +905,7 @@ static SyscallTableEntry syscall_table[] = { LINX_(__NR_pwritev, sys_pwritev), // 321 LINXY(__NR_rt_tgsigqueueinfo, sys_rt_tgsigqueueinfo),// 322 + LINXY(__NR_prlimit64, sys_prlimit64), // 325 LINXY(__NR_socket, sys_socket), // 326 LINX_(__NR_bind, sys_bind), // 327 LINX_(__NR_connect, sys_connect), // 328
valgrind svn r16228