OSDN Git Service

glsl/lower_vector_derefs: Don't use a temporary for TCS outputs
authorJason Ekstrand <jason.ekstrand@intel.com>
Tue, 12 Mar 2019 01:43:15 +0000 (20:43 -0500)
committerJason Ekstrand <jason@jlekstrand.net>
Wed, 13 Mar 2019 02:10:31 +0000 (02:10 +0000)
commitbd17bdc56b34a08c421172df27fe07294c7a7024
treef9ae2185d11d4bd4582462bfccae0f27f3ebe008
parent20c4578c5539de909e94a6acc3ad680ab2ddeca6
glsl/lower_vector_derefs: Don't use a temporary for TCS outputs

Tessellation control shader outputs act as if they have memory backing
them and you can have multiple writes to different components of the
same vector in-flight at the same time.  When this happens, the load vec
store pattern that gets used by ir_triop_vector_insert doesn't yield the
correct results.  Instead, just emit a sequence of conditional
assignments.

Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Cc: mesa-stable@lists.freedesktop.org
src/compiler/glsl/lower_vector_derefs.cpp