Fix register assignment for constant arrays
Constant arrays are allocated in the same 'register file' as the one
for per-program uniforms, to support dynamic indexing. While we had
a special case for that in OutputASM::registerType(), in registerIndex()
we were actually allocating them in the temporaries register file. This
led to assigning the same register index range twice, leading to
overwriting the per-program uniforms with constant array data in the
shader.
Bug: b/168060171
Change-Id: If42944d186ed1c1328a8d477edca4662aa1e8e54
Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/48248
Presubmit-Ready: Nicolas Capens <nicolascapens@google.com>
Kokoro-Result: kokoro <noreply+kokoro@google.com>
Tested-by:
Nicolas Capens <nicolascapens@google.com>
Reviewed-by:
Alexis Hétu <sugoi@google.com>
Showing
Please
register
or
sign in
to comment