>>722896SIGALRM is one of the signals, which are a simple form of inter process communication implemented by the kernel. alarm() is a syscall that schedules a SIGALRM to be sent to the process after some time. There's also pause(), which waits for signals, and that's how you make the process wait until you get that SIGALRM.
Anyway, signals are unique, thus alarm() and sleep() used to interfere with each other. sleep() implemented using nanosleep doesn't have this problem.