From: Kenneth Graunke Date: Thu, 10 Dec 2015 05:39:27 +0000 (-0800) Subject: i965: Handle TCS inputs and TES outputs. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=31140d097a7939e0f917aa76bd37b5c682898e63;p=mesa.git i965: Handle TCS inputs and TES outputs. TES outputs work exactly like VS outputs, so we can simply add a case statement for those. TCS inputs are very similar to geometry shaders - they're arrays of per-vertex data. We use the same method I used for the scalar GS backend. Signed-off-by: Kenneth Graunke Reviewed-by: Jordan Justen --- diff --git a/src/mesa/drivers/dri/i965/brw_nir.c b/src/mesa/drivers/dri/i965/brw_nir.c index 88457e4f9cb..2cce4aa946b 100644 --- a/src/mesa/drivers/dri/i965/brw_nir.c +++ b/src/mesa/drivers/dri/i965/brw_nir.c @@ -178,8 +178,9 @@ brw_nir_lower_inputs(nir_shader *nir, } } break; + case MESA_SHADER_TESS_CTRL: case MESA_SHADER_GEOMETRY: { - if (!is_scalar) { + if (!is_scalar && nir->stage == MESA_SHADER_GEOMETRY) { foreach_list_typed(nir_variable, var, node, &nir->inputs) { var->data.driver_location = var->data.location; } @@ -243,6 +244,7 @@ brw_nir_lower_outputs(nir_shader *nir, bool is_scalar) { switch (nir->stage) { case MESA_SHADER_VERTEX: + case MESA_SHADER_TESS_EVAL: case MESA_SHADER_GEOMETRY: if (is_scalar) { nir_assign_var_locations(&nir->outputs, &nir->num_outputs,