ref: dc593372bfc4224c6cf91d2031d0ad0aeadaddfe dir: /sys/src/libc/9sys/getpid.c/
#include <u.h> #include <libc.h> #include <tos.h> int getpid(void) { return _tos->pid; }