zink: always run optimize_nir after lower_64bit_vars
authorMike Blumenkrantz <michael.blumenkrantz@gmail.com>
Wed, 21 Sep 2022 16:19:24 +0000 (12:19 -0400)
committerMarge Bot <emma+marge@anholt.net>
Tue, 27 Sep 2022 18:38:25 +0000 (18:38 +0000)
it's otherwise possible (and likely) that optimizations won't
happen since there's no shader key data active

Fixes: 5b2f850425e ("zink: rewrite 64bit shader i/o as 32bit")

SoroushIMG <soroush.kashani@imgtec.com>

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18728>

src/gallium/drivers/zink/zink_compiler.c

index f808f96..1032e74 100644 (file)
@@ -1874,6 +1874,7 @@ lower_64bit_vars(nir_shader *shader)
    if (progress) {
       nir_lower_alu_to_scalar(shader, filter_64_bit_instr, NULL);
       nir_lower_phis_to_scalar(shader, false);
+      optimize_nir(shader, NULL);
    }
    return progress;
 }