Maximum threads based on available processor cores