threads to template for csolve