From d1c65939e2dd2250286fd3f77c1e1d5d7707a31b Mon Sep 17 00:00:00 2001 From: Connor Abbott Date: Mon, 13 May 2019 16:28:58 +0200 Subject: [PATCH] radeonsi/nir: Delete unreachable code MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit We always get gl_FragCoord as a system value, not a varying, so this is never hit. We already set PIXEL_CENTER_INTEGER elsewhere. Reviewed-by: Bas Nieuwenhuizen Reviewed-by: Marek Olšák --- src/gallium/drivers/radeonsi/si_shader_nir.c | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/src/gallium/drivers/radeonsi/si_shader_nir.c b/src/gallium/drivers/radeonsi/si_shader_nir.c index a852283aff0..365c137f8fc 100644 --- a/src/gallium/drivers/radeonsi/si_shader_nir.c +++ b/src/gallium/drivers/radeonsi/si_shader_nir.c @@ -444,17 +444,6 @@ void si_nir_scan_shader(const struct nir_shader *nir, continue; } - /* Fragment shader position is a system value. */ - if (nir->info.stage == MESA_SHADER_FRAGMENT && - variable->data.location == VARYING_SLOT_POS) { - if (nir->info.fs.pixel_center_integer) - info->properties[TGSI_PROPERTY_FS_COORD_PIXEL_CENTER] = - TGSI_FS_COORD_PIXEL_CENTER_INTEGER; - - num_inputs++; - continue; - } - for (unsigned j = 0; j < attrib_count; j++, i++) { if (processed_inputs & ((uint64_t)1 << i)) -- 2.30.2