GLSL/SPV: Fix #1196: Require resources to have layout(binding=X).
This commit is contained in:
parent
2d9973de0e
commit
9c9c4e90df
20 changed files with 114 additions and 64 deletions
|
|
@ -40,7 +40,6 @@ ERROR: 0:119: 'r8ui' : does not apply to signed integer images
|
|||
ERROR: 0:128: 'atomic_uint' : samplers and atomic_uints cannot be output parameters
|
||||
ERROR: 0:130: 'return' : type does not match, or is not convertible to, the function's return type
|
||||
ERROR: 0:136: 'atomic_uint' : atomic_uints can only be used in uniform variables or function parameters: non_uniform_counter
|
||||
ERROR: 0:136: 'atomic_uint' : layout(binding=X) is required
|
||||
ERROR: 0:141: 'atomic_uint' : atomic counters can only be highp
|
||||
ERROR: 0:141: 'binding' : atomic_uint binding is too large; see gl_MaxAtomicCounterBindings
|
||||
ERROR: 0:143: 'binding' : atomic_uint binding is too large; see gl_MaxAtomicCounterBindings
|
||||
|
|
@ -84,7 +83,7 @@ WARNING: 0:238: '#define' : names containing consecutive underscores are reserve
|
|||
ERROR: 0:244: 'gl_DeviceIndex' : required extension not requested: GL_EXT_device_group
|
||||
ERROR: 0:245: 'gl_ViewIndex' : undeclared identifier
|
||||
ERROR: 0:255: 'gl_ViewIndex' : undeclared identifier
|
||||
ERROR: 83 compilation errors. No code generated.
|
||||
ERROR: 82 compilation errors. No code generated.
|
||||
|
||||
|
||||
Shader version: 310
|
||||
|
|
|
|||
|
|
@ -2,7 +2,6 @@ atomic_uint.frag
|
|||
ERROR: 0:10: 'atomic_uint' : samplers and atomic_uints cannot be output parameters
|
||||
ERROR: 0:12: 'return' : type does not match, or is not convertible to, the function's return type
|
||||
ERROR: 0:18: 'atomic_uint' : atomic_uints can only be used in uniform variables or function parameters: non_uniform_counter
|
||||
ERROR: 0:18: 'atomic_uint' : layout(binding=X) is required
|
||||
ERROR: 0:23: 'binding' : atomic_uint binding is too large; see gl_MaxAtomicCounterBindings
|
||||
ERROR: 0:28: '+' : wrong operand types: no operation '+' exists that takes a left-hand operand of type 'layout( binding=0 offset=0) uniform atomic_uint' and a right operand of type 'layout( binding=0 offset=0) uniform atomic_uint' (or there is no acceptable conversion)
|
||||
ERROR: 0:29: '-' : wrong operand type no operation '-' exists that takes an operand of type layout( binding=0 offset=0) uniform atomic_uint (or there is no acceptable conversion)
|
||||
|
|
@ -10,14 +9,10 @@ ERROR: 0:31: '[]' : scalar integer expression required
|
|||
ERROR: 0:34: 'assign' : l-value required "counter" (can't modify a uniform)
|
||||
ERROR: 0:34: 'assign' : cannot convert from ' const int' to 'layout( binding=0 offset=0) uniform atomic_uint'
|
||||
ERROR: 0:37: 'atomic_uint' : atomic_uints can only be used in uniform variables or function parameters: acin
|
||||
ERROR: 0:37: 'atomic_uint' : layout(binding=X) is required
|
||||
ERROR: 0:38: 'atomic_uint' : atomic_uints can only be used in uniform variables or function parameters: acg
|
||||
ERROR: 0:38: 'atomic_uint' : layout(binding=X) is required
|
||||
ERROR: 0:40: 'atomic_uint' : layout(binding=X) is required
|
||||
ERROR: 0:46: 'atomic_uint' : layout(binding=X) is required
|
||||
ERROR: 0:47: 'offset' : atomic counters sharing the same offset: 12
|
||||
ERROR: 0:48: 'binding' : atomic_uint binding is too large; see gl_MaxAtomicCounterBindings
|
||||
ERROR: 18 compilation errors. No code generated.
|
||||
ERROR: 13 compilation errors. No code generated.
|
||||
|
||||
|
||||
Shader version: 420
|
||||
|
|
|
|||
|
|
@ -1,13 +1,15 @@
|
|||
glspv.frag
|
||||
ERROR: 0:4: '#error' : GL_SPIRV is set ( correct , not an error )
|
||||
ERROR: 0:6: '#error' : GL_SPIR is 100
|
||||
ERROR: 0:14: 'f' : non-opaque uniform variables need a layout(location=L)
|
||||
ERROR: 0:21: 'noise1' : no matching overloaded function found
|
||||
ERROR: 0:22: 'noise2' : no matching overloaded function found
|
||||
ERROR: 0:23: 'noise3' : no matching overloaded function found
|
||||
ERROR: 0:24: 'noise4' : no matching overloaded function found
|
||||
ERROR: 0:27: 'input_attachment_index' : only allowed when using GLSL for Vulkan
|
||||
ERROR: 0:27: '' : syntax error, unexpected IDENTIFIER, expecting LEFT_BRACE or COMMA or SEMICOLON
|
||||
ERROR: 8 compilation errors. No code generated.
|
||||
ERROR: 0:27: 'atomic_uint' : layout(binding=X) is required
|
||||
ERROR: 0:28: 'input_attachment_index' : only allowed when using GLSL for Vulkan
|
||||
ERROR: 0:28: '' : syntax error, unexpected IDENTIFIER, expecting LEFT_BRACE or COMMA or SEMICOLON
|
||||
ERROR: 10 compilation errors. No code generated.
|
||||
|
||||
|
||||
SPIR-V is not generated for failed compile or link
|
||||
|
|
|
|||
|
|
@ -20,12 +20,12 @@ gl_FragCoord origin is upper left
|
|||
0:7 Sequence
|
||||
0:7 Branch: Return with expression
|
||||
0:7 texture ( global highp 4-component vector of float)
|
||||
0:7 's2D' ( uniform highp sampler2D)
|
||||
0:7 's2D' (layout( binding=1) uniform highp sampler2D)
|
||||
0:7 Constant:
|
||||
0:7 0.500000
|
||||
0:7 0.500000
|
||||
0:? Linker Objects
|
||||
0:? 's2D' ( uniform highp sampler2D)
|
||||
0:? 's2D' (layout( binding=1) uniform highp sampler2D)
|
||||
|
||||
|
||||
Linked fragment stage:
|
||||
|
|
@ -45,12 +45,12 @@ gl_FragCoord origin is upper left
|
|||
0:7 Sequence
|
||||
0:7 Branch: Return with expression
|
||||
0:7 texture ( global highp 4-component vector of float)
|
||||
0:7 's2D' ( uniform highp sampler2D)
|
||||
0:7 's2D' (layout( binding=1) uniform highp sampler2D)
|
||||
0:7 Constant:
|
||||
0:7 0.500000
|
||||
0:7 0.500000
|
||||
0:? Linker Objects
|
||||
0:? 'color' ( out highp 4-component vector of float)
|
||||
0:? 's2D' ( uniform highp sampler2D)
|
||||
0:? 's2D' (layout( binding=1) uniform highp sampler2D)
|
||||
|
||||
SPIR-V is not generated for failed compile or link
|
||||
|
|
|
|||
|
|
@ -19,7 +19,6 @@ ERROR: 0:85: 'binding' : atomic_uint binding is too large; see gl_MaxAtomicCount
|
|||
ERROR: 0:87: 'binding' : atomic_uint binding is too large; see gl_MaxAtomicCounterBindings
|
||||
ERROR: 0:89: 'binding' : atomic_uint binding is too large
|
||||
ERROR: 0:91: 'bar' : redefinition
|
||||
ERROR: 0:92: 'atomic_uint' : layout(binding=X) is required
|
||||
ERROR: 0:94: 'a2' : redefinition
|
||||
ERROR: 0:95: 'binding' : atomic_uint binding is too large; see gl_MaxAtomicCounterBindings
|
||||
ERROR: 0:96: 'binding' : atomic_uint binding is too large; see gl_MaxAtomicCounterBindings
|
||||
|
|
@ -32,7 +31,7 @@ ERROR: 0:134: '' : function does not return a value: funcA
|
|||
ERROR: 0:136: '' : function does not return a value: funcB
|
||||
ERROR: 0:153: '' : function does not return a value: func3
|
||||
ERROR: 0:170: 'coherent' : argument cannot drop memory qualifier when passed to formal parameter
|
||||
ERROR: 33 compilation errors. No code generated.
|
||||
ERROR: 32 compilation errors. No code generated.
|
||||
|
||||
|
||||
Shader version: 430
|
||||
|
|
|
|||
|
|
@ -11,6 +11,7 @@ spv.debugInfo.frag
|
|||
1: String "spv.debugInfo.frag"
|
||||
Source GLSL 450 1 "// OpModuleProcessed no-storage-format
|
||||
// OpModuleProcessed resource-set-binding 3
|
||||
// OpModuleProcessed auto-map-bindings
|
||||
// OpModuleProcessed auto-map-locations
|
||||
// OpModuleProcessed client opengl100
|
||||
// OpModuleProcessed target-env opengl
|
||||
|
|
@ -95,7 +96,9 @@ void main()
|
|||
MemberDecorate 54(ubuf) 0 Offset 0
|
||||
Decorate 54(ubuf) Block
|
||||
Decorate 56 DescriptorSet 3
|
||||
Decorate 56 Binding 0
|
||||
Decorate 69(s2d) DescriptorSet 3
|
||||
Decorate 69(s2d) Binding 1
|
||||
3: TypeVoid
|
||||
4: TypeFunction 3
|
||||
7: TypeInt 32 1
|
||||
|
|
|
|||
|
|
@ -41,19 +41,25 @@ spv.glsl.register.noautoassign.frag
|
|||
Name 137 "FragColor"
|
||||
Name 141 "g_tTex_unused3"
|
||||
Decorate 17(g_tTex1) DescriptorSet 0
|
||||
Decorate 17(g_tTex1) Binding 11
|
||||
Decorate 17(g_tTex1) Binding 17
|
||||
Decorate 21(g_sSamp1) DescriptorSet 0
|
||||
Decorate 21(g_sSamp1) Binding 5
|
||||
Decorate 27(g_tTex2) DescriptorSet 0
|
||||
Decorate 27(g_tTex2) Binding 18
|
||||
Decorate 29(g_sSamp2) DescriptorSet 0
|
||||
Decorate 29(g_sSamp2) Binding 6
|
||||
Decorate 39(g_tTex3) DescriptorSet 0
|
||||
Decorate 39(g_tTex3) Binding 13
|
||||
Decorate 39(g_tTex3) Binding 19
|
||||
Decorate 46(g_sSamp3) DescriptorSet 0
|
||||
Decorate 46(g_sSamp3) Binding 7
|
||||
Decorate 64(g_tTex4) DescriptorSet 0
|
||||
Decorate 64(g_tTex4) Binding 20
|
||||
Decorate 69(g_sSamp4) DescriptorSet 0
|
||||
Decorate 69(g_sSamp4) Binding 8
|
||||
Decorate 84(g_tTex5) DescriptorSet 0
|
||||
Decorate 84(g_tTex5) Binding 21
|
||||
Decorate 86(g_sSamp5) DescriptorSet 0
|
||||
Decorate 86(g_sSamp5) Binding 9
|
||||
MemberDecorate 93(MyStruct_t) 0 Offset 0
|
||||
MemberDecorate 93(MyStruct_t) 1 Offset 4
|
||||
MemberDecorate 93(MyStruct_t) 2 Offset 16
|
||||
|
|
@ -65,13 +71,16 @@ spv.glsl.register.noautoassign.frag
|
|||
Decorate 97 DescriptorSet 0
|
||||
Decorate 97 Binding 19
|
||||
Decorate 119(g_tTex_unused1) DescriptorSet 0
|
||||
Decorate 119(g_tTex_unused1) Binding 10
|
||||
Decorate 119(g_tTex_unused1) Binding 22
|
||||
Decorate 121(g_sSamp_unused1) DescriptorSet 0
|
||||
Decorate 121(g_sSamp_unused1) Binding 10
|
||||
Decorate 126(g_tTex_unused2) DescriptorSet 0
|
||||
Decorate 126(g_tTex_unused2) Binding 12
|
||||
Decorate 126(g_tTex_unused2) Binding 23
|
||||
Decorate 128(g_sSamp_unused2) DescriptorSet 0
|
||||
Decorate 128(g_sSamp_unused2) Binding 11
|
||||
Decorate 137(FragColor) Location 0
|
||||
Decorate 141(g_tTex_unused3) DescriptorSet 0
|
||||
Decorate 141(g_tTex_unused3) Binding 24
|
||||
2: TypeVoid
|
||||
3: TypeFunction 2
|
||||
6: TypeFloat 32
|
||||
|
|
|
|||
|
|
@ -1,4 +1,11 @@
|
|||
vulkan.frag
|
||||
ERROR: 0:3: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:4: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:5: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:6: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:8: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:9: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:10: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:14: 'sampler2D' : sampler-constructor requires two arguments
|
||||
ERROR: 0:15: 'sampler2D' : sampler-constructor first argument must be a scalar textureXXX type
|
||||
ERROR: 0:16: 'sampler2D' : sampler-constructor first argument must be a scalar textureXXX type
|
||||
|
|
@ -14,13 +21,19 @@ ERROR: 0:28: 'sampler2D' : sampler/image types can only be used in uniform varia
|
|||
ERROR: 0:29: 'sampler3D' : sampler-constructor cannot make an array of samplers
|
||||
ERROR: 0:29: 'sampler3D' : sampler/image types can only be used in uniform variables or function parameters: s3d
|
||||
ERROR: 0:29: '=' : cannot convert from ' const float' to ' global 4-element array of highp sampler3D'
|
||||
ERROR: 0:31: 'location' : SPIR-V requires location for user input/output
|
||||
ERROR: 0:39: 'push_constant' : can only be used with a uniform
|
||||
ERROR: 0:43: 'non-opaque uniforms outside a block' : not allowed when using GLSL for Vulkan
|
||||
ERROR: 0:43: 'push_constant' : can only be used with a block
|
||||
ERROR: 0:45: 'push_constant' : cannot declare a default, can only be used on a block
|
||||
ERROR: 0:51: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:52: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:52: 'input_attachment_index' : can only be used with a subpass
|
||||
ERROR: 0:53: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:53: 'input_attachment_index' : can only be used with a subpass
|
||||
ERROR: 0:54: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:54: 'subpass' : requires an input_attachment_index layout qualifier
|
||||
ERROR: 0:55: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:60: 'subpassLoadMS' : no matching overloaded function found
|
||||
ERROR: 0:61: 'subpassLoad' : no matching overloaded function found
|
||||
ERROR: 0:63: 'subpassLoadMS' : no matching overloaded function found
|
||||
|
|
@ -43,7 +56,7 @@ ERROR: 0:101: 'noise1' : no matching overloaded function found
|
|||
ERROR: 0:102: 'noise2' : no matching overloaded function found
|
||||
ERROR: 0:103: 'noise3' : no matching overloaded function found
|
||||
ERROR: 0:104: 'noise4' : no matching overloaded function found
|
||||
ERROR: 42 compilation errors. No code generated.
|
||||
ERROR: 55 compilation errors. No code generated.
|
||||
|
||||
|
||||
ERROR: Linking fragment stage: Only one push_constant block is allowed per stage
|
||||
|
|
|
|||
|
|
@ -1,12 +1,20 @@
|
|||
vulkan.vert
|
||||
ERROR: 0:3: 'subpass input' : not supported in this stage: vertex
|
||||
ERROR: 0:3: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:4: 'subpass input' : not supported in this stage: vertex
|
||||
ERROR: 0:4: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:5: 'subpass input' : not supported in this stage: vertex
|
||||
ERROR: 0:5: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:6: 'subpass input' : not supported in this stage: vertex
|
||||
ERROR: 0:6: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:7: 'subpass input' : not supported in this stage: vertex
|
||||
ERROR: 0:7: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:8: 'subpass input' : not supported in this stage: vertex
|
||||
ERROR: 0:8: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:10: 'location' : SPIR-V requires location for user input/output
|
||||
ERROR: 0:12: 'constant_id' : can only be applied to a scalar
|
||||
ERROR: 0:13: 'constant_id' : specialization-constant id already used
|
||||
ERROR: 0:13: 'binding' : sampler/texture/image requires layout(binding=X)
|
||||
ERROR: 0:13: 'constant_id' : can only be applied to 'const'-qualified scalar
|
||||
ERROR: 0:13: 'constant_id' : cannot be applied to this type
|
||||
ERROR: 0:14: 'constant_id' : specialization-constant id is too large
|
||||
|
|
@ -26,7 +34,9 @@ ERROR: 0:49: '[]' : only outermost dimension of an array of arrays can be a spec
|
|||
ERROR: 0:50: '[]' : only outermost dimension of an array of arrays can be a specialization constant
|
||||
ERROR: 0:51: '[]' : only outermost dimension of an array of arrays can be a specialization constant
|
||||
ERROR: 0:54: '[]' : only outermost dimension of an array of arrays can be a specialization constant
|
||||
ERROR: 27 compilation errors. No code generated.
|
||||
ERROR: 0:54: 'location' : SPIR-V requires location for user input/output
|
||||
ERROR: 0:58: 'location' : SPIR-V requires location for user input/output
|
||||
ERROR: 37 compilation errors. No code generated.
|
||||
|
||||
|
||||
SPIR-V is not generated for failed compile or link
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue