We want this here instead of nir_lower_system_values because for Vulkan we don't want this lowering to take place. --- src/mesa/drivers/dri/i965/brw_program.c | 6 ++++++ 1 file changed, 6 insertions(+)
diff --git a/src/mesa/drivers/dri/i965/brw_program.c b/src/mesa/drivers/dri/i965/brw_program.c index 5b168c25e3..84f29e9c7f 100644 --- a/src/mesa/drivers/dri/i965/brw_program.c +++ b/src/mesa/drivers/dri/i965/brw_program.c @@ -88,6 +88,12 @@ brw_create_nir(struct brw_context *brw, } nir_validate_shader(nir); + /* Lower TCS PatchVerticesIn from system value to uniform. This needs to + * happen before brw_preprocess_nir, since that will lower system values. + */ + if (stage == MESA_SHADER_TESS_CTRL && brw->screen->devinfo.gen >= 8) + brw_nir_lower_tcs_vertices_in_to_uniform(nir); + nir = brw_preprocess_nir(brw->screen->compiler, nir); if (stage == MESA_SHADER_FRAGMENT) { -- 2.11.0 _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev