Multiple passes just like threading on a manual lathe.
The spindle needs at least an index pulse trigger that is fed into the controller. This way the controller knows the spindle position once per rev, which is enough to get decent results. A multi-count encoder with index can also be used depending on the controller.