From 0d5f89cdc376445c46f4aa1ae126286cbaebde2b Mon Sep 17 00:00:00 2001 From: Jason Ekstrand Date: Wed, 3 May 2017 17:40:54 -0700 Subject: i965/vec4: Use NIR remapping for VS attributes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The NIR pass already handles remapping system values to attributes for us so we delete the system value code as part of the conversion. We also change nir_lower_vs_inputs to take an explicit inputs_read bitmask and pass in the inputs_read from prog_data instead from pulling it out of NIR. This is because the version in prog_data may get EDGEFLAG added to it on some old platforms. Reviewed-by: Alejandro PiƱeiro Reviewed-by: Kenneth Graunke --- src/intel/compiler/brw_nir.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'src/intel/compiler/brw_nir.c') diff --git a/src/intel/compiler/brw_nir.c b/src/intel/compiler/brw_nir.c index a9d909e8db0..2b41e0470c6 100644 --- a/src/intel/compiler/brw_nir.c +++ b/src/intel/compiler/brw_nir.c @@ -230,7 +230,6 @@ remap_patch_urb_offsets(nir_block *block, nir_builder *b, void brw_nir_lower_vs_inputs(nir_shader *nir, - bool is_scalar, bool use_legacy_snorm_formula, const uint8_t *vs_attrib_wa_flags) { @@ -253,11 +252,7 @@ brw_nir_lower_vs_inputs(nir_shader *nir, brw_nir_apply_attribute_workarounds(nir, use_legacy_snorm_formula, vs_attrib_wa_flags); - /* The last step is to remap VERT_ATTRIB_* to actual registers and we only - * do that for scalar shaders at the moment. - */ - if (!is_scalar) - return; + /* The last step is to remap VERT_ATTRIB_* to actual registers */ /* Whether or not we have any system generated values. gl_DrawID is not * included here as it lives in its own vec4. -- cgit v1.2.3