STRUCT SYSCALL(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… NAME πŸ’…

struct syscall β€” okay so this is the struct that holds everything perf's trace tooling needs to know about one single syscall, and the manpage straight-up left the description blank so we're gonna vibe with the fields themselves ✨


πŸ¦‹ SYNOPSIS πŸ¦‹

struct syscall {
    int e_machine;
    int id;
    struct tep_event    *tp_format;
    int nr_args;
    int args_size;
    struct {
      struct bpf_program *sys_enter, *sys_exit;
    } bpf_prog;
    bool is_exit;
    bool is_open;
    bool nonexistent;
    bool use_btf;
    struct tep_format_field *args;
    const char          *name;
    const struct syscall_fmt  *fmt;
    struct syscall_arg_fmt *arg_fmt;
 };

Like, look at her. The anonymous nested struct for bpf_prog holding *sys_enter and *sys_exit? Main character energy fr fr πŸ”₯


πŸŽ€ Members πŸŽ€

Heads up bestie β€” the page only spells out some of these fields, so I'm not gonna make up lore for the rest. Here's exactly what we got:

  • e_machine β€” the ELF machine that's associated with the entry. iykyk 🧚
  • id β€” the id value that comes from the tracepoint; it's the system call number.
  • args_size β€” the sum of the sizes of the syscall arguments. Anything after that is augmented stuff, like the pathname for openat, etc. πŸ’–
  • is_exit β€” is this "exit" or "exit_group"? πŸ‘€
  • is_open β€” is this "open" or "openat"? It exists so you can associate the fd returned in sys_exit with the pathname in sys_enter. iconic.
  • nonexistent β€” name lookup failed. It's literally just a hole in the syscall table, syscall id not allocated. πŸ’€
Quick vibe check: tp_format, nr_args, bpf_prog, use_btf, args, name, fmt and arg_fmt are all chillin' in the synopsis, but the manpage doesn't document them here β€” so no invented facts from me, periodt. πŸ™ˆ

🌈 SEE ALSO 🌈


That's the whole page, bestie β€” slay 🫢 This lil beauty comes from ./tools/perf and is dated October 2026, so go forth and trace those syscalls πŸ’œβœ¨

πŸ“¦ where this page comes from