nir/lower_wpos_ytransform: Support system value intrinsics
authorJason Ekstrand <jason.ekstrand@intel.com>
Sat, 2 Sep 2017 05:10:06 +0000 (22:10 -0700)
committerJason Ekstrand <jason.ekstrand@intel.com>
Wed, 25 Oct 2017 23:14:09 +0000 (16:14 -0700)
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
src/compiler/nir/nir_lower_wpos_ytransform.c

index e2a3039..62166e7 100644 (file)
@@ -314,6 +314,10 @@ lower_wpos_ytransform_block(lower_wpos_ytransform_state *state, nir_block *block
                assert(dvar->deref.child == NULL);
                lower_load_sample_pos(state, intr);
             }
+         } else if (intr->intrinsic == nir_intrinsic_load_frag_coord) {
+            lower_fragcoord(state, intr);
+         } else if (intr->intrinsic == nir_intrinsic_load_sample_pos) {
+            lower_load_sample_pos(state, intr);
          } else if (intr->intrinsic == nir_intrinsic_interp_var_at_offset) {
             lower_interp_var_at_offset(state, intr);
          }