From: Timothy Arceri Date: Fri, 24 Jun 2016 02:10:12 +0000 (+1000) Subject: i965/vec4: add support for packing tcs outputs X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=d07cfb31c4930ddb7700667783f6dfe5754b5435;p=mesa.git i965/vec4: add support for packing tcs outputs Reviewed-by: Kenneth Graunke Reviewed-by: Edward O'Callaghan --- diff --git a/src/mesa/drivers/dri/i965/brw_vec4_tcs.cpp b/src/mesa/drivers/dri/i965/brw_vec4_tcs.cpp index 8bd150ad1b4..4bc3be70188 100644 --- a/src/mesa/drivers/dri/i965/brw_vec4_tcs.cpp +++ b/src/mesa/drivers/dri/i965/brw_vec4_tcs.cpp @@ -406,6 +406,13 @@ vec4_tcs_visitor::nir_emit_intrinsic(nir_intrinsic_instr *instr) } } + unsigned first_component = nir_intrinsic_component(instr); + if (first_component) { + assert(swiz == BRW_SWIZZLE_XYZW); + swiz = BRW_SWZ_COMP_OUTPUT(first_component); + mask = mask << first_component; + } + emit_urb_write(swizzle(value, swiz), mask, imm_offset, indirect_offset); break;