yum-mirror/glslang

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

Wint3rNightAdd halfBitsToUint16 cases to the halfBitsToInt16 testb79d769a

main
7.0 KiB153 linesraw
1spv.halfBitsToInt16.frag
2// Module Version 10300
3// Generated by (magic number): 8000b
4// Id's are bound by 118
5
6                              Capability Shader
7                              Capability Float16
8                              Capability Int16
9               1:             ExtInstImport  "GLSL.std.450"
10                              MemoryModel Logical GLSL450
11                              EntryPoint Fragment 4  "main" 9 13 72
12                              ExecutionMode 4 OriginUpperLeft
13                              Source GLSL 450
14                              SourceExtension  "GL_EXT_shader_explicit_arithmetic_types"
15                              Name 4  "main"
16                              Name 9  "o"
17                              Name 13  "v"
18                              Name 72  "u"
19                              Decorate 9(o) Location 0
20                              Decorate 13(v) Location 0
21                              Decorate 72(u) Location 1
22               2:             TypeVoid
23               3:             TypeFunction 2
24               6:             TypeInt 32 1
25               7:             TypeVector 6(int) 4
26               8:             TypePointer Output 7(ivec4)
27            9(o):      8(ptr) Variable Output
28              10:             TypeFloat 32
29              11:             TypeVector 10(float) 4
30              12:             TypePointer Input 11(fvec4)
31           13(v):     12(ptr) Variable Input
32              14:             TypeInt 32 0
33              15:     14(int) Constant 0
34              16:             TypePointer Input 10(float)
35              19:             TypeFloat 16
36              21:             TypeInt 16 1
37              24:             TypePointer Output 6(int)
38              26:             TypeVector 10(float) 2
39              29:             TypeVector 19(float16_t) 2
40              31:             TypeVector 21(int16_t) 2
41              33:             TypeVector 6(int) 2
42              40:     14(int) Constant 1
43              43:             TypeVector 10(float) 3
44              46:             TypeVector 19(float16_t) 3
45              48:             TypeVector 21(int16_t) 3
46              50:             TypeVector 6(int) 3
47              59:     14(int) Constant 2
48              63:             TypeVector 19(float16_t) 4
49              65:             TypeVector 21(int16_t) 4
50              70:             TypeVector 14(int) 4
51              71:             TypePointer Output 70(ivec4)
52           72(u):     71(ptr) Variable Output
53              76:             TypeInt 16 0
54              79:             TypePointer Output 14(int)
55              84:             TypeVector 76(int16_t) 2
56              86:             TypeVector 14(int) 2
57              98:             TypeVector 76(int16_t) 3
58             100:             TypeVector 14(int) 3
59             113:             TypeVector 76(int16_t) 4
60         4(main):           2 Function None 3
61               5:             Label
62              17:     16(ptr) AccessChain 13(v) 15
63              18:   10(float) Load 17
64              20:19(float16_t) FConvert 18
65              22: 21(int16_t) Bitcast 20
66              23:      6(int) SConvert 22
67              25:     24(ptr) AccessChain 9(o) 15
68                              Store 25 23
69              27:   11(fvec4) Load 13(v)
70              28:   26(fvec2) VectorShuffle 27 27 0 1
71              30: 29(f16vec2) FConvert 28
72              32: 31(i16vec2) Bitcast 30
73              34:   33(ivec2) SConvert 32
74              35:    7(ivec4) Load 9(o)
75              36:   33(ivec2) VectorShuffle 35 35 0 1
76              37:   33(ivec2) IAdd 36 34
77              38:     24(ptr) AccessChain 9(o) 15
78              39:      6(int) CompositeExtract 37 0
79                              Store 38 39
80              41:     24(ptr) AccessChain 9(o) 40
81              42:      6(int) CompositeExtract 37 1
82                              Store 41 42
83              44:   11(fvec4) Load 13(v)
84              45:   43(fvec3) VectorShuffle 44 44 0 1 2
85              47: 46(f16vec3) FConvert 45
86              49: 48(i16vec3) Bitcast 47
87              51:   50(ivec3) SConvert 49
88              52:    7(ivec4) Load 9(o)
89              53:   50(ivec3) VectorShuffle 52 52 0 1 2
90              54:   50(ivec3) IAdd 53 51
91              55:     24(ptr) AccessChain 9(o) 15
92              56:      6(int) CompositeExtract 54 0
93                              Store 55 56
94              57:     24(ptr) AccessChain 9(o) 40
95              58:      6(int) CompositeExtract 54 1
96                              Store 57 58
97              60:     24(ptr) AccessChain 9(o) 59
98              61:      6(int) CompositeExtract 54 2
99                              Store 60 61
100              62:   11(fvec4) Load 13(v)
101              64: 63(f16vec4) FConvert 62
102              66: 65(i16vec4) Bitcast 64
103              67:    7(ivec4) SConvert 66
104              68:    7(ivec4) Load 9(o)
105              69:    7(ivec4) IAdd 68 67
106                              Store 9(o) 69
107              73:     16(ptr) AccessChain 13(v) 15
108              74:   10(float) Load 73
109              75:19(float16_t) FConvert 74
110              77: 76(int16_t) Bitcast 75
111              78:     14(int) UConvert 77
112              80:     79(ptr) AccessChain 72(u) 15
113                              Store 80 78
114              81:   11(fvec4) Load 13(v)
115              82:   26(fvec2) VectorShuffle 81 81 0 1
116              83: 29(f16vec2) FConvert 82
117              85: 84(i16vec2) Bitcast 83
118              87:   86(ivec2) UConvert 85
119              88:   70(ivec4) Load 72(u)
120              89:   86(ivec2) VectorShuffle 88 88 0 1
121              90:   86(ivec2) IAdd 89 87
122              91:     79(ptr) AccessChain 72(u) 15
123              92:     14(int) CompositeExtract 90 0
124                              Store 91 92
125              93:     79(ptr) AccessChain 72(u) 40
126              94:     14(int) CompositeExtract 90 1
127                              Store 93 94
128              95:   11(fvec4) Load 13(v)
129              96:   43(fvec3) VectorShuffle 95 95 0 1 2
130              97: 46(f16vec3) FConvert 96
131              99: 98(i16vec3) Bitcast 97
132             101:  100(ivec3) UConvert 99
133             102:   70(ivec4) Load 72(u)
134             103:  100(ivec3) VectorShuffle 102 102 0 1 2
135             104:  100(ivec3) IAdd 103 101
136             105:     79(ptr) AccessChain 72(u) 15
137             106:     14(int) CompositeExtract 104 0
138                              Store 105 106
139             107:     79(ptr) AccessChain 72(u) 40
140             108:     14(int) CompositeExtract 104 1
141                              Store 107 108
142             109:     79(ptr) AccessChain 72(u) 59
143             110:     14(int) CompositeExtract 104 2
144                              Store 109 110
145             111:   11(fvec4) Load 13(v)
146             112: 63(f16vec4) FConvert 111
147             114:113(i16vec4) Bitcast 112
148             115:   70(ivec4) UConvert 114
149             116:   70(ivec4) Load 72(u)
150             117:   70(ivec4) IAdd 116 115
151                              Store 72(u) 117
152                              Return
153                              FunctionEnd