glsl: convert lower distance pass to nir
The nir pass is a significant simplification over the old GLSL IR pass.
Note this MR exposes a bug and currently some virgl tests that are working by luck start to fail. see #10031 (closed) hopefully that bug can be fixed quickly before we merge this.