Factor out alignment code into sp_align