Artificial intelligent assistant

Is there a better method than ptrace for intercepting ("catching") Linux syscalls coming from a forked process? I would like to catch all syscalls coming from a forked process, modify them, send them to the kernel, and then pass them back to the forked process. Is this possible, and if so, how might I go about this? I've done some research, and found ptrace, but it seems a bit heavy weight because it does so many things (modifying registers, etc...). Correct me if I am incorrect, however.

If you can wait for version 5.11 of the kernel, it will have a new system call interception mechanism designed for fast (or less slow) emulation of system calls. The initial use case is for Wine but it is usable for other purposes, as long as a signal handler can work (it relies on `SIGSYS`).

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy 60bc6ebeda482d65c7ebf1e9062534e5