improved templates
moved KernelRunningSettings argument into first place, added cpu unwrapping of arguments