Apply memory decorations from GLSL source to the top-level OpVariable. Previously, these decorations would only be applied to individual members. While this is correct behavior, it is more convenient for some front ends to see the decorations (specifically ReadOnly and WriteOnly) applied to the whole variable rather than individual members.
48 lines
2.3 KiB
Text
48 lines
2.3 KiB
Text
spv.expect_assume.assumeEXT.comp
|
|
// Module Version 10000
|
|
// Generated by (magic number): 8000b
|
|
// Id's are bound by 22
|
|
|
|
Capability Shader
|
|
Capability ExpectAssumeKHR
|
|
Extension "SPV_KHR_expect_assume"
|
|
1: ExtInstImport "GLSL.std.450"
|
|
MemoryModel Logical GLSL450
|
|
EntryPoint GLCompute 4 "main"
|
|
ExecutionMode 4 LocalSize 8 1 1
|
|
Source GLSL 450
|
|
SourceExtension "GL_EXT_expect_assume"
|
|
Name 4 "main"
|
|
Name 7 "roblock"
|
|
MemberName 7(roblock) 0 "i"
|
|
Name 9 "ro"
|
|
Decorate 7(roblock) BufferBlock
|
|
MemberDecorate 7(roblock) 0 NonWritable
|
|
MemberDecorate 7(roblock) 0 Offset 0
|
|
Decorate 9(ro) NonWritable
|
|
Decorate 9(ro) Binding 0
|
|
Decorate 9(ro) DescriptorSet 0
|
|
Decorate 21 BuiltIn WorkgroupSize
|
|
2: TypeVoid
|
|
3: TypeFunction 2
|
|
6: TypeInt 32 1
|
|
7(roblock): TypeStruct 6(int)
|
|
8: TypePointer Uniform 7(roblock)
|
|
9(ro): 8(ptr) Variable Uniform
|
|
10: 6(int) Constant 0
|
|
11: TypePointer Uniform 6(int)
|
|
14: 6(int) Constant 42
|
|
15: TypeBool
|
|
17: TypeInt 32 0
|
|
18: TypeVector 17(int) 3
|
|
19: 17(int) Constant 8
|
|
20: 17(int) Constant 1
|
|
21: 18(ivec3) ConstantComposite 19 20 20
|
|
4(main): 2 Function None 3
|
|
5: Label
|
|
12: 11(ptr) AccessChain 9(ro) 10
|
|
13: 6(int) Load 12
|
|
16: 15(bool) SGreaterThan 13 14
|
|
AssumeTrueKHR 16
|
|
Return
|
|
FunctionEnd
|