If C++ is possible for you, definitely look at Boost.Thread. Boost.Thread with ASIO is some pretty powerful stuff. 

For C, OpenMP is what you want.