nir: fix sorting before assigning varying driver locations
We need to make sure we also properly sort varyings sharing a single slot otherwise we can end up assigning earlier components to the next slot if we have already processed later components. Closes: mesa/mesa#6392 Fixes: 1e93b0ca ("mesa/st: add support for NIR as possible driver IR") Reviewed-by:Emma Anholt <emma@anholt.net> Part-of: <mesa/mesa!16208>