Copied all C extension code from concurrent-ruby project.