yum-mirror/glslang

git clone https://git.yummers.dev/yum-mirror/glslang

Saddamfix oob operand read on short coopMatPerElementNV arg list3b7ce572

main
865 B22 linesraw
1#version 450 core
2#extension GL_KHR_memory_scope_semantics : enable
3#extension GL_KHR_cooperative_matrix : enable
4#extension GL_EXT_shader_explicit_arithmetic_types : enable
5#extension GL_NV_cooperative_matrix2 : enable
6
7layout(local_size_x = 64, local_size_y = 1, local_size_z = 1) in;
8
9float16_t relu(const in uint32_t row, const in uint32_t col, const in float16_t x) { return max(x, float16_t(0)); }
10
11void main()
12{
13    coopmat<float16_t, gl_ScopeWorkgroup, 64, 32, gl_MatrixUseAccumulator> Acc;
14
15    // coopMatPerElementNV is declared with an empty prototype, so overload
16    // resolution accepts these malformed calls; each is missing at least one of
17    // the required (result matrix, input matrix, per-element function) arguments.
18    coopMatPerElementNV();
19    coopMatPerElementNV(relu);
20    coopMatPerElementNV(Acc);
21    coopMatPerElementNV(Acc, Acc);
22}