Show HN: I've updated my Linux System Call website and API (syscall.sh)
I first released those in back in 2020 and now I finally added more architectures, Kernel selector, syscall descriptions and a few other niceties. It should work a bit better on mobile devices too but I am no CSS expert.
The API is at https://api.syscall.sh
26 comments
[ 0.23 ms ] story [ 6.4 ms ] threadDoes it still make sense to term or classify them as two distinct syscalls?
Doesn't really matter if it has the same name or similar (or identical) function. This website seeks to describe the syscall ABI and that means that each number should get it's own entry.
And there is no identical syscalls in the list, they all have slightly different behavior.
It would be nice to make a banner or warning for deprecated or surpassed syscalls. For example (as mentioned in other comments) you should probably use pipe2 instead of pipe and similar other examples.
[1] https://lore.kernel.org/all/20210518191303.4135296-5-hpa@zyt...
Or is it I am confusing it with the C standard library/POSIX and assuming that it should be the same everywhere?
Then the frontend is refreshed from the API weekly via a cronjob with some simple Go templating
The data comes directly from the official Kernel source code so it is as official as it gets, I don't change anything just format it in a way my website and API understands
echo '#include <sys/syscall.h>' | gcc -E -dM -xc - | grep -i "read"
To get the real values on your PC to make sure.
I had LLMs give wrong numbers or constant definitions several times but getting it to generate a command like this and seeing it for myself works every time.
Also chromium docs has a table:
https://www.chromium.org/chromium-os/developer-library/refer...
It would be very useful to just make this website directly link to the syscall number.
What I think would make sense is a change to the C API where the error code is an out parameter and not that ugly thread local errno. But I guess that's not big enough of an issue for people/languages that use libc as system call interface.