Simplify threading implementation. Removed iothread array. Threads now
run detached (no more pthread_join), and will not exit until they see
that all requests have been dequeued.