run with four threads correctly