rt_sigpending on x64
examine pending signals
sys_rt_sigpending(sigset_t *uset, size_t sigsetsize)
| number | 127 (0x7f) |
|---|---|
| abi | 64 |
| entry point | sys_rt_sigpending |
| since | Linux 3.3 or earlier (3.3 is the first release scanned for x64) |
| man page | rt_sigpending(2) |
| source | elixir.bootlin.com |
Registers
| register | value |
|---|---|
rax | 127, the syscall number |
rdi | sigset_t *uset |
rsi | size_t sigsetsize |
rax | the return value |
Then run syscall to enter the kernel.
The syscall instruction clobbers rcx (the return address lands in rcx) and r11 (the flags land in r11).
Since Linux 5.14 the kernel reads the syscall number from eax and ignores the upper 32 bits of rax. Older kernels fail with ENOSYS when those bits are not zero, and mov eax, N clears them, so it works on both.
Same syscall on other architectures
- x86 176
- arm64 136
- arm 176
- riscv64 136
- ia32 176
- x32 1073742346
- loongarch64 136
- ppc64 175
- ppc 175
- s390x 176
- mips64 5125
- mipsn32 6125
- mipso32 4196
- alpha 354
- arc 136
- blackfin 176, removed in 4.17
- cris 176, removed in 4.17
- csky 136
- frv 176, removed in 4.17
- hexagon 136
- ia64 1178, removed in 6.7
- m32r 176, removed in 4.17
- m68k 176
- metag 136, removed in 4.17
- microblaze 176
- mn10300 176, removed in 4.17
- nds32 136, removed in 5.18
- nios2 136
- openrisc 136
- parisc 176
- score 136, removed in 4.17
- sh 176
- sparc 104
- sparc64 104
- tilegx 136, removed in 4.17
- tilepro 136, removed in 4.17
- xtensa 228
Get this as JSON: https://api.syscall.sh/v2/syscalls/x64/rt_sigpending