Projects
Mega:24.03:SP1:Everything
systemtap
_service:tar_scm:Add-basic-LoongArch64-support....
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File _service:tar_scm:Add-basic-LoongArch64-support.patch of Package systemtap
From 3c7f981349c02da5baee0d1f721571078aa6bbc6 Mon Sep 17 00:00:00 2001 From: wangqiang <wangqiang1@kylinos.cn> Date: Fri, 5 Jul 2024 15:51:29 +0800 Subject: [PATCH] Add basic LoongArch64 support LoongArch is a new RISC ISA, which is a bit like MIPS or RISC-V. LoongArch includes a reduced 32-bit version (LA32R), a standard 32-bit version (LA32S) and a 64-bit version (LA64). LoongArch use ACPI as its boot protocol LoongArch-specific interrupt controllers (similar to APIC) are already added in the next revision of ACPI Specification (current revision is 6.4). This patchset is adding basic LoongArch support in mainline systemtap. --- bpf-translate.cxx | 33 + buildrun.cxx | 9 +- dwflpp.cxx | 1 + dwflpp.h | 4 + runtime/dyninst/regs.c | 20 + runtime/dyninst/stapdyn.h | 26 + runtime/linux/compat_structs.h | 4 +- runtime/linux/compat_unistd.h | 4 +- runtime/linux/regs.c | 20 + runtime/linux/runtime.h | 2 +- runtime/loc2c-runtime.h | 49 + runtime/regs.h | 8 + runtime/syscall.h | 42 + runtime/unwind/loongarch.h | 83 + runtime/unwind/unwind.h | 2 + scripts/dump-syscalls.sh | 6 + stapbpf/libbpf.c | 2 +- stapdyn/mutatee.cxx | 9 + tapset/errno.stp | 2 + tapset/linux/aux_syscalls.stp | 5 +- tapset/linux/loongarch64/aux_syscalls.stp | 12 + tapset/linux/loongarch64/registers.stp | 293 +++++ tapset/linux/loongarch64/syscall_num.stp | 1283 +++++++++++++++++++++ tapset/linux/syscalls.stpm | 2 +- tapsets.cxx | 40 +- testsuite/lib/compile_flags.exp | 9 +- testsuite/lib/systemtap.exp | 3 +- testsuite/systemtap.syscall/clone.c | 2 +- translate.cxx | 3 +- util.cxx | 2 + 30 files changed, 1964 insertions(+), 16 deletions(-) create mode 100644 runtime/unwind/loongarch.h create mode 100644 tapset/linux/loongarch64/aux_syscalls.stp create mode 100644 tapset/linux/loongarch64/registers.stp create mode 100644 tapset/linux/loongarch64/syscall_num.stp diff --git a/bpf-translate.cxx b/bpf-translate.cxx index 1a93024..8867d8e 100644 --- a/bpf-translate.cxx +++ b/bpf-translate.cxx @@ -3328,6 +3328,39 @@ bpf_unparser::visit_target_register (target_register* e) case 29: ofs = offsetof(user_pt_regs, regs[29]); break; case 30: ofs = offsetof(user_pt_regs, regs[30]); break; case 31: ofs = offsetof(user_pt_regs, sp); break; +#elif defined(__loongarch64) + case 0: ofs = offsetof(user_pt_regs, regs[0]); break; + case 1: ofs = offsetof(user_pt_regs, regs[1]); break; + case 2: ofs = offsetof(user_pt_regs, regs[2]); break; + case 3: ofs = offsetof(user_pt_regs, regs[3]); break; + case 4: ofs = offsetof(user_pt_regs, regs[4]); break; + case 5: ofs = offsetof(user_pt_regs, regs[5]); break; + case 6: ofs = offsetof(user_pt_regs, regs[6]); break; + case 7: ofs = offsetof(user_pt_regs, regs[7]); break; + case 8: ofs = offsetof(user_pt_regs, regs[8]); break; + case 9: ofs = offsetof(user_pt_regs, regs[9]); break; + case 10: ofs = offsetof(user_pt_regs, regs[10]); break; + case 11: ofs = offsetof(user_pt_regs, regs[11]); break; + case 12: ofs = offsetof(user_pt_regs, regs[12]); break; + case 13: ofs = offsetof(user_pt_regs, regs[13]); break; + case 14: ofs = offsetof(user_pt_regs, regs[14]); break; + case 15: ofs = offsetof(user_pt_regs, regs[15]); break; + case 16: ofs = offsetof(user_pt_regs, regs[16]); break; + case 17: ofs = offsetof(user_pt_regs, regs[17]); break; + case 18: ofs = offsetof(user_pt_regs, regs[18]); break; + case 19: ofs = offsetof(user_pt_regs, regs[19]); break; + case 20: ofs = offsetof(user_pt_regs, regs[20]); break; + case 21: ofs = offsetof(user_pt_regs, regs[21]); break; + case 22: ofs = offsetof(user_pt_regs, regs[22]); break; + case 23: ofs = offsetof(user_pt_regs, regs[23]); break; + case 24: ofs = offsetof(user_pt_regs, regs[24]); break; + case 25: ofs = offsetof(user_pt_regs, regs[25]); break; + case 26: ofs = offsetof(user_pt_regs, regs[26]); break; + case 27: ofs = offsetof(user_pt_regs, regs[27]); break; + case 28: ofs = offsetof(user_pt_regs, regs[28]); break; + case 29: ofs = offsetof(user_pt_regs, regs[29]); break; + case 30: ofs = offsetof(user_pt_regs, regs[30]); break; + case 31: ofs = offsetof(user_pt_regs, regs[31]); break; #elif defined(__powerpc__) case 0: ofs = offsetof(pt_regs, gpr[0]); break; case 1: ofs = offsetof(pt_regs, gpr[1]); break; diff --git a/buildrun.cxx b/buildrun.cxx index 8168420..3eaf7a6 100644 --- a/buildrun.cxx +++ b/buildrun.cxx @@ -144,8 +144,13 @@ make_any_make_cmd(systemtap_session& s, const string& dir, const string& target) // Add architecture, except for old powerpc (RHBZ669082) if (s.architecture != "powerpc" || - (strverscmp (s.kernel_base_release.c_str(), "2.6.15") >= 0)) - make_cmd.push_back("ARCH=" + s.architecture); // need make-quoting? + (strverscmp (s.kernel_base_release.c_str(), "2.6.15") >= 0)) { + if (s.architecture == "loongarch64") { + make_cmd.push_back("ARCH=loongarch"); + } else { + make_cmd.push_back("ARCH=" + s.architecture); // need make-quoting? + } + } // PR29837: Suppress the kernel version warning make_cmd.push_back("CC_VERSION_TEXT=foo"); diff --git a/dwflpp.cxx b/dwflpp.cxx index 9fccca0..d1b2b70 100644 --- a/dwflpp.cxx +++ b/dwflpp.cxx @@ -1355,6 +1355,7 @@ dwflpp::iterate_over_libraries<void>(void (*callback)(void*, const char*), && interpreter != "/lib/ld-linux-armhf.so.3" // arm && interpreter != "/lib/ld-linux-aarch64.so.1" // arm64 && interpreter != "/lib64/ld64.so.2" // ppc64le + && interpreter != "/lib64/ld-linux-loongarch-lp64d.so.1" // loongarch64 ) { sess.print_warning (_F("module %s --ldd skipped: unsupported interpreter: %s", diff --git a/dwflpp.h b/dwflpp.h index d90ce94..a604992 100644 --- a/dwflpp.h +++ b/dwflpp.h @@ -36,6 +36,10 @@ #define EM_RISCV 243 #endif +// Old elf.h doesn't know about this machine type. +#ifndef EM_LOONGARCH +#define EM_LOONGARCH 258 +#endif #define write_uleb128(ptr,val) ({ \ uint32_t valv = (val); \ diff --git a/runtime/dyninst/regs.c b/runtime/dyninst/regs.c index 8389ebd..664e45d 100644 --- a/runtime/dyninst/regs.c +++ b/runtime/dyninst/regs.c @@ -87,6 +87,26 @@ static void _stp_print_regs(struct pt_regs * regs) _stp_printf("\n"); } +#elif defined (__loongarch64) +static void _stp_print_regs(struct pt_regs * regs) +{ + int i, top_reg; + u64 lr, sp; + + lr = regs->regs[1]; + sp = regs->regs[3]; + top_reg = 31; + + _stp_printf("pc : [<%016llx>] lr : [<%016llx>] estat: %08llx\n", + regs->csr_era, lr, regs->csr_estat); + for (i = top_reg; i >= 0; i--) { + _stp_printf("x%-2d: %016llx ", i, regs->regs[i]); + if (i % 2 == 0) + _stp_printf("\n"); + } + _stp_printf("\n"); +} + #endif #endif /* _DYNINST_REGS_C_ */ diff --git a/runtime/dyninst/stapdyn.h b/runtime/dyninst/stapdyn.h index 4045dfc..2467f9a 100644 --- a/runtime/dyninst/stapdyn.h +++ b/runtime/dyninst/stapdyn.h @@ -52,6 +52,32 @@ struct pt_regs { }; #endif +#if defined(__loongarch64) + +/* + * This struct defines the way the registers are stored on the stack during a + * system call/exception. + * + * If you add a register here, also add it to regoffset_table[] in + * arch/loongarch/kernel/ptrace.c. + */ +struct pt_regs { + /* Saved main processor registers. */ + unsigned long regs[32]; + + /* Saved special registers. */ + unsigned long csr_era; + unsigned long csr_badv; + unsigned long csr_crmd; + unsigned long csr_prmd; + unsigned long csr_euen; + unsigned long csr_ecfg; + unsigned long csr_estat; + unsigned long orig_a0; + unsigned long __last[]; +} __attribute__ ((aligned (8))); +#endif + /* These are declarations of all interfaces that stapdyn may call in the * module, either directly or via dyninst in the mutatee. To maintain * compatibility as much as possible, function signatures should not be diff --git a/runtime/linux/compat_structs.h b/runtime/linux/compat_structs.h index fa9b855..1ca6de7 100644 --- a/runtime/linux/compat_structs.h +++ b/runtime/linux/compat_structs.h @@ -133,7 +133,7 @@ typedef struct compat_siginfo { #include <asm/ia32.h> #endif /* __x86_64__ */ -#if defined(__aarch64__) +#if defined(__aarch64__) || defined(__loongarch64) typedef struct compat_siginfo { int si_signo; int si_errno; @@ -193,6 +193,6 @@ typedef struct compat_siginfo { } _sigsys; } _sifields; } compat_siginfo_t; -#endif /* __aarch64__ */ +#endif /* __aarch64__, __loongarch64 */ #endif /* _COMPAT_STRUCTS_H_ */ diff --git a/runtime/linux/compat_unistd.h b/runtime/linux/compat_unistd.h index a66be04..84052e0 100644 --- a/runtime/linux/compat_unistd.h +++ b/runtime/linux/compat_unistd.h @@ -1860,7 +1860,7 @@ #endif /* __x86_64__ */ -#if defined(__powerpc64__) || defined (__s390x__) || defined(__aarch64__) +#if defined(__powerpc64__) || defined (__s390x__) || defined(__aarch64__) || defined(__loongarch64) // On the ppc64 and s390x, the 32-bit syscalls use the same number // as the 64-bit syscalls. @@ -2217,7 +2217,7 @@ #endif #define __NR_compat_writev __NR_writev -#endif /* __powerpc64__ || __s390x__ || __aarch64__ */ +#endif /* __powerpc64__ || __s390x__ || __aarch64__ || __loongarch64 */ #if defined(__ia64__) diff --git a/runtime/linux/regs.c b/runtime/linux/regs.c index f2aaa74..dc0edef 100644 --- a/runtime/linux/regs.c +++ b/runtime/linux/regs.c @@ -225,6 +225,26 @@ static void _stp_print_regs(struct pt_regs * regs) _stp_printf("\n"); } +#elif defined (__loongarch64) +static void _stp_print_regs(struct pt_regs * regs) +{ + int i, top_reg; + u64 lr, sp; + + lr = regs->regs[1]; + sp = regs->regs[3]; + top_reg = 31; + + _stp_printf("pc : [<%016llx>] lr : [<%016llx>] estat: %08llx\n", + regs->csr_era, lr, regs->csr_estat); + for (i = top_reg; i >= 0; i--) { + _stp_printf("x%-2d: %016llx ", i, regs->regs[i]); + if (i % 2 == 0) + _stp_printf("\n"); + } + _stp_printf("\n"); +} + #elif defined (__arm__) static const char *processor_modes[]= diff --git a/runtime/linux/runtime.h b/runtime/linux/runtime.h index a584079..c931e5e 100644 --- a/runtime/linux/runtime.h +++ b/runtime/linux/runtime.h @@ -201,7 +201,7 @@ static struct Only define STP_USE_DWARF_UNWINDER when STP_NEED_UNWIND_DATA, as set through a pragma:unwind in one of the [u]context-unwind.stp functions. */ -#if (defined(__arm__) || defined(__i386__) || defined(__x86_64__) || defined(__powerpc64__)) || defined (__s390x__) || defined(__aarch64__) || defined(__mips__) || defined(__riscv) +#if (defined(__arm__) || defined(__i386__) || defined(__x86_64__) || defined(__powerpc64__)) || defined (__s390x__) || defined(__aarch64__) || defined(__mips__) || defined(__riscv) || defined(__loongarch64) #ifdef STP_NEED_UNWIND_DATA #ifndef STP_USE_DWARF_UNWINDER #define STP_USE_DWARF_UNWINDER diff --git a/runtime/loc2c-runtime.h b/runtime/loc2c-runtime.h index 073ba04..d2732af 100644 --- a/runtime/loc2c-runtime.h +++ b/runtime/loc2c-runtime.h @@ -202,6 +202,16 @@ (pt_regs->regs[regno] = (value)) #define pt_regs_maxno 31 /* ignore special registers */ +#elif defined __loongarch64 + +#undef pt_regs_fetch_register +#undef pt_regs_store_register +#define pt_regs_fetch_register(pt_regs,regno) \ + ((intptr_t) pt_regs->regs[regno]) +#define pt_regs_store_register(pt_regs,regno,value) \ + (pt_regs->regs[regno] = (value)) +#define pt_regs_maxno 31 /* register max number,ignore special registers */ + #elif defined __riscv #define pt_dwarf_register_0(regs) regs->epc @@ -310,6 +320,45 @@ #define pt_dwarf_register_95(regs) ({uint64_t v; __asm__ __volatile__("mov %0, v31.d[0]" : "=r"(v)); v;}) #define pt_regs_maxno 95 +#elif defined (__loongarch64) + +#define pt_dwarf_register_0(pt_regs) pt_regs->regs[0] +#define pt_dwarf_register_1(pt_regs) pt_regs->regs[1] +#define pt_dwarf_register_2(pt_regs) pt_regs->regs[2] +#define pt_dwarf_register_3(pt_regs) pt_regs->regs[3] +#define pt_dwarf_register_4(pt_regs) pt_regs->regs[4] +#define pt_dwarf_register_5(pt_regs) pt_regs->regs[5] +#define pt_dwarf_register_6(pt_regs) pt_regs->regs[6] +#define pt_dwarf_register_7(pt_regs) pt_regs->regs[7] +#define pt_dwarf_register_8(pt_regs) pt_regs->regs[8] +#define pt_dwarf_register_9(pt_regs) pt_regs->regs[9] + +#define pt_dwarf_register_10(pt_regs) pt_regs->regs[10] +#define pt_dwarf_register_11(pt_regs) pt_regs->regs[11] +#define pt_dwarf_register_12(pt_regs) pt_regs->regs[12] +#define pt_dwarf_register_13(pt_regs) pt_regs->regs[13] +#define pt_dwarf_register_14(pt_regs) pt_regs->regs[14] +#define pt_dwarf_register_15(pt_regs) pt_regs->regs[15] +#define pt_dwarf_register_16(pt_regs) pt_regs->regs[16] +#define pt_dwarf_register_17(pt_regs) pt_regs->regs[17] +#define pt_dwarf_register_18(pt_regs) pt_regs->regs[18] +#define pt_dwarf_register_19(pt_regs) pt_regs->regs[19] + +#define pt_dwarf_register_20(pt_regs) pt_regs->regs[20] +#define pt_dwarf_register_21(pt_regs) pt_regs->regs[21] +#define pt_dwarf_register_22(pt_regs) pt_regs->regs[22] +#define pt_dwarf_register_23(pt_regs) pt_regs->regs[23] +#define pt_dwarf_register_24(pt_regs) pt_regs->regs[24] +#define pt_dwarf_register_25(pt_regs) pt_regs->regs[25] +#define pt_dwarf_register_26(pt_regs) pt_regs->regs[26] +#define pt_dwarf_register_27(pt_regs) pt_regs->regs[27] +#define pt_dwarf_register_28(pt_regs) pt_regs->regs[28] +#define pt_dwarf_register_29(pt_regs) pt_regs->regs[29] + +#define pt_dwarf_register_30(pt_regs) pt_regs->regs[30] +#define pt_dwarf_register_31(pt_regs) pt_regs->regs[31] +#define pt_regs_maxno 31 + #elif defined (__arm__) #undef pt_regs_fetch_register diff --git a/runtime/regs.h b/runtime/regs.h index b0237fc..05c9dce 100644 --- a/runtime/regs.h +++ b/runtime/regs.h @@ -64,6 +64,14 @@ #define REG_SP(regs_arg) (regs_arg)->sp #define REG_LINK(regs_arg) (regs_arg)->ra +#elif defined (__loongarch64) +#define REG_IP(regs_arg) ((regs_arg)->csr_era) +#ifdef REG_SP +#undef REG_SP +#define REG_SP(regs_arg) ((regs_arg)->regs[3]) +#endif +#define REG_LINK(regs_arg) ((regs_arg)->regs[1]) + #elif defined (__s390__) || defined (__s390x__) #ifndef __s390x__ diff --git a/runtime/syscall.h b/runtime/syscall.h index 44d8a28..92a10e4 100644 --- a/runtime/syscall.h +++ b/runtime/syscall.h @@ -158,6 +158,14 @@ #define MREMAP_SYSCALL_NO(tsk) 216 #endif +#if defined(__loongarch64) +#define MMAP_SYSCALL_NO(tsk) 222 +#define MMAP2_SYSCALL_NO(tsk) 222 +#define MPROTECT_SYSCALL_NO(tsk) 226 +#define MUNMAP_SYSCALL_NO(tsk) 215 +#define MREMAP_SYSCALL_NO(tsk) 216 +#endif + #if !defined(MMAP_SYSCALL_NO) || !defined(MMAP2_SYSCALL_NO) \ || !defined(MPROTECT_SYSCALL_NO) || !defined(MUNMAP_SYSCALL_NO) \ || !defined(MREMAP_SYSCALL_NO) @@ -261,6 +269,14 @@ _stp_syscall_get_nr(struct task_struct *task, struct pt_regs *regs) } #endif +#if defined(__loongarch64) +static inline long +_stp_syscall_get_nr(struct task_struct *task, struct pt_regs *regs) +{ + return regs->regs[11]; +} +#endif + #if defined(__aarch64__) static inline long _stp_syscall_get_nr(struct task_struct *task, struct pt_regs *regs) @@ -327,6 +343,14 @@ syscall_get_return_value(struct task_struct *task, struct pt_regs *regs) } #endif +#if defined(__loongarch64) +static inline long +syscall_get_return_value(struct task_struct *task, struct pt_regs *regs) +{ + return regs->regs[4]; +} +#endif + #if defined(__arm__) static inline long syscall_get_return_value(struct task_struct *task, struct pt_regs *regs) @@ -676,5 +700,23 @@ _stp_syscall_get_arguments(struct task_struct *task, struct pt_regs *regs, } #endif +#if defined(__loongarch64) +static inline void +_stp_syscall_get_arguments(struct task_struct *task, struct pt_regs *regs, + unsigned int i, unsigned int n, unsigned long *args) +{ + if (!n) + return; + if (i == 0) { + args[0] = regs->orig_a0; + args++; + n--; + } else { + i--; + } + memcpy(args, ®s->regs[5] + i, n * sizeof(args[0])); +} +#endif + #endif /* !STAPCONF_ASM_SYSCALL_H */ #endif /* _SYSCALL_H_ */ diff --git a/runtime/unwind/loongarch.h b/runtime/unwind/loongarch.h new file mode 100644 index 0000000..a5e5390 --- /dev/null +++ b/runtime/unwind/loongarch.h @@ -0,0 +1,83 @@ +/* -*- linux-c -*- + * + * LOONGARCH dwarf unwinder header file + * + * This file is part of systemtap, and is free software. You can + * redistribute it and/or modify it under the terms of the GNU General + * Public License (GPL); either version 2, or (at your option) any + * later version. + */ +#ifndef _STP_LOONGARCH_UNWIND_H +#define _STP_LOONGARCH_UNWIND_H + +#include <linux/sched.h> +#include <asm/ptrace.h> + +#define _stp_get_unaligned(ptr) (*(ptr)) + +#define UNW_PC(frame) (frame)->regs.csr_era +#define UNW_SP(frame) (frame)->regs.regs[3] + +#define STACK_LIMIT(ptr) (((ptr) - 1) & ~(THREAD_SIZE - 1)) + +// runtime/unwind/unwind.h: +// struct pt_regs regs; +// #define PTREGS_INFO(f) EXTRA_INFO(regs.f) +// +#define UNW_REGISTER_INFO \ + PTREGS_INFO(regs[0]), \ + PTREGS_INFO(regs[1]), \ + PTREGS_INFO(regs[2]), \ + PTREGS_INFO(regs[3]), \ + PTREGS_INFO(regs[4]), \ + PTREGS_INFO(regs[5]), \ + PTREGS_INFO(regs[6]), \ + PTREGS_INFO(regs[7]), \ + PTREGS_INFO(regs[8]), \ + PTREGS_INFO(regs[9]), \ + PTREGS_INFO(regs[10]), \ + PTREGS_INFO(regs[11]), \ + PTREGS_INFO(regs[12]), \ + PTREGS_INFO(regs[13]), \ + PTREGS_INFO(regs[14]), \ + PTREGS_INFO(regs[16]), \ + PTREGS_INFO(regs[17]), \ + PTREGS_INFO(regs[18]), \ + PTREGS_INFO(regs[19]), \ + PTREGS_INFO(regs[20]), \ + PTREGS_INFO(regs[21]), \ + PTREGS_INFO(regs[22]), \ + PTREGS_INFO(regs[23]), \ + PTREGS_INFO(regs[24]), \ + PTREGS_INFO(regs[26]), \ + PTREGS_INFO(regs[27]), \ + PTREGS_INFO(regs[28]), \ + PTREGS_INFO(regs[29]), \ + PTREGS_INFO(regs[30]), \ + PTREGS_INFO(regs[31]), \ + PTREGS_INFO(csr_era) + +//libunwind: include/libunwind-loongarch64.h UNW_LOONGARCH64_PC = 33 +#define UNW_PC_IDX 33 +// sp(r3) register +#define UNW_SP_IDX 3 + +/* Use default rules. The stack pointer should be set from the CFA. + And the instruction pointer should be set from the return address + column (which normally is the return register (regs[31]). */ + +static inline void arch_unw_init_frame_info(struct unwind_frame_info *info, + /*const*/ struct pt_regs *regs, + int sanitize) +{ + if (&info->regs == regs) { /* happens when unwinding kernel->user */ + info->call_frame = 1; + return; + } + + memset(info, 0, sizeof(*info)); + /* XXX handle sanitize??? */ + info->regs = *regs; +} + +#endif /* _STP_LOONGARCH_UNWIND_H */ \ No newline at end of file diff --git a/runtime/unwind/unwind.h b/runtime/unwind/unwind.h index 1c77b50..cebae34 100644 --- a/runtime/unwind/unwind.h +++ b/runtime/unwind/unwind.h @@ -38,6 +38,8 @@ struct unwind_frame_info #include "mips.h" #elif defined (__riscv) #include "riscv.h" +#elif defined (__loongarch64) +#include "loongarch64.h" #else #error "Unsupported dwarf unwind architecture" #endif diff --git a/scripts/dump-syscalls.sh b/scripts/dump-syscalls.sh index 57e5e42..420f620 100755 --- a/scripts/dump-syscalls.sh +++ b/scripts/dump-syscalls.sh @@ -24,6 +24,7 @@ TAPSET_ARM=$TAPSET_SRC/linux/arm/syscall_num.stp TAPSET_AARCH64=$TAPSET_SRC/linux/arm64/syscall_num.stp TAPSET_MIPS=$TAPSET_SRC/linux/mips/syscall_num.stp TAPSET_RISCV=$TAPSET_SRC/linux/riscv/syscall_num.stp +TAPSET_LOONGARCH=$TAPSET_SRC/linux/loongarch64/syscall_num.stp SYSCALLS_32=$(mktemp) SYSCALLS_64=$(mktemp) @@ -132,5 +133,10 @@ __dump_syscalls $STRACE_SRC/linux/riscv64/syscallent.h 64 # than nothing. __dump_syscalls $STRACE_SRC/linux/riscv64/syscallent.h 32 __generate_tapset $TAPSET_RISCV riscv +# ======= loongarch64 ======= +__init +__dump_syscalls $STRACE_SRC/linux/64/syscallent.h 64 +__dump_syscalls $STRACE_SRC/linux/loongarch64/syscallent.h 64 +__generate_tapset $TAPSET_LOONGARCH loongarch64 rm -f $SYSCALLS_32 $SYSCALLS_64 diff --git a/stapbpf/libbpf.c b/stapbpf/libbpf.c index 09f20eb..95505c5 100644 --- a/stapbpf/libbpf.c +++ b/stapbpf/libbpf.c @@ -20,7 +20,7 @@ # define __NR_bpf 357 # elif defined(__x86_64__) # define __NR_bpf 321 -# elif defined(__aarch64__) +# elif defined(__aarch64__) || defined(__loongarch64) # define __NR_bpf 280 # else # error __NR_bpf not defined. diff --git a/stapdyn/mutatee.cxx b/stapdyn/mutatee.cxx index c357b17..5438ee4 100644 --- a/stapdyn/mutatee.cxx +++ b/stapdyn/mutatee.cxx @@ -62,6 +62,15 @@ get_dwarf_registers(BPatch_process *app, "r20", "r21", "r22", "r23", "r24", "r25", "r26", "r27", "r28", "r29", "r30", "r31", +#elif defined(__loongarch64) + "r0", "r1", "r2", "r3", + "r4", "r5", "r6", "r7", + "r8", "r9", "r10", "r11", + "r12", "r13", "r14", "r15", + "r16", "r17", "r18", "r19", + "r20", "r21", "r22", "r23", + "r24", "r25", "r26", "r27", + "r28", "r29", "r30", "r31", #endif NULL }; diff --git a/tapset/errno.stp b/tapset/errno.stp index a75e3ba..d7c93f5 100644 --- a/tapset/errno.stp +++ b/tapset/errno.stp @@ -392,6 +392,8 @@ static long _stp_returnval(struct pt_regs *regs) { return regs->ARM_r0; #elif defined (__mips__) return regs->regs[2]; +#elif defined (__loongarch64) + return regs->regs[4]; #else _stp_error("returnval() not defined for this architecture"); return 0; diff --git a/tapset/linux/aux_syscalls.stp b/tapset/linux/aux_syscalls.stp index af6b0ae..6193f76 100644 --- a/tapset/linux/aux_syscalls.stp +++ b/tapset/linux/aux_syscalls.stp @@ -3568,7 +3568,7 @@ static void _stp_sigaction_str(struct sigaction *act, char *ptr, int len) strlcat (ptr, ", ", len); _stp_lookup_or_str(_stp_sa_flags_list, act->sa_flags, ptr, len); strlcat (ptr, ", ", len); -#if !defined (__ia64__) && !defined (__mips__) && !defined(__riscv) +#if !defined (__ia64__) && !defined (__mips__) && !defined(__riscv) && !defined (__loongarch64) slen = strlen(ptr); _stp_snprintf(ptr + slen, len - slen, "0x%lx, ", (long)act->sa_restorer); @@ -4129,6 +4129,9 @@ function _swapon_flags_str:string(flags:long) #elif defined(__aarch64__) long pstate = kread(®s->pstate); STAP_RETVALUE = ((pstate & PSR_MODE_MASK) == PSR_MODE_EL0t); +#elif defined(__loongarch64) + long csr_prmd = kread(®s->csr_prmd); + STAP_RETVALUE = ((csr_prmd & PLV_MASK) == PLV_USER); #else #error "Unimplemented architecture" #endif diff --git a/tapset/linux/loongarch64/aux_syscalls.stp b/tapset/linux/loongarch64/aux_syscalls.stp new file mode 100644 index 0000000..d7f2edd --- /dev/null +++ b/tapset/linux/loongarch64/aux_syscalls.stp @@ -0,0 +1,12 @@ +# arch-specific requests of ptrace ___________________________ +# + +function _arch_ptrace_argstr(request, pid, addr, data) +{ + return("") +} + +function _ptrace_return_arch_prctl_addr:long(request:long, addr:long, data:long) +{ + return 0 +} \ No newline at end of file diff --git a/tapset/linux/loongarch64/registers.stp b/tapset/linux/loongarch64/registers.stp new file mode 100644 index 0000000..b2523f4 --- /dev/null +++ b/tapset/linux/loongarch64/registers.stp @@ -0,0 +1,293 @@ +/* Dwarfless register access for LOONGARCH */ + +global _reg_offsets, _stp_regs_registered + +function _stp_register_regs() { + offset_acx = 0 + /* Same order as struct pt_regs */ + _reg_offsets["$zero"] = 0 + _reg_offsets["$ra"] = 8 + _reg_offsets["$tp"] = 16 + _reg_offsets["$sp"] = 24 + _reg_offsets["$a0"] = 32 + _reg_offsets["$a1"] = 40 + _reg_offsets["$a2"] = 48 + _reg_offsets["$a3"] = 56 + _reg_offsets["$a4"] = 64 + _reg_offsets["$a5"] = 72 + _reg_offsets["$a6"] = 80 + _reg_offsets["$a7"] = 88 + _reg_offsets["$t0"] = 96 + _reg_offsets["$t1"] = 104 + _reg_offsets["$t2"] = 112 + _reg_offsets["$t3"] = 120 + _reg_offsets["$t4"] = 128 + _reg_offsets["$t5"] = 136 + _reg_offsets["$t6"] = 144 + _reg_offsets["$t7"] = 152 + _reg_offsets["$t8"] = 160 + _reg_offsets["$x"] = 168 + _reg_offsets["$fp"] = 176 + _reg_offsets["$s0"] = 184 + _reg_offsets["$s1"] = 192 + _reg_offsets["$s2"] = 200 + _reg_offsets["$s3"] = 208 + _reg_offsets["$s4"] = 216 + _reg_offsets["$s5"] = 224 + _reg_offsets["$s6"] = 232 + _reg_offsets["$s7"] = 240 + _reg_offsets["$s8"] = 248 + +/* ignore special registers */ + + _stp_regs_registered = 1 +} + +function _stp_get_register_by_offset:long (offset:long) %{ /* pure */ + long value; + struct pt_regs *regs; + regs = (CONTEXT->user_mode_p ? CONTEXT->uregs : CONTEXT->kregs); + + if (!regs) { + CONTEXT->last_error = "No registers available in this context"; + return; + } + if (STAP_ARG_offset < 0 || STAP_ARG_offset > sizeof(struct pt_regs) - sizeof(long)) { + snprintf(CONTEXT->error_buffer, sizeof(CONTEXT->error_buffer), + "Bad register offset: %lld", STAP_ARG_offset); + CONTEXT->last_error = CONTEXT->error_buffer; + return; + } + memcpy(&value, ((char *)regs) + STAP_ARG_offset, sizeof(value)); + STAP_RETVALUE = value; +%} + +function _stp_sign_extend32:long (value:long) { + if (value & 0x80000000) + value |= (0xffffffff << 32) + return value +} + +function _stp_register:long (name:string, sign_extend:long) { + if (!registers_valid()) { + error("cannot access CPU registers in this context") + return 0 + } + if (!_stp_regs_registered) + _stp_register_regs() + offset = _reg_offsets[name] + if (offset == 0 && !(name in _reg_offsets)) { + error("Unknown register: " . name) + return 0 + } + value = _stp_get_register_by_offset(offset) + return value +} + +/* Return the named register value as a signed value. */ +function register:long (name:string) { + return _stp_register(name, 1) +} + +/* + * Return the named register value as an unsigned value. Specifically, + * don't sign-extend the register value when promoting it to 64 bits. + */ +function u_register:long (name:string) { + return _stp_register(name, 0) +} + + +/* Dwarfless register access for loongarch */ + +%{ +// These functions are largely lifted from arch/loongarch/include/asm/ptrace.h. + +static inline unsigned long _stp_kernel_stack_pointer(struct pt_regs *regs) +{ + return regs->regs[3]; +} + +/** + * _stp_regs_within_kernel_stack() - check the address in the stack + * @regs: pt_regs which contains kernel stack pointer. + * @addr: address which is checked. + * + * _stp_regs_within_kernel_stack() checks @addr is within the kernel stack page(s). + * If @addr is within the kernel stack, it returns true. If not, returns false. + */ +static inline int _stp_regs_within_kernel_stack(struct pt_regs *regs, unsigned long addr) +{ + return ((addr & ~(THREAD_SIZE - 1)) == + (_stp_kernel_stack_pointer(regs) & ~(THREAD_SIZE - 1))); +} + +/* + * _stp_regs_get_kernel_stack_nth_addr() - get address of the Nth entry of the stack + * @regs: pt_regs which contains kernel stack pointer. + * @n: stack entry number. + * + * _stp_regs_get_kernel_stack_nth_addr() returns the address of the @n + * th entry of the kernel stack which is specified by @regs. If the @n + * th entry is NOT in the kernel stack, this returns 0. + */ +long * +_stp_regs_get_kernel_stack_nth_addr(struct pt_regs *regs, unsigned int n) +{ + long *addr = (unsigned long *)_stp_kernel_stack_pointer(regs); + addr += n; + if (_stp_regs_within_kernel_stack(regs, (unsigned long)addr)) + return addr; + else + return 0; +} + +%} + +function _stp_get_stack_nth:long (n:long) +%{ /* pure */ + __label__ deref_fault; + unsigned int n = (unsigned int)STAP_ARG_n; + struct pt_regs *regs; + long *addr; + + STAP_RETVALUE = 0; + if (CONTEXT->user_mode_p) { + // This function only handles kernel arguments off the stack. + snprintf(CONTEXT->error_buffer, sizeof(CONTEXT->error_buffer), + "cannot access function args in this context"); + CONTEXT->last_error = CONTEXT->error_buffer; + return; + } + regs = CONTEXT->kregs; + if (!regs) { + snprintf(CONTEXT->error_buffer, sizeof(CONTEXT->error_buffer), + "cannot access function args in this context"); + CONTEXT->last_error = CONTEXT->error_buffer; + return; + } + + /* Get the address of the nth item on the stack. */ + addr = _stp_regs_get_kernel_stack_nth_addr(regs, n); + if (addr == NULL) { + snprintf(CONTEXT->error_buffer, sizeof(CONTEXT->error_buffer), + "cannot access stack arg(%d)", n); + CONTEXT->last_error = CONTEXT->error_buffer; + return; + } + STAP_RETVALUE = kread(addr); + return; + +deref_fault: /* branched to from kread() */ + snprintf(CONTEXT->error_buffer, sizeof(CONTEXT->error_buffer), + "kernel fault at %#lx accessing stack arg(%d)", + (unsigned long)addr, n); + CONTEXT->last_error = CONTEXT->error_buffer; +%} + +/* + * Return the value of function arg #argnum (1=first arg). + * If truncate=1, mask off the top 32 bits. + * If sign_extend=1 and (truncate=1 or the probepoint we've hit is in a + * 32-bit app), sign-extend the 32-bit value. + */ +function _stp_arg:long (argnum:long, sign_extend:long, truncate:long) { + val = 0 + if (argnum < 1 || argnum > 8) { + error(sprintf("Cannot access arg(%d)", argnum)) + return 0 + } + + if (argnum == 1) + val = u_register("$a0") + else if (argnum == 2) + val = u_register("$a1") + else if (argnum == 3) + val = u_register("$a2") + else if (argnum == 4) + val = u_register("$a3") + else if (argnum == 5) + val = u_register("$a4") + else if (argnum == 6) + val = u_register("$a5") + else if (argnum == 7) + val = u_register("$a6") + else if (argnum == 8) + val = u_register("$a7") + else + val = _stp_get_stack_nth(argnum - 5) + + if (truncate) { + if (sign_extend) + val = _stp_sign_extend32(val) + else + /* High bits may be garbage. */ + val = (val & 0xffffffff); + } + return val; +} + +function arch_bytes:long() %{ /* pure */ + STAP_RETVALUE = sizeof(long); +%} + +function uarch_bytes:long() { + assert(user_mode(), "requires user mode") + return probing_32bit_app() ? 4 : 8 +} + +/* Return the value of function arg #argnum (1=first arg) as a signed int. */ +function int_arg:long (argnum:long) { + return _stp_arg(argnum, 1, 1) +} + +/* Return the value of function arg #argnum (1=first arg) as an unsigned int. */ +function uint_arg:long (argnum:long) { + return _stp_arg(argnum, 0, 1) +} + +function long_arg:long (argnum:long) { + return _stp_arg(argnum, 1, 0) +} + +function ulong_arg:long (argnum:long) { + return _stp_arg(argnum, 0, 0) +} + +function longlong_arg:long (argnum:long) { + return _stp_arg(argnum, 0, 0) +} + +function ulonglong_arg:long (argnum:long) { + return longlong_arg(argnum) +} + +function pointer_arg:long (argnum:long) { + return _stp_arg(argnum, 0, 0) +} + +function s32_arg:long (argnum:long) { + return int_arg(argnum) +} + +function u32_arg:long (argnum:long) { + return uint_arg(argnum) +} + +function s64_arg:long (argnum:long) { + return longlong_arg(argnum) +} + +function u64_arg:long (argnum:long) { + return ulonglong_arg(argnum) +} + +function asmlinkage() %{ /* pure */ %} + +function fastcall() %{ /* pure */ %} + +function regparm() %{ + snprintf(CONTEXT->error_buffer, sizeof(CONTEXT->error_buffer), + "regparm is invalid on mips."); + CONTEXT->last_error = CONTEXT->error_buffer; +%} \ No newline at end of file diff --git a/tapset/linux/loongarch64/syscall_num.stp b/tapset/linux/loongarch64/syscall_num.stp new file mode 100644 index 0000000..284f6ba --- /dev/null +++ b/tapset/linux/loongarch64/syscall_num.stp @@ -0,0 +1,1283 @@ +# This is arch specific syscall table generated by scripts/dump-syscalls.sh + +%( arch =="loongarch64" %? +global __syscall_64_num2name[636] +global __syscall_64_name2num[636] +%) + +probe init { +%( arch =="loongarch64" %? +__syscall_64_num2name[202]="accept" +__syscall_64_num2name[202]="accept" +__syscall_64_name2num["accept"]=202 +__syscall_64_name2num["accept"]=202 +__syscall_64_num2name[242]="accept4" +__syscall_64_num2name[242]="accept4" +__syscall_64_name2num["accept4"]=242 +__syscall_64_name2num["accept4"]=242 +__syscall_64_num2name[89]="acct" +__syscall_64_num2name[89]="acct" +__syscall_64_name2num["acct"]=89 +__syscall_64_name2num["acct"]=89 +__syscall_64_num2name[217]="add_key" +__syscall_64_num2name[217]="add_key" +__syscall_64_name2num["add_key"]=217 +__syscall_64_name2num["add_key"]=217 +__syscall_64_num2name[171]="adjtimex" +__syscall_64_num2name[171]="adjtimex" +__syscall_64_name2num["adjtimex"]=171 +__syscall_64_name2num["adjtimex"]=171 +__syscall_64_num2name[200]="bind" +__syscall_64_num2name[200]="bind" +__syscall_64_name2num["bind"]=200 +__syscall_64_name2num["bind"]=200 +__syscall_64_num2name[280]="bpf" +__syscall_64_num2name[280]="bpf" +__syscall_64_name2num["bpf"]=280 +__syscall_64_name2num["bpf"]=280 +__syscall_64_num2name[214]="brk" +__syscall_64_num2name[214]="brk" +__syscall_64_name2num["brk"]=214 +__syscall_64_name2num["brk"]=214 +__syscall_64_num2name[0+451]="cachestat" +__syscall_64_num2name[0+451]="cachestat" +__syscall_64_name2num["cachestat"]=0+451 +__syscall_64_name2num["cachestat"]=0+451 +__syscall_64_num2name[90]="capget" +__syscall_64_num2name[90]="capget" +__syscall_64_name2num["capget"]=90 +__syscall_64_name2num["capget"]=90 +__syscall_64_num2name[91]="capset" +__syscall_64_num2name[91]="capset" +__syscall_64_name2num["capset"]=91 +__syscall_64_name2num["capset"]=91 +__syscall_64_num2name[49]="chdir" +__syscall_64_num2name[49]="chdir" +__syscall_64_name2num["chdir"]=49 +__syscall_64_name2num["chdir"]=49 +__syscall_64_num2name[51]="chroot" +__syscall_64_num2name[51]="chroot" +__syscall_64_name2num["chroot"]=51 +__syscall_64_name2num["chroot"]=51 +__syscall_64_num2name[266]="clock_adjtime" +__syscall_64_num2name[266]="clock_adjtime" +__syscall_64_name2num["clock_adjtime"]=266 +__syscall_64_name2num["clock_adjtime"]=266 +__syscall_64_num2name[114]="clock_getres" +__syscall_64_num2name[114]="clock_getres" +__syscall_64_name2num["clock_getres"]=114 +__syscall_64_name2num["clock_getres"]=114 +__syscall_64_num2name[113]="clock_gettime" +__syscall_64_num2name[113]="clock_gettime" +__syscall_64_name2num["clock_gettime"]=113 +__syscall_64_name2num["clock_gettime"]=113 +__syscall_64_num2name[115]="clock_nanosleep" +__syscall_64_num2name[115]="clock_nanosleep" +__syscall_64_name2num["clock_nanosleep"]=115 +__syscall_64_name2num["clock_nanosleep"]=115 +__syscall_64_num2name[112]="clock_settime" +__syscall_64_num2name[112]="clock_settime" +__syscall_64_name2num["clock_settime"]=112 +__syscall_64_name2num["clock_settime"]=112 +__syscall_64_num2name[220]="clone" +__syscall_64_num2name[220]="clone" +__syscall_64_name2num["clone"]=220 +__syscall_64_name2num["clone"]=220 +__syscall_64_num2name[0+435]="clone3" +__syscall_64_num2name[0+435]="clone3" +__syscall_64_name2num["clone3"]=0+435 +__syscall_64_name2num["clone3"]=0+435 +__syscall_64_num2name[57]="close" +__syscall_64_num2name[57]="close" +__syscall_64_name2num["close"]=57 +__syscall_64_name2num["close"]=57 +__syscall_64_num2name[0+436]="close_range" +__syscall_64_num2name[0+436]="close_range" +__syscall_64_name2num["close_range"]=0+436 +__syscall_64_name2num["close_range"]=0+436 +__syscall_64_num2name[203]="connect" +__syscall_64_num2name[203]="connect" +__syscall_64_name2num["connect"]=203 +__syscall_64_name2num["connect"]=203 +__syscall_64_num2name[285]="copy_file_range" +__syscall_64_num2name[285]="copy_file_range" +__syscall_64_name2num["copy_file_range"]=285 +__syscall_64_name2num["copy_file_range"]=285 +__syscall_64_num2name[106]="delete_module" +__syscall_64_num2name[106]="delete_module" +__syscall_64_name2num["delete_module"]=106 +__syscall_64_name2num["delete_module"]=106 +__syscall_64_num2name[23]="dup" +__syscall_64_num2name[23]="dup" +__syscall_64_name2num["dup"]=23 +__syscall_64_name2num["dup"]=23 +__syscall_64_num2name[24]="dup3" +__syscall_64_num2name[24]="dup3" +__syscall_64_name2num["dup3"]=24 +__syscall_64_name2num["dup3"]=24 +__syscall_64_num2name[20]="epoll_create1" +__syscall_64_num2name[20]="epoll_create1" +__syscall_64_name2num["epoll_create1"]=20 +__syscall_64_name2num["epoll_create1"]=20 +__syscall_64_num2name[21]="epoll_ctl" +__syscall_64_num2name[21]="epoll_ctl" +__syscall_64_name2num["epoll_ctl"]=21 +__syscall_64_name2num["epoll_ctl"]=21 +__syscall_64_num2name[22]="epoll_pwait" +__syscall_64_num2name[22]="epoll_pwait" +__syscall_64_num2name[0+441]="epoll_pwait2" +__syscall_64_num2name[0+441]="epoll_pwait2" +__syscall_64_name2num["epoll_pwait2"]=0+441 +__syscall_64_name2num["epoll_pwait2"]=0+441 +__syscall_64_name2num["epoll_pwait"]=22 +__syscall_64_name2num["epoll_pwait"]=22 +__syscall_64_num2name[19]="eventfd2" +__syscall_64_num2name[19]="eventfd2" +__syscall_64_name2num["eventfd2"]=19 +__syscall_64_name2num["eventfd2"]=19 +__syscall_64_num2name[221]="execve" +__syscall_64_num2name[221]="execve" +__syscall_64_name2num["execve"]=221 +__syscall_64_name2num["execve"]=221 +__syscall_64_num2name[281]="execveat" +__syscall_64_num2name[281]="execveat" +__syscall_64_name2num["execveat"]=281 +__syscall_64_name2num["execveat"]=281 +__syscall_64_num2name[93]="exit" +__syscall_64_num2name[93]="exit" +__syscall_64_name2num["exit"]=93 +__syscall_64_name2num["exit"]=93 +__syscall_64_num2name[94]="exit_group" +__syscall_64_num2name[94]="exit_group" +__syscall_64_name2num["exit_group"]=94 +__syscall_64_name2num["exit_group"]=94 +__syscall_64_num2name[48]="faccessat" +__syscall_64_num2name[48]="faccessat" +__syscall_64_num2name[0+439]="faccessat2" +__syscall_64_num2name[0+439]="faccessat2" +__syscall_64_name2num["faccessat2"]=0+439 +__syscall_64_name2num["faccessat2"]=0+439 +__syscall_64_name2num["faccessat"]=48 +__syscall_64_name2num["faccessat"]=48 +__syscall_64_num2name[223]="fadvise64" +__syscall_64_num2name[223]="fadvise64" +__syscall_64_name2num["fadvise64"]=223 +__syscall_64_name2num["fadvise64"]=223 +__syscall_64_num2name[47]="fallocate" +__syscall_64_num2name[47]="fallocate" +__syscall_64_name2num["fallocate"]=47 +__syscall_64_name2num["fallocate"]=47 +__syscall_64_num2name[262]="fanotify_init" +__syscall_64_num2name[262]="fanotify_init" +__syscall_64_name2num["fanotify_init"]=262 +__syscall_64_name2num["fanotify_init"]=262 +__syscall_64_num2name[263]="fanotify_mark" +__syscall_64_num2name[263]="fanotify_mark" +__syscall_64_name2num["fanotify_mark"]=263 +__syscall_64_name2num["fanotify_mark"]=263 +__syscall_64_num2name[50]="fchdir" +__syscall_64_num2name[50]="fchdir" +__syscall_64_name2num["fchdir"]=50 +__syscall_64_name2num["fchdir"]=50 +__syscall_64_num2name[52]="fchmod" +__syscall_64_num2name[52]="fchmod" +__syscall_64_name2num["fchmod"]=52 +__syscall_64_name2num["fchmod"]=52 +__syscall_64_num2name[53]="fchmodat" +__syscall_64_num2name[53]="fchmodat" +__syscall_64_num2name[0+452]="fchmodat2" +__syscall_64_num2name[0+452]="fchmodat2" +__syscall_64_name2num["fchmodat2"]=0+452 +__syscall_64_name2num["fchmodat2"]=0+452 +__syscall_64_name2num["fchmodat"]=53 +__syscall_64_name2num["fchmodat"]=53 +__syscall_64_num2name[55]="fchown" +__syscall_64_num2name[55]="fchown" +__syscall_64_name2num["fchown"]=55 +__syscall_64_name2num["fchown"]=55 +__syscall_64_num2name[54]="fchownat" +__syscall_64_num2name[54]="fchownat" +__syscall_64_name2num["fchownat"]=54 +__syscall_64_name2num["fchownat"]=54 +__syscall_64_num2name[25]="fcntl" +__syscall_64_num2name[25]="fcntl" +__syscall_64_name2num["fcntl"]=25 +__syscall_64_name2num["fcntl"]=25 +__syscall_64_num2name[83]="fdatasync" +__syscall_64_num2name[83]="fdatasync" +__syscall_64_name2num["fdatasync"]=83 +__syscall_64_name2num["fdatasync"]=83 +__syscall_64_num2name[10]="fgetxattr" +__syscall_64_num2name[10]="fgetxattr" +__syscall_64_name2num["fgetxattr"]=10 +__syscall_64_name2num["fgetxattr"]=10 +__syscall_64_num2name[273]="finit_module" +__syscall_64_num2name[273]="finit_module" +__syscall_64_name2num["finit_module"]=273 +__syscall_64_name2num["finit_module"]=273 +__syscall_64_num2name[13]="flistxattr" +__syscall_64_num2name[13]="flistxattr" +__syscall_64_name2num["flistxattr"]=13 +__syscall_64_name2num["flistxattr"]=13 +__syscall_64_num2name[32]="flock" +__syscall_64_num2name[32]="flock" +__syscall_64_name2num["flock"]=32 +__syscall_64_name2num["flock"]=32 +__syscall_64_num2name[16]="fremovexattr" +__syscall_64_num2name[16]="fremovexattr" +__syscall_64_name2num["fremovexattr"]=16 +__syscall_64_name2num["fremovexattr"]=16 +__syscall_64_num2name[0+431]="fsconfig" +__syscall_64_num2name[0+431]="fsconfig" +__syscall_64_name2num["fsconfig"]=0+431 +__syscall_64_name2num["fsconfig"]=0+431 +__syscall_64_num2name[7]="fsetxattr" +__syscall_64_num2name[7]="fsetxattr" +__syscall_64_name2num["fsetxattr"]=7 +__syscall_64_name2num["fsetxattr"]=7 +__syscall_64_num2name[0+432]="fsmount" +__syscall_64_num2name[0+432]="fsmount" +__syscall_64_name2num["fsmount"]=0+432 +__syscall_64_name2num["fsmount"]=0+432 +__syscall_64_num2name[0+430]="fsopen" +__syscall_64_num2name[0+430]="fsopen" +__syscall_64_name2num["fsopen"]=0+430 +__syscall_64_name2num["fsopen"]=0+430 +__syscall_64_num2name[0+433]="fspick" +__syscall_64_num2name[0+433]="fspick" +__syscall_64_name2num["fspick"]=0+433 +__syscall_64_name2num["fspick"]=0+433 +__syscall_64_num2name[80]="fstat" +__syscall_64_num2name[80]="fstat" +__syscall_64_name2num["fstat"]=80 +__syscall_64_name2num["fstat"]=80 +__syscall_64_num2name[44]="fstatfs" +__syscall_64_num2name[44]="fstatfs" +__syscall_64_name2num["fstatfs"]=44 +__syscall_64_name2num["fstatfs"]=44 +__syscall_64_num2name[82]="fsync" +__syscall_64_num2name[82]="fsync" +__syscall_64_name2num["fsync"]=82 +__syscall_64_name2num["fsync"]=82 +__syscall_64_num2name[46]="ftruncate" +__syscall_64_num2name[46]="ftruncate" +__syscall_64_name2num["ftruncate"]=46 +__syscall_64_name2num["ftruncate"]=46 +__syscall_64_num2name[98]="futex" +__syscall_64_num2name[98]="futex" +__syscall_64_name2num["futex"]=98 +__syscall_64_name2num["futex"]=98 +__syscall_64_num2name[0+456]="futex_requeue" +__syscall_64_num2name[0+456]="futex_requeue" +__syscall_64_name2num["futex_requeue"]=0+456 +__syscall_64_name2num["futex_requeue"]=0+456 +__syscall_64_num2name[0+455]="futex_wait" +__syscall_64_num2name[0+455]="futex_wait" +__syscall_64_name2num["futex_wait"]=0+455 +__syscall_64_name2num["futex_wait"]=0+455 +__syscall_64_num2name[0+449]="futex_waitv" +__syscall_64_num2name[0+449]="futex_waitv" +__syscall_64_name2num["futex_waitv"]=0+449 +__syscall_64_name2num["futex_waitv"]=0+449 +__syscall_64_num2name[0+454]="futex_wake" +__syscall_64_num2name[0+454]="futex_wake" +__syscall_64_name2num["futex_wake"]=0+454 +__syscall_64_name2num["futex_wake"]=0+454 +__syscall_64_num2name[168]="getcpu" +__syscall_64_num2name[168]="getcpu" +__syscall_64_name2num["getcpu"]=168 +__syscall_64_name2num["getcpu"]=168 +__syscall_64_num2name[17]="getcwd" +__syscall_64_num2name[17]="getcwd" +__syscall_64_name2num["getcwd"]=17 +__syscall_64_name2num["getcwd"]=17 +__syscall_64_num2name[61]="getdents64" +__syscall_64_num2name[61]="getdents64" +__syscall_64_name2num["getdents64"]=61 +__syscall_64_name2num["getdents64"]=61 +__syscall_64_num2name[177]="getegid" +__syscall_64_num2name[177]="getegid" +__syscall_64_name2num["getegid"]=177 +__syscall_64_name2num["getegid"]=177 +__syscall_64_num2name[175]="geteuid" +__syscall_64_num2name[175]="geteuid" +__syscall_64_name2num["geteuid"]=175 +__syscall_64_name2num["geteuid"]=175 +__syscall_64_num2name[176]="getgid" +__syscall_64_num2name[176]="getgid" +__syscall_64_name2num["getgid"]=176 +__syscall_64_name2num["getgid"]=176 +__syscall_64_num2name[158]="getgroups" +__syscall_64_num2name[158]="getgroups" +__syscall_64_name2num["getgroups"]=158 +__syscall_64_name2num["getgroups"]=158 +__syscall_64_num2name[102]="getitimer" +__syscall_64_num2name[102]="getitimer" +__syscall_64_name2num["getitimer"]=102 +__syscall_64_name2num["getitimer"]=102 +__syscall_64_num2name[236]="get_mempolicy" +__syscall_64_num2name[236]="get_mempolicy" +__syscall_64_name2num["get_mempolicy"]=236 +__syscall_64_name2num["get_mempolicy"]=236 +__syscall_64_num2name[205]="getpeername" +__syscall_64_num2name[205]="getpeername" +__syscall_64_name2num["getpeername"]=205 +__syscall_64_name2num["getpeername"]=205 +__syscall_64_num2name[155]="getpgid" +__syscall_64_num2name[155]="getpgid" +__syscall_64_name2num["getpgid"]=155 +__syscall_64_name2num["getpgid"]=155 +__syscall_64_num2name[172]="getpid" +__syscall_64_num2name[172]="getpid" +__syscall_64_name2num["getpid"]=172 +__syscall_64_name2num["getpid"]=172 +__syscall_64_num2name[173]="getppid" +__syscall_64_num2name[173]="getppid" +__syscall_64_name2num["getppid"]=173 +__syscall_64_name2num["getppid"]=173 +__syscall_64_num2name[141]="getpriority" +__syscall_64_num2name[141]="getpriority" +__syscall_64_name2num["getpriority"]=141 +__syscall_64_name2num["getpriority"]=141 +__syscall_64_num2name[278]="getrandom" +__syscall_64_num2name[278]="getrandom" +__syscall_64_name2num["getrandom"]=278 +__syscall_64_name2num["getrandom"]=278 +__syscall_64_num2name[150]="getresgid" +__syscall_64_num2name[150]="getresgid" +__syscall_64_name2num["getresgid"]=150 +__syscall_64_name2num["getresgid"]=150 +__syscall_64_num2name[148]="getresuid" +__syscall_64_num2name[148]="getresuid" +__syscall_64_name2num["getresuid"]=148 +__syscall_64_name2num["getresuid"]=148 +__syscall_64_num2name[163]="getrlimit" +__syscall_64_num2name[163]="getrlimit" +__syscall_64_name2num["getrlimit"]=163 +__syscall_64_name2num["getrlimit"]=163 +__syscall_64_num2name[100]="get_robust_list" +__syscall_64_num2name[100]="get_robust_list" +__syscall_64_name2num["get_robust_list"]=100 +__syscall_64_name2num["get_robust_list"]=100 +__syscall_64_num2name[165]="getrusage" +__syscall_64_num2name[165]="getrusage" +__syscall_64_name2num["getrusage"]=165 +__syscall_64_name2num["getrusage"]=165 +__syscall_64_num2name[156]="getsid" +__syscall_64_num2name[156]="getsid" +__syscall_64_name2num["getsid"]=156 +__syscall_64_name2num["getsid"]=156 +__syscall_64_num2name[204]="getsockname" +__syscall_64_num2name[204]="getsockname" +__syscall_64_name2num["getsockname"]=204 +__syscall_64_name2num["getsockname"]=204 +__syscall_64_num2name[209]="getsockopt" +__syscall_64_num2name[209]="getsockopt" +__syscall_64_name2num["getsockopt"]=209 +__syscall_64_name2num["getsockopt"]=209 +__syscall_64_num2name[178]="gettid" +__syscall_64_num2name[178]="gettid" +__syscall_64_name2num["gettid"]=178 +__syscall_64_name2num["gettid"]=178 +__syscall_64_num2name[169]="gettimeofday" +__syscall_64_num2name[169]="gettimeofday" +__syscall_64_name2num["gettimeofday"]=169 +__syscall_64_name2num["gettimeofday"]=169 +__syscall_64_num2name[174]="getuid" +__syscall_64_num2name[174]="getuid" +__syscall_64_name2num["getuid"]=174 +__syscall_64_name2num["getuid"]=174 +__syscall_64_num2name[8]="getxattr" +__syscall_64_num2name[8]="getxattr" +__syscall_64_name2num["getxattr"]=8 +__syscall_64_name2num["getxattr"]=8 +__syscall_64_num2name[105]="init_module" +__syscall_64_num2name[105]="init_module" +__syscall_64_name2num["init_module"]=105 +__syscall_64_name2num["init_module"]=105 +__syscall_64_num2name[27]="inotify_add_watch" +__syscall_64_num2name[27]="inotify_add_watch" +__syscall_64_name2num["inotify_add_watch"]=27 +__syscall_64_name2num["inotify_add_watch"]=27 +__syscall_64_num2name[26]="inotify_init1" +__syscall_64_num2name[26]="inotify_init1" +__syscall_64_name2num["inotify_init1"]=26 +__syscall_64_name2num["inotify_init1"]=26 +__syscall_64_num2name[28]="inotify_rm_watch" +__syscall_64_num2name[28]="inotify_rm_watch" +__syscall_64_name2num["inotify_rm_watch"]=28 +__syscall_64_name2num["inotify_rm_watch"]=28 +__syscall_64_num2name[3]="io_cancel" +__syscall_64_num2name[3]="io_cancel" +__syscall_64_name2num["io_cancel"]=3 +__syscall_64_name2num["io_cancel"]=3 +__syscall_64_num2name[29]="ioctl" +__syscall_64_num2name[29]="ioctl" +__syscall_64_name2num["ioctl"]=29 +__syscall_64_name2num["ioctl"]=29 +__syscall_64_num2name[1]="io_destroy" +__syscall_64_num2name[1]="io_destroy" +__syscall_64_name2num["io_destroy"]=1 +__syscall_64_name2num["io_destroy"]=1 +__syscall_64_num2name[4]="io_getevents" +__syscall_64_num2name[4]="io_getevents" +__syscall_64_name2num["io_getevents"]=4 +__syscall_64_name2num["io_getevents"]=4 +__syscall_64_num2name[292]="io_pgetevents" +__syscall_64_num2name[292]="io_pgetevents" +__syscall_64_name2num["io_pgetevents"]=292 +__syscall_64_name2num["io_pgetevents"]=292 +__syscall_64_num2name[31]="ioprio_get" +__syscall_64_num2name[31]="ioprio_get" +__syscall_64_name2num["ioprio_get"]=31 +__syscall_64_name2num["ioprio_get"]=31 +__syscall_64_num2name[30]="ioprio_set" +__syscall_64_num2name[30]="ioprio_set" +__syscall_64_name2num["ioprio_set"]=30 +__syscall_64_name2num["ioprio_set"]=30 +__syscall_64_num2name[0]="io_setup" +__syscall_64_num2name[0]="io_setup" +__syscall_64_name2num["io_setup"]=0 +__syscall_64_name2num["io_setup"]=0 +__syscall_64_num2name[2]="io_submit" +__syscall_64_num2name[2]="io_submit" +__syscall_64_name2num["io_submit"]=2 +__syscall_64_name2num["io_submit"]=2 +__syscall_64_num2name[0+426]="io_uring_enter" +__syscall_64_num2name[0+426]="io_uring_enter" +__syscall_64_name2num["io_uring_enter"]=0+426 +__syscall_64_name2num["io_uring_enter"]=0+426 +__syscall_64_num2name[0+427]="io_uring_register" +__syscall_64_num2name[0+427]="io_uring_register" +__syscall_64_name2num["io_uring_register"]=0+427 +__syscall_64_name2num["io_uring_register"]=0+427 +__syscall_64_num2name[0+425]="io_uring_setup" +__syscall_64_num2name[0+425]="io_uring_setup" +__syscall_64_name2num["io_uring_setup"]=0+425 +__syscall_64_name2num["io_uring_setup"]=0+425 +__syscall_64_num2name[272]="kcmp" +__syscall_64_num2name[272]="kcmp" +__syscall_64_name2num["kcmp"]=272 +__syscall_64_name2num["kcmp"]=272 +__syscall_64_num2name[294]="kexec_file_load" +__syscall_64_num2name[294]="kexec_file_load" +__syscall_64_name2num["kexec_file_load"]=294 +__syscall_64_name2num["kexec_file_load"]=294 +__syscall_64_num2name[104]="kexec_load" +__syscall_64_num2name[104]="kexec_load" +__syscall_64_name2num["kexec_load"]=104 +__syscall_64_name2num["kexec_load"]=104 +__syscall_64_num2name[219]="keyctl" +__syscall_64_num2name[219]="keyctl" +__syscall_64_name2num["keyctl"]=219 +__syscall_64_name2num["keyctl"]=219 +__syscall_64_num2name[129]="kill" +__syscall_64_num2name[129]="kill" +__syscall_64_name2num["kill"]=129 +__syscall_64_name2num["kill"]=129 +__syscall_64_num2name[0+445]="landlock_add_rule" +__syscall_64_num2name[0+445]="landlock_add_rule" +__syscall_64_name2num["landlock_add_rule"]=0+445 +__syscall_64_name2num["landlock_add_rule"]=0+445 +__syscall_64_num2name[0+444]="landlock_create_ruleset" +__syscall_64_num2name[0+444]="landlock_create_ruleset" +__syscall_64_name2num["landlock_create_ruleset"]=0+444 +__syscall_64_name2num["landlock_create_ruleset"]=0+444 +__syscall_64_num2name[0+446]="landlock_restrict_self" +__syscall_64_num2name[0+446]="landlock_restrict_self" +__syscall_64_name2num["landlock_restrict_self"]=0+446 +__syscall_64_name2num["landlock_restrict_self"]=0+446 +__syscall_64_num2name[9]="lgetxattr" +__syscall_64_num2name[9]="lgetxattr" +__syscall_64_name2num["lgetxattr"]=9 +__syscall_64_name2num["lgetxattr"]=9 +__syscall_64_num2name[37]="linkat" +__syscall_64_num2name[37]="linkat" +__syscall_64_name2num["linkat"]=37 +__syscall_64_name2num["linkat"]=37 +__syscall_64_num2name[201]="listen" +__syscall_64_num2name[201]="listen" +__syscall_64_name2num["listen"]=201 +__syscall_64_name2num["listen"]=201 +__syscall_64_num2name[0+458]="listmount" +__syscall_64_num2name[0+458]="listmount" +__syscall_64_name2num["listmount"]=0+458 +__syscall_64_name2num["listmount"]=0+458 +__syscall_64_num2name[11]="listxattr" +__syscall_64_num2name[11]="listxattr" +__syscall_64_name2num["listxattr"]=11 +__syscall_64_name2num["listxattr"]=11 +__syscall_64_num2name[12]="llistxattr" +__syscall_64_num2name[12]="llistxattr" +__syscall_64_name2num["llistxattr"]=12 +__syscall_64_name2num["llistxattr"]=12 +__syscall_64_num2name[18]="lookup_dcookie" +__syscall_64_num2name[18]="lookup_dcookie" +__syscall_64_name2num["lookup_dcookie"]=18 +__syscall_64_name2num["lookup_dcookie"]=18 +__syscall_64_num2name[15]="lremovexattr" +__syscall_64_num2name[15]="lremovexattr" +__syscall_64_name2num["lremovexattr"]=15 +__syscall_64_name2num["lremovexattr"]=15 +__syscall_64_num2name[62]="lseek" +__syscall_64_num2name[62]="lseek" +__syscall_64_name2num["lseek"]=62 +__syscall_64_name2num["lseek"]=62 +__syscall_64_num2name[6]="lsetxattr" +__syscall_64_num2name[6]="lsetxattr" +__syscall_64_name2num["lsetxattr"]=6 +__syscall_64_name2num["lsetxattr"]=6 +__syscall_64_num2name[0+459]="lsm_get_self_attr" +__syscall_64_num2name[0+459]="lsm_get_self_attr" +__syscall_64_name2num["lsm_get_self_attr"]=0+459 +__syscall_64_name2num["lsm_get_self_attr"]=0+459 +__syscall_64_num2name[0+461]="lsm_list_modules" +__syscall_64_num2name[0+461]="lsm_list_modules" +__syscall_64_name2num["lsm_list_modules"]=0+461 +__syscall_64_name2num["lsm_list_modules"]=0+461 +__syscall_64_num2name[0+460]="lsm_set_self_attr" +__syscall_64_num2name[0+460]="lsm_set_self_attr" +__syscall_64_name2num["lsm_set_self_attr"]=0+460 +__syscall_64_name2num["lsm_set_self_attr"]=0+460 +__syscall_64_num2name[233]="madvise" +__syscall_64_num2name[233]="madvise" +__syscall_64_name2num["madvise"]=233 +__syscall_64_name2num["madvise"]=233 +__syscall_64_num2name[0+453]="map_shadow_stack" +__syscall_64_num2name[0+453]="map_shadow_stack" +__syscall_64_name2num["map_shadow_stack"]=0+453 +__syscall_64_name2num["map_shadow_stack"]=0+453 +__syscall_64_num2name[235]="mbind" +__syscall_64_num2name[235]="mbind" +__syscall_64_name2num["mbind"]=235 +__syscall_64_name2num["mbind"]=235 +__syscall_64_num2name[283]="membarrier" +__syscall_64_num2name[283]="membarrier" +__syscall_64_name2num["membarrier"]=283 +__syscall_64_name2num["membarrier"]=283 +__syscall_64_num2name[279]="memfd_create" +__syscall_64_num2name[279]="memfd_create" +__syscall_64_name2num["memfd_create"]=279 +__syscall_64_name2num["memfd_create"]=279 +__syscall_64_num2name[0+447]="memfd_secret" +__syscall_64_num2name[0+447]="memfd_secret" +__syscall_64_name2num["memfd_secret"]=0+447 +__syscall_64_name2num["memfd_secret"]=0+447 +__syscall_64_num2name[238]="migrate_pages" +__syscall_64_num2name[238]="migrate_pages" +__syscall_64_name2num["migrate_pages"]=238 +__syscall_64_name2num["migrate_pages"]=238 +__syscall_64_num2name[232]="mincore" +__syscall_64_num2name[232]="mincore" +__syscall_64_name2num["mincore"]=232 +__syscall_64_name2num["mincore"]=232 +__syscall_64_num2name[34]="mkdirat" +__syscall_64_num2name[34]="mkdirat" +__syscall_64_name2num["mkdirat"]=34 +__syscall_64_name2num["mkdirat"]=34 +__syscall_64_num2name[33]="mknodat" +__syscall_64_num2name[33]="mknodat" +__syscall_64_name2num["mknodat"]=33 +__syscall_64_name2num["mknodat"]=33 +__syscall_64_num2name[228]="mlock" +__syscall_64_num2name[228]="mlock" +__syscall_64_num2name[284]="mlock2" +__syscall_64_num2name[284]="mlock2" +__syscall_64_name2num["mlock"]=228 +__syscall_64_name2num["mlock"]=228 +__syscall_64_name2num["mlock2"]=284 +__syscall_64_name2num["mlock2"]=284 +__syscall_64_num2name[230]="mlockall" +__syscall_64_num2name[230]="mlockall" +__syscall_64_name2num["mlockall"]=230 +__syscall_64_name2num["mlockall"]=230 +__syscall_64_num2name[222]="mmap" +__syscall_64_num2name[222]="mmap" +__syscall_64_name2num["mmap"]=222 +__syscall_64_name2num["mmap"]=222 +__syscall_64_num2name[40]="mount" +__syscall_64_num2name[40]="mount" +__syscall_64_name2num["mount"]=40 +__syscall_64_name2num["mount"]=40 +__syscall_64_num2name[0+442]="mount_setattr" +__syscall_64_num2name[0+442]="mount_setattr" +__syscall_64_name2num["mount_setattr"]=0+442 +__syscall_64_name2num["mount_setattr"]=0+442 +__syscall_64_num2name[0+429]="move_mount" +__syscall_64_num2name[0+429]="move_mount" +__syscall_64_name2num["move_mount"]=0+429 +__syscall_64_name2num["move_mount"]=0+429 +__syscall_64_num2name[239]="move_pages" +__syscall_64_num2name[239]="move_pages" +__syscall_64_name2num["move_pages"]=239 +__syscall_64_name2num["move_pages"]=239 +__syscall_64_num2name[226]="mprotect" +__syscall_64_num2name[226]="mprotect" +__syscall_64_name2num["mprotect"]=226 +__syscall_64_name2num["mprotect"]=226 +__syscall_64_num2name[185]="mq_getsetattr" +__syscall_64_num2name[185]="mq_getsetattr" +__syscall_64_name2num["mq_getsetattr"]=185 +__syscall_64_name2num["mq_getsetattr"]=185 +__syscall_64_num2name[184]="mq_notify" +__syscall_64_num2name[184]="mq_notify" +__syscall_64_name2num["mq_notify"]=184 +__syscall_64_name2num["mq_notify"]=184 +__syscall_64_num2name[180]="mq_open" +__syscall_64_num2name[180]="mq_open" +__syscall_64_name2num["mq_open"]=180 +__syscall_64_name2num["mq_open"]=180 +__syscall_64_num2name[183]="mq_timedreceive" +__syscall_64_num2name[183]="mq_timedreceive" +__syscall_64_name2num["mq_timedreceive"]=183 +__syscall_64_name2num["mq_timedreceive"]=183 +__syscall_64_num2name[182]="mq_timedsend" +__syscall_64_num2name[182]="mq_timedsend" +__syscall_64_name2num["mq_timedsend"]=182 +__syscall_64_name2num["mq_timedsend"]=182 +__syscall_64_num2name[181]="mq_unlink" +__syscall_64_num2name[181]="mq_unlink" +__syscall_64_name2num["mq_unlink"]=181 +__syscall_64_name2num["mq_unlink"]=181 +__syscall_64_num2name[216]="mremap" +__syscall_64_num2name[216]="mremap" +__syscall_64_name2num["mremap"]=216 +__syscall_64_name2num["mremap"]=216 +__syscall_64_num2name[0+462]="mseal" +__syscall_64_num2name[0+462]="mseal" +__syscall_64_name2num["mseal"]=0+462 +__syscall_64_name2num["mseal"]=0+462 +__syscall_64_num2name[187]="msgctl" +__syscall_64_num2name[187]="msgctl" +__syscall_64_name2num["msgctl"]=187 +__syscall_64_name2num["msgctl"]=187 +__syscall_64_num2name[186]="msgget" +__syscall_64_num2name[186]="msgget" +__syscall_64_name2num["msgget"]=186 +__syscall_64_name2num["msgget"]=186 +__syscall_64_num2name[188]="msgrcv" +__syscall_64_num2name[188]="msgrcv" +__syscall_64_name2num["msgrcv"]=188 +__syscall_64_name2num["msgrcv"]=188 +__syscall_64_num2name[189]="msgsnd" +__syscall_64_num2name[189]="msgsnd" +__syscall_64_name2num["msgsnd"]=189 +__syscall_64_name2num["msgsnd"]=189 +__syscall_64_num2name[227]="msync" +__syscall_64_num2name[227]="msync" +__syscall_64_name2num["msync"]=227 +__syscall_64_name2num["msync"]=227 +__syscall_64_num2name[229]="munlock" +__syscall_64_num2name[229]="munlock" +__syscall_64_name2num["munlock"]=229 +__syscall_64_name2num["munlock"]=229 +__syscall_64_num2name[231]="munlockall" +__syscall_64_num2name[231]="munlockall" +__syscall_64_name2num["munlockall"]=231 +__syscall_64_name2num["munlockall"]=231 +__syscall_64_num2name[215]="munmap" +__syscall_64_num2name[215]="munmap" +__syscall_64_name2num["munmap"]=215 +__syscall_64_name2num["munmap"]=215 +__syscall_64_num2name[264]="name_to_handle_at" +__syscall_64_num2name[264]="name_to_handle_at" +__syscall_64_name2num["name_to_handle_at"]=264 +__syscall_64_name2num["name_to_handle_at"]=264 +__syscall_64_num2name[101]="nanosleep" +__syscall_64_num2name[101]="nanosleep" +__syscall_64_name2num["nanosleep"]=101 +__syscall_64_name2num["nanosleep"]=101 +__syscall_64_num2name[79]="newfstatat" +__syscall_64_num2name[79]="newfstatat" +__syscall_64_name2num["newfstatat"]=79 +__syscall_64_name2num["newfstatat"]=79 +__syscall_64_num2name[42]="nfsservctl" +__syscall_64_num2name[42]="nfsservctl" +__syscall_64_name2num["nfsservctl"]=42 +__syscall_64_name2num["nfsservctl"]=42 +__syscall_64_num2name[56]="openat" +__syscall_64_num2name[56]="openat" +__syscall_64_num2name[0+437]="openat2" +__syscall_64_num2name[0+437]="openat2" +__syscall_64_name2num["openat2"]=0+437 +__syscall_64_name2num["openat2"]=0+437 +__syscall_64_name2num["openat"]=56 +__syscall_64_name2num["openat"]=56 +__syscall_64_num2name[265]="open_by_handle_at" +__syscall_64_num2name[265]="open_by_handle_at" +__syscall_64_name2num["open_by_handle_at"]=265 +__syscall_64_name2num["open_by_handle_at"]=265 +__syscall_64_num2name[0+428]="open_tree" +__syscall_64_num2name[0+428]="open_tree" +__syscall_64_name2num["open_tree"]=0+428 +__syscall_64_name2num["open_tree"]=0+428 +__syscall_64_num2name[241]="perf_event_open" +__syscall_64_num2name[241]="perf_event_open" +__syscall_64_name2num["perf_event_open"]=241 +__syscall_64_name2num["perf_event_open"]=241 +__syscall_64_num2name[92]="personality" +__syscall_64_num2name[92]="personality" +__syscall_64_name2num["personality"]=92 +__syscall_64_name2num["personality"]=92 +__syscall_64_num2name[0+438]="pidfd_getfd" +__syscall_64_num2name[0+438]="pidfd_getfd" +__syscall_64_name2num["pidfd_getfd"]=0+438 +__syscall_64_name2num["pidfd_getfd"]=0+438 +__syscall_64_num2name[0+434]="pidfd_open" +__syscall_64_num2name[0+434]="pidfd_open" +__syscall_64_name2num["pidfd_open"]=0+434 +__syscall_64_name2num["pidfd_open"]=0+434 +__syscall_64_num2name[0+424]="pidfd_send_signal" +__syscall_64_num2name[0+424]="pidfd_send_signal" +__syscall_64_name2num["pidfd_send_signal"]=0+424 +__syscall_64_name2num["pidfd_send_signal"]=0+424 +__syscall_64_num2name[59]="pipe2" +__syscall_64_num2name[59]="pipe2" +__syscall_64_name2num["pipe2"]=59 +__syscall_64_name2num["pipe2"]=59 +__syscall_64_num2name[41]="pivot_root" +__syscall_64_num2name[41]="pivot_root" +__syscall_64_name2num["pivot_root"]=41 +__syscall_64_name2num["pivot_root"]=41 +__syscall_64_num2name[289]="pkey_alloc" +__syscall_64_num2name[289]="pkey_alloc" +__syscall_64_name2num["pkey_alloc"]=289 +__syscall_64_name2num["pkey_alloc"]=289 +__syscall_64_num2name[290]="pkey_free" +__syscall_64_num2name[290]="pkey_free" +__syscall_64_name2num["pkey_free"]=290 +__syscall_64_name2num["pkey_free"]=290 +__syscall_64_num2name[288]="pkey_mprotect" +__syscall_64_num2name[288]="pkey_mprotect" +__syscall_64_name2num["pkey_mprotect"]=288 +__syscall_64_name2num["pkey_mprotect"]=288 +__syscall_64_num2name[73]="ppoll" +__syscall_64_num2name[73]="ppoll" +__syscall_64_name2num["ppoll"]=73 +__syscall_64_name2num["ppoll"]=73 +__syscall_64_num2name[167]="prctl" +__syscall_64_num2name[167]="prctl" +__syscall_64_name2num["prctl"]=167 +__syscall_64_name2num["prctl"]=167 +__syscall_64_num2name[67]="pread64" +__syscall_64_num2name[67]="pread64" +__syscall_64_name2num["pread64"]=67 +__syscall_64_name2num["pread64"]=67 +__syscall_64_num2name[69]="preadv" +__syscall_64_num2name[69]="preadv" +__syscall_64_num2name[286]="preadv2" +__syscall_64_num2name[286]="preadv2" +__syscall_64_name2num["preadv2"]=286 +__syscall_64_name2num["preadv2"]=286 +__syscall_64_name2num["preadv"]=69 +__syscall_64_name2num["preadv"]=69 +__syscall_64_num2name[261]="prlimit64" +__syscall_64_num2name[261]="prlimit64" +__syscall_64_name2num["prlimit64"]=261 +__syscall_64_name2num["prlimit64"]=261 +__syscall_64_num2name[0+440]="process_madvise" +__syscall_64_num2name[0+440]="process_madvise" +__syscall_64_name2num["process_madvise"]=0+440 +__syscall_64_name2num["process_madvise"]=0+440 +__syscall_64_num2name[0+448]="process_mrelease" +__syscall_64_num2name[0+448]="process_mrelease" +__syscall_64_name2num["process_mrelease"]=0+448 +__syscall_64_name2num["process_mrelease"]=0+448 +__syscall_64_num2name[270]="process_vm_readv" +__syscall_64_num2name[270]="process_vm_readv" +__syscall_64_name2num["process_vm_readv"]=270 +__syscall_64_name2num["process_vm_readv"]=270 +__syscall_64_num2name[271]="process_vm_writev" +__syscall_64_num2name[271]="process_vm_writev" +__syscall_64_name2num["process_vm_writev"]=271 +__syscall_64_name2num["process_vm_writev"]=271 +__syscall_64_num2name[72]="pselect6" +__syscall_64_num2name[72]="pselect6" +__syscall_64_name2num["pselect6"]=72 +__syscall_64_name2num["pselect6"]=72 +__syscall_64_num2name[117]="ptrace" +__syscall_64_num2name[117]="ptrace" +__syscall_64_name2num["ptrace"]=117 +__syscall_64_name2num["ptrace"]=117 +__syscall_64_num2name[68]="pwrite64" +__syscall_64_num2name[68]="pwrite64" +__syscall_64_name2num["pwrite64"]=68 +__syscall_64_name2num["pwrite64"]=68 +__syscall_64_num2name[70]="pwritev" +__syscall_64_num2name[70]="pwritev" +__syscall_64_num2name[287]="pwritev2" +__syscall_64_num2name[287]="pwritev2" +__syscall_64_name2num["pwritev2"]=287 +__syscall_64_name2num["pwritev2"]=287 +__syscall_64_name2num["pwritev"]=70 +__syscall_64_name2num["pwritev"]=70 +__syscall_64_num2name[60]="quotactl" +__syscall_64_num2name[60]="quotactl" +__syscall_64_name2num["quotactl"]=60 +__syscall_64_name2num["quotactl"]=60 +__syscall_64_num2name[0+443]="quotactl_fd" +__syscall_64_num2name[0+443]="quotactl_fd" +__syscall_64_name2num["quotactl_fd"]=0+443 +__syscall_64_name2num["quotactl_fd"]=0+443 +__syscall_64_num2name[63]="read" +__syscall_64_num2name[63]="read" +__syscall_64_name2num["read"]=63 +__syscall_64_name2num["read"]=63 +__syscall_64_num2name[213]="readahead" +__syscall_64_num2name[213]="readahead" +__syscall_64_name2num["readahead"]=213 +__syscall_64_name2num["readahead"]=213 +__syscall_64_num2name[78]="readlinkat" +__syscall_64_num2name[78]="readlinkat" +__syscall_64_name2num["readlinkat"]=78 +__syscall_64_name2num["readlinkat"]=78 +__syscall_64_num2name[65]="readv" +__syscall_64_num2name[65]="readv" +__syscall_64_name2num["readv"]=65 +__syscall_64_name2num["readv"]=65 +__syscall_64_num2name[142]="reboot" +__syscall_64_num2name[142]="reboot" +__syscall_64_name2num["reboot"]=142 +__syscall_64_name2num["reboot"]=142 +__syscall_64_num2name[207]="recvfrom" +__syscall_64_num2name[207]="recvfrom" +__syscall_64_name2num["recvfrom"]=207 +__syscall_64_name2num["recvfrom"]=207 +__syscall_64_num2name[243]="recvmmsg" +__syscall_64_num2name[243]="recvmmsg" +__syscall_64_name2num["recvmmsg"]=243 +__syscall_64_name2num["recvmmsg"]=243 +__syscall_64_num2name[212]="recvmsg" +__syscall_64_num2name[212]="recvmsg" +__syscall_64_name2num["recvmsg"]=212 +__syscall_64_name2num["recvmsg"]=212 +__syscall_64_num2name[234]="remap_file_pages" +__syscall_64_num2name[234]="remap_file_pages" +__syscall_64_name2num["remap_file_pages"]=234 +__syscall_64_name2num["remap_file_pages"]=234 +__syscall_64_num2name[14]="removexattr" +__syscall_64_num2name[14]="removexattr" +__syscall_64_name2num["removexattr"]=14 +__syscall_64_name2num["removexattr"]=14 +__syscall_64_num2name[38]="renameat" +__syscall_64_num2name[38]="renameat" +__syscall_64_num2name[276]="renameat2" +__syscall_64_num2name[276]="renameat2" +__syscall_64_name2num["renameat2"]=276 +__syscall_64_name2num["renameat2"]=276 +__syscall_64_name2num["renameat"]=38 +__syscall_64_name2num["renameat"]=38 +__syscall_64_num2name[218]="request_key" +__syscall_64_num2name[218]="request_key" +__syscall_64_name2num["request_key"]=218 +__syscall_64_name2num["request_key"]=218 +__syscall_64_num2name[128]="restart_syscall" +__syscall_64_num2name[128]="restart_syscall" +__syscall_64_name2num["restart_syscall"]=128 +__syscall_64_name2num["restart_syscall"]=128 +__syscall_64_num2name[293]="rseq" +__syscall_64_num2name[293]="rseq" +__syscall_64_name2num["rseq"]=293 +__syscall_64_name2num["rseq"]=293 +__syscall_64_num2name[134]="rt_sigaction" +__syscall_64_num2name[134]="rt_sigaction" +__syscall_64_name2num["rt_sigaction"]=134 +__syscall_64_name2num["rt_sigaction"]=134 +__syscall_64_num2name[136]="rt_sigpending" +__syscall_64_num2name[136]="rt_sigpending" +__syscall_64_name2num["rt_sigpending"]=136 +__syscall_64_name2num["rt_sigpending"]=136 +__syscall_64_num2name[135]="rt_sigprocmask" +__syscall_64_num2name[135]="rt_sigprocmask" +__syscall_64_name2num["rt_sigprocmask"]=135 +__syscall_64_name2num["rt_sigprocmask"]=135 +__syscall_64_num2name[138]="rt_sigqueueinfo" +__syscall_64_num2name[138]="rt_sigqueueinfo" +__syscall_64_name2num["rt_sigqueueinfo"]=138 +__syscall_64_name2num["rt_sigqueueinfo"]=138 +__syscall_64_num2name[139]="rt_sigreturn" +__syscall_64_num2name[139]="rt_sigreturn" +__syscall_64_name2num["rt_sigreturn"]=139 +__syscall_64_name2num["rt_sigreturn"]=139 +__syscall_64_num2name[133]="rt_sigsuspend" +__syscall_64_num2name[133]="rt_sigsuspend" +__syscall_64_name2num["rt_sigsuspend"]=133 +__syscall_64_name2num["rt_sigsuspend"]=133 +__syscall_64_num2name[137]="rt_sigtimedwait" +__syscall_64_num2name[137]="rt_sigtimedwait" +__syscall_64_name2num["rt_sigtimedwait"]=137 +__syscall_64_name2num["rt_sigtimedwait"]=137 +__syscall_64_num2name[240]="rt_tgsigqueueinfo" +__syscall_64_num2name[240]="rt_tgsigqueueinfo" +__syscall_64_name2num["rt_tgsigqueueinfo"]=240 +__syscall_64_name2num["rt_tgsigqueueinfo"]=240 +__syscall_64_num2name[123]="sched_getaffinity" +__syscall_64_num2name[123]="sched_getaffinity" +__syscall_64_name2num["sched_getaffinity"]=123 +__syscall_64_name2num["sched_getaffinity"]=123 +__syscall_64_num2name[275]="sched_getattr" +__syscall_64_num2name[275]="sched_getattr" +__syscall_64_name2num["sched_getattr"]=275 +__syscall_64_name2num["sched_getattr"]=275 +__syscall_64_num2name[121]="sched_getparam" +__syscall_64_num2name[121]="sched_getparam" +__syscall_64_name2num["sched_getparam"]=121 +__syscall_64_name2num["sched_getparam"]=121 +__syscall_64_num2name[125]="sched_get_priority_max" +__syscall_64_num2name[125]="sched_get_priority_max" +__syscall_64_name2num["sched_get_priority_max"]=125 +__syscall_64_name2num["sched_get_priority_max"]=125 +__syscall_64_num2name[126]="sched_get_priority_min" +__syscall_64_num2name[126]="sched_get_priority_min" +__syscall_64_name2num["sched_get_priority_min"]=126 +__syscall_64_name2num["sched_get_priority_min"]=126 +__syscall_64_num2name[120]="sched_getscheduler" +__syscall_64_num2name[120]="sched_getscheduler" +__syscall_64_name2num["sched_getscheduler"]=120 +__syscall_64_name2num["sched_getscheduler"]=120 +__syscall_64_num2name[127]="sched_rr_get_interval" +__syscall_64_num2name[127]="sched_rr_get_interval" +__syscall_64_name2num["sched_rr_get_interval"]=127 +__syscall_64_name2num["sched_rr_get_interval"]=127 +__syscall_64_num2name[122]="sched_setaffinity" +__syscall_64_num2name[122]="sched_setaffinity" +__syscall_64_name2num["sched_setaffinity"]=122 +__syscall_64_name2num["sched_setaffinity"]=122 +__syscall_64_num2name[274]="sched_setattr" +__syscall_64_num2name[274]="sched_setattr" +__syscall_64_name2num["sched_setattr"]=274 +__syscall_64_name2num["sched_setattr"]=274 +__syscall_64_num2name[118]="sched_setparam" +__syscall_64_num2name[118]="sched_setparam" +__syscall_64_name2num["sched_setparam"]=118 +__syscall_64_name2num["sched_setparam"]=118 +__syscall_64_num2name[119]="sched_setscheduler" +__syscall_64_num2name[119]="sched_setscheduler" +__syscall_64_name2num["sched_setscheduler"]=119 +__syscall_64_name2num["sched_setscheduler"]=119 +__syscall_64_num2name[124]="sched_yield" +__syscall_64_num2name[124]="sched_yield" +__syscall_64_name2num["sched_yield"]=124 +__syscall_64_name2num["sched_yield"]=124 +__syscall_64_num2name[277]="seccomp" +__syscall_64_num2name[277]="seccomp" +__syscall_64_name2num["seccomp"]=277 +__syscall_64_name2num["seccomp"]=277 +__syscall_64_num2name[191]="semctl" +__syscall_64_num2name[191]="semctl" +__syscall_64_name2num["semctl"]=191 +__syscall_64_name2num["semctl"]=191 +__syscall_64_num2name[190]="semget" +__syscall_64_num2name[190]="semget" +__syscall_64_name2num["semget"]=190 +__syscall_64_name2num["semget"]=190 +__syscall_64_num2name[193]="semop" +__syscall_64_num2name[193]="semop" +__syscall_64_name2num["semop"]=193 +__syscall_64_name2num["semop"]=193 +__syscall_64_num2name[192]="semtimedop" +__syscall_64_num2name[192]="semtimedop" +__syscall_64_name2num["semtimedop"]=192 +__syscall_64_name2num["semtimedop"]=192 +__syscall_64_num2name[71]="sendfile" +__syscall_64_num2name[71]="sendfile" +__syscall_64_name2num["sendfile"]=71 +__syscall_64_name2num["sendfile"]=71 +__syscall_64_num2name[269]="sendmmsg" +__syscall_64_num2name[269]="sendmmsg" +__syscall_64_name2num["sendmmsg"]=269 +__syscall_64_name2num["sendmmsg"]=269 +__syscall_64_num2name[211]="sendmsg" +__syscall_64_num2name[211]="sendmsg" +__syscall_64_name2num["sendmsg"]=211 +__syscall_64_name2num["sendmsg"]=211 +__syscall_64_num2name[206]="sendto" +__syscall_64_num2name[206]="sendto" +__syscall_64_name2num["sendto"]=206 +__syscall_64_name2num["sendto"]=206 +__syscall_64_num2name[162]="setdomainname" +__syscall_64_num2name[162]="setdomainname" +__syscall_64_name2num["setdomainname"]=162 +__syscall_64_name2num["setdomainname"]=162 +__syscall_64_num2name[152]="setfsgid" +__syscall_64_num2name[152]="setfsgid" +__syscall_64_name2num["setfsgid"]=152 +__syscall_64_name2num["setfsgid"]=152 +__syscall_64_num2name[151]="setfsuid" +__syscall_64_num2name[151]="setfsuid" +__syscall_64_name2num["setfsuid"]=151 +__syscall_64_name2num["setfsuid"]=151 +__syscall_64_num2name[144]="setgid" +__syscall_64_num2name[144]="setgid" +__syscall_64_name2num["setgid"]=144 +__syscall_64_name2num["setgid"]=144 +__syscall_64_num2name[159]="setgroups" +__syscall_64_num2name[159]="setgroups" +__syscall_64_name2num["setgroups"]=159 +__syscall_64_name2num["setgroups"]=159 +__syscall_64_num2name[161]="sethostname" +__syscall_64_num2name[161]="sethostname" +__syscall_64_name2num["sethostname"]=161 +__syscall_64_name2num["sethostname"]=161 +__syscall_64_num2name[103]="setitimer" +__syscall_64_num2name[103]="setitimer" +__syscall_64_name2num["setitimer"]=103 +__syscall_64_name2num["setitimer"]=103 +__syscall_64_num2name[237]="set_mempolicy" +__syscall_64_num2name[237]="set_mempolicy" +__syscall_64_name2num["set_mempolicy"]=237 +__syscall_64_name2num["set_mempolicy"]=237 +__syscall_64_num2name[0+450]="set_mempolicy_home_node" +__syscall_64_num2name[0+450]="set_mempolicy_home_node" +__syscall_64_name2num["set_mempolicy_home_node"]=0+450 +__syscall_64_name2num["set_mempolicy_home_node"]=0+450 +__syscall_64_num2name[268]="setns" +__syscall_64_num2name[268]="setns" +__syscall_64_name2num["setns"]=268 +__syscall_64_name2num["setns"]=268 +__syscall_64_num2name[154]="setpgid" +__syscall_64_num2name[154]="setpgid" +__syscall_64_name2num["setpgid"]=154 +__syscall_64_name2num["setpgid"]=154 +__syscall_64_num2name[140]="setpriority" +__syscall_64_num2name[140]="setpriority" +__syscall_64_name2num["setpriority"]=140 +__syscall_64_name2num["setpriority"]=140 +__syscall_64_num2name[143]="setregid" +__syscall_64_num2name[143]="setregid" +__syscall_64_name2num["setregid"]=143 +__syscall_64_name2num["setregid"]=143 +__syscall_64_num2name[149]="setresgid" +__syscall_64_num2name[149]="setresgid" +__syscall_64_name2num["setresgid"]=149 +__syscall_64_name2num["setresgid"]=149 +__syscall_64_num2name[147]="setresuid" +__syscall_64_num2name[147]="setresuid" +__syscall_64_name2num["setresuid"]=147 +__syscall_64_name2num["setresuid"]=147 +__syscall_64_num2name[145]="setreuid" +__syscall_64_num2name[145]="setreuid" +__syscall_64_name2num["setreuid"]=145 +__syscall_64_name2num["setreuid"]=145 +__syscall_64_num2name[164]="setrlimit" +__syscall_64_num2name[164]="setrlimit" +__syscall_64_name2num["setrlimit"]=164 +__syscall_64_name2num["setrlimit"]=164 +__syscall_64_num2name[99]="set_robust_list" +__syscall_64_num2name[99]="set_robust_list" +__syscall_64_name2num["set_robust_list"]=99 +__syscall_64_name2num["set_robust_list"]=99 +__syscall_64_num2name[157]="setsid" +__syscall_64_num2name[157]="setsid" +__syscall_64_name2num["setsid"]=157 +__syscall_64_name2num["setsid"]=157 +__syscall_64_num2name[208]="setsockopt" +__syscall_64_num2name[208]="setsockopt" +__syscall_64_name2num["setsockopt"]=208 +__syscall_64_name2num["setsockopt"]=208 +__syscall_64_num2name[96]="set_tid_address" +__syscall_64_num2name[96]="set_tid_address" +__syscall_64_name2num["set_tid_address"]=96 +__syscall_64_name2num["set_tid_address"]=96 +__syscall_64_num2name[170]="settimeofday" +__syscall_64_num2name[170]="settimeofday" +__syscall_64_name2num["settimeofday"]=170 +__syscall_64_name2num["settimeofday"]=170 +__syscall_64_num2name[146]="setuid" +__syscall_64_num2name[146]="setuid" +__syscall_64_name2num["setuid"]=146 +__syscall_64_name2num["setuid"]=146 +__syscall_64_num2name[5]="setxattr" +__syscall_64_num2name[5]="setxattr" +__syscall_64_name2num["setxattr"]=5 +__syscall_64_name2num["setxattr"]=5 +__syscall_64_num2name[196]="shmat" +__syscall_64_num2name[196]="shmat" +__syscall_64_name2num["shmat"]=196 +__syscall_64_name2num["shmat"]=196 +__syscall_64_num2name[195]="shmctl" +__syscall_64_num2name[195]="shmctl" +__syscall_64_name2num["shmctl"]=195 +__syscall_64_name2num["shmctl"]=195 +__syscall_64_num2name[197]="shmdt" +__syscall_64_num2name[197]="shmdt" +__syscall_64_name2num["shmdt"]=197 +__syscall_64_name2num["shmdt"]=197 +__syscall_64_num2name[194]="shmget" +__syscall_64_num2name[194]="shmget" +__syscall_64_name2num["shmget"]=194 +__syscall_64_name2num["shmget"]=194 +__syscall_64_num2name[210]="shutdown" +__syscall_64_num2name[210]="shutdown" +__syscall_64_name2num["shutdown"]=210 +__syscall_64_name2num["shutdown"]=210 +__syscall_64_num2name[132]="sigaltstack" +__syscall_64_num2name[132]="sigaltstack" +__syscall_64_name2num["sigaltstack"]=132 +__syscall_64_name2num["sigaltstack"]=132 +__syscall_64_num2name[74]="signalfd4" +__syscall_64_num2name[74]="signalfd4" +__syscall_64_name2num["signalfd4"]=74 +__syscall_64_name2num["signalfd4"]=74 +__syscall_64_num2name[198]="socket" +__syscall_64_num2name[198]="socket" +__syscall_64_name2num["socket"]=198 +__syscall_64_name2num["socket"]=198 +__syscall_64_num2name[199]="socketpair" +__syscall_64_num2name[199]="socketpair" +__syscall_64_name2num["socketpair"]=199 +__syscall_64_name2num["socketpair"]=199 +__syscall_64_num2name[76]="splice" +__syscall_64_num2name[76]="splice" +__syscall_64_name2num["splice"]=76 +__syscall_64_name2num["splice"]=76 +__syscall_64_num2name[43]="statfs" +__syscall_64_num2name[43]="statfs" +__syscall_64_name2num["statfs"]=43 +__syscall_64_name2num["statfs"]=43 +__syscall_64_num2name[0+457]="statmount" +__syscall_64_num2name[0+457]="statmount" +__syscall_64_name2num["statmount"]=0+457 +__syscall_64_name2num["statmount"]=0+457 +__syscall_64_num2name[291]="statx" +__syscall_64_num2name[291]="statx" +__syscall_64_name2num["statx"]=291 +__syscall_64_name2num["statx"]=291 +__syscall_64_num2name[225]="swapoff" +__syscall_64_num2name[225]="swapoff" +__syscall_64_name2num["swapoff"]=225 +__syscall_64_name2num["swapoff"]=225 +__syscall_64_num2name[224]="swapon" +__syscall_64_num2name[224]="swapon" +__syscall_64_name2num["swapon"]=224 +__syscall_64_name2num["swapon"]=224 +__syscall_64_num2name[36]="symlinkat" +__syscall_64_num2name[36]="symlinkat" +__syscall_64_name2num["symlinkat"]=36 +__syscall_64_name2num["symlinkat"]=36 +__syscall_64_num2name[81]="sync" +__syscall_64_num2name[81]="sync" +__syscall_64_name2num["sync"]=81 +__syscall_64_name2num["sync"]=81 +__syscall_64_num2name[84]="sync_file_range" +__syscall_64_num2name[84]="sync_file_range" +__syscall_64_name2num["sync_file_range"]=84 +__syscall_64_name2num["sync_file_range"]=84 +__syscall_64_num2name[267]="syncfs" +__syscall_64_num2name[267]="syncfs" +__syscall_64_name2num["syncfs"]=267 +__syscall_64_name2num["syncfs"]=267 +__syscall_64_num2name[179]="sysinfo" +__syscall_64_num2name[179]="sysinfo" +__syscall_64_name2num["sysinfo"]=179 +__syscall_64_name2num["sysinfo"]=179 +__syscall_64_num2name[116]="syslog" +__syscall_64_num2name[116]="syslog" +__syscall_64_name2num["syslog"]=116 +__syscall_64_name2num["syslog"]=116 +__syscall_64_num2name[77]="tee" +__syscall_64_num2name[77]="tee" +__syscall_64_name2num["tee"]=77 +__syscall_64_name2num["tee"]=77 +__syscall_64_num2name[131]="tgkill" +__syscall_64_num2name[131]="tgkill" +__syscall_64_name2num["tgkill"]=131 +__syscall_64_name2num["tgkill"]=131 +__syscall_64_num2name[107]="timer_create" +__syscall_64_num2name[107]="timer_create" +__syscall_64_name2num["timer_create"]=107 +__syscall_64_name2num["timer_create"]=107 +__syscall_64_num2name[111]="timer_delete" +__syscall_64_num2name[111]="timer_delete" +__syscall_64_name2num["timer_delete"]=111 +__syscall_64_name2num["timer_delete"]=111 +__syscall_64_num2name[85]="timerfd_create" +__syscall_64_num2name[85]="timerfd_create" +__syscall_64_name2num["timerfd_create"]=85 +__syscall_64_name2num["timerfd_create"]=85 +__syscall_64_num2name[87]="timerfd_gettime" +__syscall_64_num2name[87]="timerfd_gettime" +__syscall_64_name2num["timerfd_gettime"]=87 +__syscall_64_name2num["timerfd_gettime"]=87 +__syscall_64_num2name[86]="timerfd_settime" +__syscall_64_num2name[86]="timerfd_settime" +__syscall_64_name2num["timerfd_settime"]=86 +__syscall_64_name2num["timerfd_settime"]=86 +__syscall_64_num2name[109]="timer_getoverrun" +__syscall_64_num2name[109]="timer_getoverrun" +__syscall_64_name2num["timer_getoverrun"]=109 +__syscall_64_name2num["timer_getoverrun"]=109 +__syscall_64_num2name[108]="timer_gettime" +__syscall_64_num2name[108]="timer_gettime" +__syscall_64_name2num["timer_gettime"]=108 +__syscall_64_name2num["timer_gettime"]=108 +__syscall_64_num2name[110]="timer_settime" +__syscall_64_num2name[110]="timer_settime" +__syscall_64_name2num["timer_settime"]=110 +__syscall_64_name2num["timer_settime"]=110 +__syscall_64_num2name[153]="times" +__syscall_64_num2name[153]="times" +__syscall_64_name2num["times"]=153 +__syscall_64_name2num["times"]=153 +__syscall_64_num2name[130]="tkill" +__syscall_64_num2name[130]="tkill" +__syscall_64_name2num["tkill"]=130 +__syscall_64_name2num["tkill"]=130 +__syscall_64_num2name[45]="truncate" +__syscall_64_num2name[45]="truncate" +__syscall_64_name2num["truncate"]=45 +__syscall_64_name2num["truncate"]=45 +__syscall_64_num2name[166]="umask" +__syscall_64_num2name[166]="umask" +__syscall_64_name2num["umask"]=166 +__syscall_64_name2num["umask"]=166 +__syscall_64_num2name[39]="umount2" +__syscall_64_num2name[39]="umount2" +__syscall_64_name2num["umount2"]=39 +__syscall_64_name2num["umount2"]=39 +__syscall_64_num2name[160]="uname" +__syscall_64_num2name[160]="uname" +__syscall_64_name2num["uname"]=160 +__syscall_64_name2num["uname"]=160 +__syscall_64_num2name[35]="unlinkat" +__syscall_64_num2name[35]="unlinkat" +__syscall_64_name2num["unlinkat"]=35 +__syscall_64_name2num["unlinkat"]=35 +__syscall_64_num2name[97]="unshare" +__syscall_64_num2name[97]="unshare" +__syscall_64_name2num["unshare"]=97 +__syscall_64_name2num["unshare"]=97 +__syscall_64_num2name[282]="userfaultfd" +__syscall_64_num2name[282]="userfaultfd" +__syscall_64_name2num["userfaultfd"]=282 +__syscall_64_name2num["userfaultfd"]=282 +__syscall_64_num2name[88]="utimensat" +__syscall_64_num2name[88]="utimensat" +__syscall_64_name2num["utimensat"]=88 +__syscall_64_name2num["utimensat"]=88 +__syscall_64_num2name[58]="vhangup" +__syscall_64_num2name[58]="vhangup" +__syscall_64_name2num["vhangup"]=58 +__syscall_64_name2num["vhangup"]=58 +__syscall_64_num2name[75]="vmsplice" +__syscall_64_num2name[75]="vmsplice" +__syscall_64_name2num["vmsplice"]=75 +__syscall_64_name2num["vmsplice"]=75 +__syscall_64_num2name[260]="wait4" +__syscall_64_num2name[260]="wait4" +__syscall_64_name2num["wait4"]=260 +__syscall_64_name2num["wait4"]=260 +__syscall_64_num2name[95]="waitid" +__syscall_64_num2name[95]="waitid" +__syscall_64_name2num["waitid"]=95 +__syscall_64_name2num["waitid"]=95 +__syscall_64_num2name[64]="write" +__syscall_64_num2name[64]="write" +__syscall_64_name2num["write"]=64 +__syscall_64_name2num["write"]=64 +__syscall_64_num2name[66]="writev" +__syscall_64_num2name[66]="writev" +__syscall_64_name2num["writev"]=66 +__syscall_64_name2num["writev"]=66 +%) +} /* probe init */ \ No newline at end of file diff --git a/tapset/linux/syscalls.stpm b/tapset/linux/syscalls.stpm index 9f14a99..3c79bc8 100644 --- a/tapset/linux/syscalls.stpm +++ b/tapset/linux/syscalls.stpm @@ -402,7 +402,7 @@ @define SYSC_CLONE_CHILD_TID_UADDR_ARGNO %( 5 %) %) -%( arch == "i386" || arch == "arm" || arch == "powerpc" || arch == "mips" || arch == "riscv" %? +%( arch == "i386" || arch == "arm" || arch == "powerpc" || arch == "mips" || arch == "riscv" || arch == "loongarch64" %? @define arch_syscall_prefix %( "" %) @define arch_syscall0_prefix %( "" %) @define SYSC_CLONE_CLONE_FLAGS_ARGNO %( 1 %) diff --git a/tapsets.cxx b/tapsets.cxx index 49a0d1d..404a64c 100644 --- a/tapsets.cxx +++ b/tapsets.cxx @@ -2582,6 +2582,7 @@ validate_module_elf (systemtap_session& sess, case EM_AARCH64: expect_machine = "arm64"; break; case EM_MIPS: expect_machine = "mips"; break; case EM_RISCV: expect_machine = "riscv"; break; + case EM_LOONGARCH: expect_machine = "loongarch64"; break; // XXX: fill in some more of these default: expect_machine = "?"; break; } @@ -6961,6 +6962,43 @@ sdt_uprobe_var_expanding_visitor::build_dwarf_registers () DRI ("$29", 29, mips_reg_width); DRI ("$30", 30, mips_reg_width); DRI ("$31", 31, mips_reg_width); + } else if (elf_machine == EM_LOONGARCH) { + Dwarf_Addr bias; + Elf* elf = (dwfl_module_getelf (dw.mod_info->mod, &bias)); + enum regwidths loongarch_reg_width = + (gelf_getclass (elf) == ELFCLASS32) ? SI : DI; // 32-bit: SI 64-bit: DI + DRI ("$r0", 0, loongarch_reg_width); DRI ("$zero", 0, loongarch_reg_width); + DRI ("$r1", 1, loongarch_reg_width); DRI ("$ra", 1, loongarch_reg_width); + DRI ("$r2", 2, loongarch_reg_width); DRI ("$tp", 2, loongarch_reg_width); + DRI ("$r3", 3, loongarch_reg_width); DRI ("$sp", 3, loongarch_reg_width); + DRI ("$r4", 4, loongarch_reg_width); DRI ("$a0", 4, loongarch_reg_width); DRI ("$v0", 4, loongarch_reg_width); + DRI ("$r5", 5, loongarch_reg_width); DRI ("$a1", 5, loongarch_reg_width); DRI ("$v1", 5, loongarch_reg_width); + DRI ("$r6", 6, loongarch_reg_width); DRI ("$a2", 6, loongarch_reg_width); + DRI ("$r7", 7, loongarch_reg_width); DRI ("$a3", 7, loongarch_reg_width); + DRI ("$r8", 8, loongarch_reg_width); DRI ("$a4", 8, loongarch_reg_width); + DRI ("$r9", 9, loongarch_reg_width); DRI ("$a5", 9, loongarch_reg_width); + DRI ("$r10", 10, loongarch_reg_width); DRI ("$a6", 10, loongarch_reg_width); + DRI ("$r11", 11, loongarch_reg_width); DRI ("$a7", 11, loongarch_reg_width); + DRI ("$r12", 12, loongarch_reg_width); DRI ("$t0", 12, loongarch_reg_width); + DRI ("$r13", 13, loongarch_reg_width); DRI ("$t1", 13, loongarch_reg_width); + DRI ("$r14", 14, loongarch_reg_width); DRI ("$t2", 14, loongarch_reg_width); + DRI ("$r15", 15, loongarch_reg_width); DRI ("$t3", 15, loongarch_reg_width); + DRI ("$r16", 16, loongarch_reg_width); DRI ("$t4", 16, loongarch_reg_width); + DRI ("$r17", 17, loongarch_reg_width); DRI ("$t5", 17, loongarch_reg_width); + DRI ("$r18", 18, loongarch_reg_width); DRI ("$t6", 18, loongarch_reg_width); + DRI ("$r19", 19, loongarch_reg_width); DRI ("$t7", 19, loongarch_reg_width); + DRI ("$r20", 20, loongarch_reg_width); DRI ("$t8", 20, loongarch_reg_width); + DRI ("$r21", 21, loongarch_reg_width); DRI ("$x", 21, loongarch_reg_width); + DRI ("$r22", 22, loongarch_reg_width); DRI ("$fp", 22, loongarch_reg_width); + DRI ("$r23", 23, loongarch_reg_width); DRI ("$s0", 23, loongarch_reg_width); + DRI ("$r24", 24, loongarch_reg_width); DRI ("$s1", 24, loongarch_reg_width); + DRI ("$r25", 25, loongarch_reg_width); DRI ("$s2", 25, loongarch_reg_width); + DRI ("$r26", 26, loongarch_reg_width); DRI ("$s3", 26, loongarch_reg_width); + DRI ("$r27", 27, loongarch_reg_width); DRI ("$s4", 27, loongarch_reg_width); + DRI ("$r28", 28, loongarch_reg_width); DRI ("$s5", 28, loongarch_reg_width); + DRI ("$r29", 29, loongarch_reg_width); DRI ("$s6", 29, loongarch_reg_width); + DRI ("$r30", 30, loongarch_reg_width); DRI ("$s7", 30, loongarch_reg_width); + DRI ("$r31", 31, loongarch_reg_width); DRI ("$s8", 31, loongarch_reg_width); } else if (arg_count) { /* permit this case; just fall back to dwarf */ } @@ -7134,7 +7172,7 @@ sdt_uprobe_var_expanding_visitor::try_parse_arg_literal (target_symbol *e, vector<string> matches; string regexp; - if (elf_machine == EM_AARCH64 || elf_machine == EM_MIPS) { + if (elf_machine == EM_AARCH64 || elf_machine == EM_MIPS || elf_machine == EM_LOONGARCH) { regexp = "^([-]?[0-9][0-9]*)$"; } else { regexp = "^[i\\$#]([-]?[0-9][0-9]*)$"; diff --git a/testsuite/lib/compile_flags.exp b/testsuite/lib/compile_flags.exp index a84e7ca..06864df 100644 --- a/testsuite/lib/compile_flags.exp +++ b/testsuite/lib/compile_flags.exp @@ -59,7 +59,11 @@ proc arch_compile_init {} { } puts "Checking for $compat_arch_bits-bit support..." - set flags "additional_flags=-g compiler=gcc additional_flags=-m$compat_arch_bits" + set flags "additional_flags=-g compiler=gcc " +# GCC on loongarch64 doesn't recognize -m64 + if { ![regexp "^(loongarch64)$" $::tcl_platform(machine)] } { + set flags "$flags additional_flags=-m$compat_arch_bits" + } set exe "hello-m$compat_arch_bits" set result [target_compile $source $exe executable $flags] if { $result != "" } { @@ -109,6 +113,7 @@ proc arch_compile_flag_name { INDEX } { {^(ia64|aarch64|ppc64le|ppc64)$} { return "m64" } {^s390$} { return "m31" } {^mips64$} { return "64" } + {^loongarch64$} { return "lp64d" } default { return "m32" } } } @@ -135,7 +140,7 @@ proc arch_compile_flag_bits { INDEX } { # Notice that even though s390/s390x is 31 bits, we'll call it 32. if { [arch_compile_flags] == 1 } { switch -regexp $::tcl_platform(machine) { - {^(ia64|aarch64|ppc64le|ppc64|mips64|s390x)$} { return 64 } + {^(ia64|aarch64|ppc64le|ppc64|mips64|s390x|loongarch64)$} { return 64 } default { return 32 } } } diff --git a/testsuite/lib/systemtap.exp b/testsuite/lib/systemtap.exp index dcf5ee7..5463d5a 100644 --- a/testsuite/lib/systemtap.exp +++ b/testsuite/lib/systemtap.exp @@ -85,7 +85,7 @@ proc uretprobes_p {} { proc plt_probes_p {} { # .plt probes need uprobes and a supported arch (x86 and arm) return [expr [uprobes_p] \ - && [regexp "^(x86_64|i.86|arm.*|aarch64)$" $::tcl_platform(machine)] ] + && [regexp "^(x86_64|i.86|arm.*|aarch64|loongarch64)$" $::tcl_platform(machine)] ] } proc perf_probes_p {} { @@ -570,6 +570,7 @@ proc normalize_arch { arch } { if {$arch == "armv7l"} then {return "arm"} if {$arch == "armv7lh"} then {return "arm"} if {$arch == "aarch64"} then {return "arm64"} + if {$arch == "loongarch64"} then {return "loongarch64"} if {$arch == "ppc64le"} then {return "powerpc"} if {$arch == "mips64"} then {return "mips"} return $arch diff --git a/testsuite/systemtap.syscall/clone.c b/testsuite/systemtap.syscall/clone.c index f1335ce..942d104 100644 --- a/testsuite/systemtap.syscall/clone.c +++ b/testsuite/systemtap.syscall/clone.c @@ -61,7 +61,7 @@ __sys_clone2(int flags, void *ustack_base, size_t ustack_size, #endif #if defined(__powerpc__) || defined(__powerpc64__) \ || defined(__arm__) || defined(__aarch64__) \ - || defined(__i386__) + || defined(__i386__) || defined(__loongarch64) #define CLONE_BACKWARDS #endif diff --git a/translate.cxx b/translate.cxx index 0a3b58a..90c3f1f 100644 --- a/translate.cxx +++ b/translate.cxx @@ -8482,7 +8482,8 @@ translate_pass (systemtap_session& s) s.op->hdr->newline() << "#if (defined(__arm__) || defined(__i386__) " "|| defined(__x86_64__) || defined(__powerpc64__)) " - "|| defined (__s390x__) || defined(__aarch64__) || defined(__mips__)\n" + "|| defined (__s390x__) || defined(__aarch64__) || defined(__mips__) " + "|| defined(__loongarch64)\n" "#ifdef STP_NEED_UNWIND_DATA\n" "#ifndef STP_USE_DWARF_UNWINDER\n" "#define STP_USE_DWARF_UNWINDER\n" diff --git a/util.cxx b/util.cxx index f2eaf54..24d3215 100644 --- a/util.cxx +++ b/util.cxx @@ -1400,6 +1400,7 @@ normalize_machine(const string& machine) else if (machine == "s390x") return "s390"; else if (machine == "aarch64") return "arm64"; else if (machine == "riscv64") return "riscv"; + else if (machine == "loongarch64") return "loongarch64"; else if (machine.substr(0,3) == "ppc") return "powerpc"; else if (machine.substr(0,4) == "mips") return "mips"; else if (machine.substr(0,3) == "sh2") return "sh"; @@ -1421,6 +1422,7 @@ elf_class_from_normalized_machine (const string &machine) || machine == "powerpc" // see normalize_machine (). || machine == "x86_64" || machine == "ia64" + || machine == "loongarch64" || machine == "arm64") return ELFCLASS64; -- 2.33.0
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.
浙ICP备2022010568号-2