Improvements to ntask impl.