In a matrix constructor that takes a number of components, as many
components as necessary must be taken, with the rest discarded, as GLSL
allows more components than necessary to be specified. For example, the
following:
mat4 m4 = mat4(v4, v4.yzwx, v4.zwx, v4.zwxy, v4.wxyz);
is equivalent to:
mat4 m4 = mat4(v4, v4.yzwx, v4.zwx, v4.zwxy, v4.w);
glslang takes the components from the constructor and builds the single
components of the matrix in a 2D array before constructing the matrix
itself. It however did not check for extra parameters and was thus
writing OOB to said 2D array. This is fixed in this change
Signed-off-by:
Shahbaz Youssefi <shabbyx@gmail.com>
| Name |
Last commit
|
Last update |
|---|---|---|
| .. | ||
| CInterface | Loading commit data... | |
| CMakeLists.txt | Loading commit data... | |
| GLSL.ext.AMD.h | Loading commit data... | |
| GLSL.ext.EXT.h | Loading commit data... | |
| GLSL.ext.KHR.h | Loading commit data... | |
| GLSL.ext.NV.h | Loading commit data... | |
| GLSL.std.450.h | Loading commit data... | |
| GlslangToSpv.cpp | Loading commit data... | |
| GlslangToSpv.h | Loading commit data... | |
| InReadableOrder.cpp | Loading commit data... | |
| Logger.cpp | Loading commit data... | |
| Logger.h | Loading commit data... | |
| NonSemanticDebugPrintf.h | Loading commit data... | |
| SPVRemapper.cpp | Loading commit data... | |
| SPVRemapper.h | Loading commit data... | |
| SpvBuilder.cpp | Loading commit data... | |
| SpvBuilder.h | Loading commit data... | |
| SpvPostProcess.cpp | Loading commit data... | |
| SpvTools.cpp | Loading commit data... | |
| SpvTools.h | Loading commit data... | |
| bitutils.h | Loading commit data... | |
| disassemble.cpp | Loading commit data... | |
| disassemble.h | Loading commit data... | |
| doc.cpp | Loading commit data... | |
| doc.h | Loading commit data... | |
| hex_float.h | Loading commit data... | |
| spirv.hpp | Loading commit data... | |
| spvIR.h | Loading commit data... |