SPV: Implement Vulkan version of GLSL (KHR_vulkan_glsl).

This commit is contained in:
John Kessenich 2016-02-15 20:58:50 -07:00
parent 019f08fcd8
commit 6c292d3ba7
200 changed files with 7841 additions and 5577 deletions

View file

@ -5,13 +5,13 @@ Linked vertex stage:
// Module Version 10000
// Generated by (magic number): 80001
// Id's are bound by 67
// Id's are bound by 63
Capability Shader
Capability ClipDistance
1: ExtInstImport "GLSL.std.450"
MemoryModel Logical GLSL450
EntryPoint Vertex 4 "main" 13 17 39 65 66
EntryPoint Vertex 4 "main" 13 17 23 38 62
Source GLSL 150
Name 4 "main"
Name 11 "gl_PerVertex"
@ -21,26 +21,23 @@ Linked vertex stage:
Name 13 ""
Name 17 "iv4"
Name 23 "ps"
Name 35 "s1"
MemberName 35(s1) 0 "a"
MemberName 35(s1) 1 "a2"
MemberName 35(s1) 2 "b"
Name 37 "s2"
MemberName 37(s2) 0 "c"
MemberName 37(s2) 1 "d"
Name 39 "s2out"
Name 41 "i"
Name 48 "s2D"
Name 63 "ui"
Name 65 "gl_VertexID"
Name 66 "gl_InstanceID"
Name 34 "s1"
MemberName 34(s1) 0 "a"
MemberName 34(s1) 1 "a2"
MemberName 34(s1) 2 "b"
Name 36 "s2"
MemberName 36(s2) 0 "c"
MemberName 36(s2) 1 "d"
Name 38 "s2out"
Name 40 "i"
Name 47 "s2D"
Name 62 "ui"
MemberDecorate 11(gl_PerVertex) 0 Invariant
MemberDecorate 11(gl_PerVertex) 0 BuiltIn Position
MemberDecorate 11(gl_PerVertex) 1 BuiltIn PointSize
MemberDecorate 11(gl_PerVertex) 2 BuiltIn ClipDistance
Decorate 11(gl_PerVertex) Block
Decorate 65(gl_VertexID) BuiltIn VertexId
Decorate 66(gl_InstanceID) BuiltIn InstanceId
Decorate 47(s2D) DescriptorSet 0
2: TypeVoid
3: TypeFunction 2
6: TypeFloat 32
@ -57,58 +54,54 @@ Linked vertex stage:
17(iv4): 16(ptr) Variable Input
19: TypePointer Output 7(fvec4)
21: 14(int) Constant 1
22: TypePointer UniformConstant 6(float)
23(ps): 22(ptr) Variable UniformConstant
22: TypePointer Input 6(float)
23(ps): 22(ptr) Variable Input
25: TypePointer Output 6(float)
27: 14(int) Constant 2
28: 8(int) Constant 0
29: TypePointer Input 6(float)
33: 8(int) Constant 3
34: TypeArray 7(fvec4) 33
35(s1): TypeStruct 14(int) 14(int) 34
36: TypeArray 35(s1) 9
37(s2): TypeStruct 14(int) 36
38: TypePointer Output 37(s2)
39(s2out): 38(ptr) Variable Output
40: TypePointer Function 14(int)
45: TypeImage 6(float) 2D sampled format:Unknown
46: TypeSampledImage 45
47: TypePointer UniformConstant 46
48(s2D): 47(ptr) Variable UniformConstant
50: TypeVector 6(float) 2
51: 6(float) Constant 1056964608
52: 50(fvec2) ConstantComposite 51 51
53: 6(float) Constant 0
56: TypeVector 6(float) 3
57: 56(fvec3) ConstantComposite 51 51 51
60: 6(float) Constant 1078774989
62: TypePointer UniformConstant 14(int)
63(ui): 62(ptr) Variable UniformConstant
64: TypePointer Input 14(int)
65(gl_VertexID): 64(ptr) Variable Input
66(gl_InstanceID): 64(ptr) Variable Input
32: 8(int) Constant 3
33: TypeArray 7(fvec4) 32
34(s1): TypeStruct 14(int) 14(int) 33
35: TypeArray 34(s1) 9
36(s2): TypeStruct 14(int) 35
37: TypePointer Output 36(s2)
38(s2out): 37(ptr) Variable Output
39: TypePointer Function 14(int)
44: TypeImage 6(float) 2D sampled format:Unknown
45: TypeSampledImage 44
46: TypePointer UniformConstant 45
47(s2D): 46(ptr) Variable UniformConstant
49: TypeVector 6(float) 2
50: 6(float) Constant 1056964608
51: 49(fvec2) ConstantComposite 50 50
52: 6(float) Constant 0
55: TypeVector 6(float) 3
56: 55(fvec3) ConstantComposite 50 50 50
59: 6(float) Constant 1078774989
61: TypePointer Input 14(int)
62(ui): 61(ptr) Variable Input
4(main): 2 Function None 3
5: Label
41(i): 40(ptr) Variable Function
40(i): 39(ptr) Variable Function
18: 7(fvec4) Load 17(iv4)
20: 19(ptr) AccessChain 13 15
Store 20 18
24: 6(float) Load 23(ps)
26: 25(ptr) AccessChain 13 21
Store 26 24
30: 29(ptr) AccessChain 17(iv4) 28
31: 6(float) Load 30
32: 25(ptr) AccessChain 13 27 27
Store 32 31
42: 14(int) Load 41(i)
43: 6(float) Load 23(ps)
44: 25(ptr) AccessChain 39(s2out) 21 42 27 27 33
Store 44 43
49: 46 Load 48(s2D)
54: 7(fvec4) ImageSampleExplicitLod 49 52 Lod 53
55: 46 Load 48(s2D)
58: 7(fvec4) ImageSampleProjExplicitLod 55 57 Lod 53
59: 46 Load 48(s2D)
61: 7(fvec4) ImageSampleExplicitLod 59 52 Lod 60
29: 22(ptr) AccessChain 17(iv4) 28
30: 6(float) Load 29
31: 25(ptr) AccessChain 13 27 27
Store 31 30
41: 14(int) Load 40(i)
42: 6(float) Load 23(ps)
43: 25(ptr) AccessChain 38(s2out) 21 41 27 27 32
Store 43 42
48: 45 Load 47(s2D)
53: 7(fvec4) ImageSampleExplicitLod 48 51 Lod 52
54: 45 Load 47(s2D)
57: 7(fvec4) ImageSampleProjExplicitLod 54 56 Lod 52
58: 45 Load 47(s2D)
60: 7(fvec4) ImageSampleExplicitLod 58 51 Lod 59
Return
FunctionEnd