No need to have a return statement after a call to status_critical()
Use pipe2() instead of socketpair()

Socketpair isn't required as there's only communication between the
main thread and each I/O thread.
each cpu arch except X86/X86_64 pass the wrong params to makecontext functoin