OSDN Git Service

Don't flag temporary registers as used samplers.
authorNicolas Capens <capn@google.com>
Fri, 4 May 2018 19:49:53 +0000 (15:49 -0400)
committerNicolas Capens <nicolascapens@google.com>
Fri, 4 May 2018 20:05:35 +0000 (20:05 +0000)
commit336cdd9031807bca6c1730a6842315a3509be960
tree26662cc5ae7a8a471dc587f6c3461d685f539e3a
parente76163e3cae02cc63d586fbf15c918c717ff54e2
Don't flag temporary registers as used samplers.

This fixes a undefined shift if the temporary register has an index
higher than 32 (also, we only have 16 samplers currently). For GLSL
we declare all actual sampler units during ASM output, so we don't
have to rely on analyzing the instructions afterwards (that is only
still relevant for Direct3D 8/9 shaders).

Change-Id: I11a58964d53fcc2c29e0ad923d9a4a4161a545f4
Reviewed-on: https://swiftshader-review.googlesource.com/18748
Tested-by: Nicolas Capens <nicolascapens@google.com>
Reviewed-by: Alexis Hétu <sugoi@google.com>
src/Shader/Shader.cpp