correct number of threads