nir/spirv: fix build_mat_subdet stack smasher
authorMark Janes <mark.a.janes@intel.com>
Wed, 10 Feb 2016 21:41:27 +0000 (13:41 -0800)
committerMark Janes <mark.a.janes@intel.com>
Wed, 10 Feb 2016 22:43:03 +0000 (14:43 -0800)
commit8179834030c85722824a2a4863e4d5c2d75f07eb
treee2c4f9b80511a14258486ba45c982f2afebad9ea
parent51c01e292c9a71958bb495d30397e82ba1a3d5d8
nir/spirv: fix build_mat_subdet stack smasher

The sub-determinate implementation pattern fixed by
6a7e2904e0a2a6f8efbf739a1b3cad7e1e4ab42d has a second instance in the
same file.

With the previous algorithm, when row and j are both 3, the index
overruns the array.  This only impacts the stack on 32 bit builds.

Reviewed-by: Jason Ekstrand <jason.ekstrand@intel.com>
src/compiler/nir/spirv/vtn_glsl450.c