Improved openmp usage