More flexible specification of threading.