1hlsl.partialFlattenLocal.vert
2WARNING: AST will form illegal SPIR-V; need to transform to legalize
3Shader version: 500
40:? Sequence
50:12  Function Definition: @main(vf4; ( temp 4-component vector of float)
60:12    Function Parameters:
70:12      'pos' ( in 4-component vector of float)
80:?     Sequence
90:14      move second child to first child ( temp texture2D)
100:14        tex: direct index for structure ( temp texture2D)
110:14          'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
120:14          Constant:
130:14            0 (const int)
140:14        'tex' ( uniform texture2D)
150:15      move second child to first child ( temp 3-component vector of float)
160:15        direct index ( temp 3-component vector of float)
170:15          pos: direct index for structure ( temp 3-element array of 3-component vector of float)
180:15            'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
190:15            Constant:
200:15              1 (const int)
210:15          Constant:
220:15            0 (const int)
230:?         Constant:
240:?           0.000000
250:?           0.000000
260:?           0.000000
270:16      move second child to first child ( temp 2-component vector of float)
280:16        direct index ( temp 2-component vector of float)
290:16          uv: direct index for structure ( temp 2-element array of 2-component vector of float)
300:16            'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
310:16            Constant:
320:16              2 (const int)
330:16          Constant:
340:16            0 (const int)
350:?         Constant:
360:?           0.000000
370:?           1.000000
380:17      move second child to first child ( temp float)
390:17        x: direct index for structure ( temp float)
400:17          'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
410:17          Constant:
420:17            3 (const int)
430:17        Constant:
440:17          1.000000
450:18      move second child to first child ( temp int)
460:18        n: direct index for structure ( temp int)
470:18          'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
480:18          Constant:
490:18            4 (const int)
500:18        Constant:
510:18          3 (const int)
520:20      Sequence
530:20        move second child to first child ( temp int)
540:20          'i' ( temp int)
550:20          Constant:
560:20            0 (const int)
570:20        Loop with condition tested first
580:20          Loop Condition
590:20          Compare Less Than ( temp bool)
600:20            'i' ( temp int)
610:20            Constant:
620:20              1 (const int)
630:20          Loop Body
640:?           Sequence
650:21            add second child into first child ( temp 2-component vector of float)
660:21              vector swizzle ( temp 2-component vector of float)
670:21                indirect index ( temp 3-component vector of float)
680:21                  pos: direct index for structure ( temp 3-element array of 3-component vector of float)
690:21                    'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
700:21                    Constant:
710:21                      1 (const int)
720:21                  'i' ( temp int)
730:21                Sequence
740:21                  Constant:
750:21                    0 (const int)
760:21                  Constant:
770:21                    1 (const int)
780:21              indirect index ( temp 2-component vector of float)
790:21                uv: direct index for structure ( temp 2-element array of 2-component vector of float)
800:21                  'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
810:21                  Constant:
820:21                    2 (const int)
830:21                'i' ( temp int)
840:20          Loop Terminal Expression
850:20          Pre-Increment ( temp int)
860:20            'i' ( temp int)
870:24      Sequence
880:24        move second child to first child ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
890:24          'packed2' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
900:24          'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
910:26      Branch: Return with expression
920:26        add ( temp 4-component vector of float)
930:26          'pos' ( in 4-component vector of float)
940:?           Construct vec4 ( temp 4-component vector of float)
950:26            direct index ( temp 3-component vector of float)
960:26              pos: direct index for structure ( temp 3-element array of 3-component vector of float)
970:26                'packed2' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
980:26                Constant:
990:26                  1 (const int)
1000:26              Constant:
1010:26                0 (const int)
1020:26            Constant:
1030:26              0.000000
1040:12  Function Definition: main( ( temp void)
1050:12    Function Parameters:
1060:?     Sequence
1070:12      move second child to first child ( temp 4-component vector of float)
1080:?         'pos' ( temp 4-component vector of float)
1090:?         'pos' (layout( location=0) in 4-component vector of float)
1100:12      move second child to first child ( temp 4-component vector of float)
1110:?         '@entryPointOutput' ( out 4-component vector of float Position)
1120:12        Function Call: @main(vf4; ( temp 4-component vector of float)
1130:?           'pos' ( temp 4-component vector of float)
1140:?   Linker Objects
1150:?     'tex' ( uniform texture2D)
1160:?     '@entryPointOutput' ( out 4-component vector of float Position)
1170:?     'pos' (layout( location=0) in 4-component vector of float)
118
119
120Linked vertex stage:
121
122
123Shader version: 500
1240:? Sequence
1250:12  Function Definition: @main(vf4; ( temp 4-component vector of float)
1260:12    Function Parameters:
1270:12      'pos' ( in 4-component vector of float)
1280:?     Sequence
1290:14      move second child to first child ( temp texture2D)
1300:14        tex: direct index for structure ( temp texture2D)
1310:14          'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
1320:14          Constant:
1330:14            0 (const int)
1340:14        'tex' ( uniform texture2D)
1350:15      move second child to first child ( temp 3-component vector of float)
1360:15        direct index ( temp 3-component vector of float)
1370:15          pos: direct index for structure ( temp 3-element array of 3-component vector of float)
1380:15            'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
1390:15            Constant:
1400:15              1 (const int)
1410:15          Constant:
1420:15            0 (const int)
1430:?         Constant:
1440:?           0.000000
1450:?           0.000000
1460:?           0.000000
1470:16      move second child to first child ( temp 2-component vector of float)
1480:16        direct index ( temp 2-component vector of float)
1490:16          uv: direct index for structure ( temp 2-element array of 2-component vector of float)
1500:16            'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
1510:16            Constant:
1520:16              2 (const int)
1530:16          Constant:
1540:16            0 (const int)
1550:?         Constant:
1560:?           0.000000
1570:?           1.000000
1580:17      move second child to first child ( temp float)
1590:17        x: direct index for structure ( temp float)
1600:17          'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
1610:17          Constant:
1620:17            3 (const int)
1630:17        Constant:
1640:17          1.000000
1650:18      move second child to first child ( temp int)
1660:18        n: direct index for structure ( temp int)
1670:18          'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
1680:18          Constant:
1690:18            4 (const int)
1700:18        Constant:
1710:18          3 (const int)
1720:20      Sequence
1730:20        move second child to first child ( temp int)
1740:20          'i' ( temp int)
1750:20          Constant:
1760:20            0 (const int)
1770:20        Loop with condition tested first
1780:20          Loop Condition
1790:20          Compare Less Than ( temp bool)
1800:20            'i' ( temp int)
1810:20            Constant:
1820:20              1 (const int)
1830:20          Loop Body
1840:?           Sequence
1850:21            add second child into first child ( temp 2-component vector of float)
1860:21              vector swizzle ( temp 2-component vector of float)
1870:21                indirect index ( temp 3-component vector of float)
1880:21                  pos: direct index for structure ( temp 3-element array of 3-component vector of float)
1890:21                    'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
1900:21                    Constant:
1910:21                      1 (const int)
1920:21                  'i' ( temp int)
1930:21                Sequence
1940:21                  Constant:
1950:21                    0 (const int)
1960:21                  Constant:
1970:21                    1 (const int)
1980:21              indirect index ( temp 2-component vector of float)
1990:21                uv: direct index for structure ( temp 2-element array of 2-component vector of float)
2000:21                  'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
2010:21                  Constant:
2020:21                    2 (const int)
2030:21                'i' ( temp int)
2040:20          Loop Terminal Expression
2050:20          Pre-Increment ( temp int)
2060:20            'i' ( temp int)
2070:24      Sequence
2080:24        move second child to first child ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
2090:24          'packed2' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
2100:24          'packed' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
2110:26      Branch: Return with expression
2120:26        add ( temp 4-component vector of float)
2130:26          'pos' ( in 4-component vector of float)
2140:?           Construct vec4 ( temp 4-component vector of float)
2150:26            direct index ( temp 3-component vector of float)
2160:26              pos: direct index for structure ( temp 3-element array of 3-component vector of float)
2170:26                'packed2' ( temp structure{ temp texture2D tex,  temp 3-element array of 3-component vector of float pos,  temp 2-element array of 2-component vector of float uv,  temp float x,  temp int n})
2180:26                Constant:
2190:26                  1 (const int)
2200:26              Constant:
2210:26                0 (const int)
2220:26            Constant:
2230:26              0.000000
2240:12  Function Definition: main( ( temp void)
2250:12    Function Parameters:
2260:?     Sequence
2270:12      move second child to first child ( temp 4-component vector of float)
2280:?         'pos' ( temp 4-component vector of float)
2290:?         'pos' (layout( location=0) in 4-component vector of float)
2300:12      move second child to first child ( temp 4-component vector of float)
2310:?         '@entryPointOutput' ( out 4-component vector of float Position)
2320:12        Function Call: @main(vf4; ( temp 4-component vector of float)
2330:?           'pos' ( temp 4-component vector of float)
2340:?   Linker Objects
2350:?     'tex' ( uniform texture2D)
2360:?     '@entryPointOutput' ( out 4-component vector of float Position)
2370:?     'pos' (layout( location=0) in 4-component vector of float)
238
239// Module Version 10000
240// Generated by (magic number): 80007
241// Id's are bound by 90
242
243                              Capability Shader
244               1:             ExtInstImport  "GLSL.std.450"
245                              MemoryModel Logical GLSL450
246                              EntryPoint Vertex 4  "main" 83 86
247                              Source HLSL 500
248                              Name 4  "main"
249                              Name 11  "@main(vf4;"
250                              Name 10  "pos"
251                              Name 22  "Packed"
252                              MemberName 22(Packed) 0  "tex"
253                              MemberName 22(Packed) 1  "pos"
254                              MemberName 22(Packed) 2  "uv"
255                              MemberName 22(Packed) 3  "x"
256                              MemberName 22(Packed) 4  "n"
257                              Name 24  "packed"
258                              Name 27  "tex"
259                              Name 47  "i"
260                              Name 69  "packed2"
261                              Name 81  "pos"
262                              Name 83  "pos"
263                              Name 86  "@entryPointOutput"
264                              Name 87  "param"
265                              Decorate 27(tex) DescriptorSet 0
266                              Decorate 83(pos) Location 0
267                              Decorate 86(@entryPointOutput) BuiltIn Position
268               2:             TypeVoid
269               3:             TypeFunction 2
270               6:             TypeFloat 32
271               7:             TypeVector 6(float) 4
272               8:             TypePointer Function 7(fvec4)
273               9:             TypeFunction 7(fvec4) 8(ptr)
274              13:             TypeImage 6(float) 2D sampled format:Unknown
275              14:             TypeVector 6(float) 3
276              15:             TypeInt 32 0
277              16:     15(int) Constant 3
278              17:             TypeArray 14(fvec3) 16
279              18:             TypeVector 6(float) 2
280              19:     15(int) Constant 2
281              20:             TypeArray 18(fvec2) 19
282              21:             TypeInt 32 1
283      22(Packed):             TypeStruct 13 17 20 6(float) 21(int)
284              23:             TypePointer Function 22(Packed)
285              25:     21(int) Constant 0
286              26:             TypePointer UniformConstant 13
287         27(tex):     26(ptr) Variable UniformConstant
288              29:             TypePointer Function 13
289              31:     21(int) Constant 1
290              32:    6(float) Constant 0
291              33:   14(fvec3) ConstantComposite 32 32 32
292              34:             TypePointer Function 14(fvec3)
293              36:     21(int) Constant 2
294              37:    6(float) Constant 1065353216
295              38:   18(fvec2) ConstantComposite 32 37
296              39:             TypePointer Function 18(fvec2)
297              41:     21(int) Constant 3
298              42:             TypePointer Function 6(float)
299              44:     21(int) Constant 4
300              45:             TypePointer Function 21(int)
301              54:             TypeBool
302              82:             TypePointer Input 7(fvec4)
303         83(pos):     82(ptr) Variable Input
304              85:             TypePointer Output 7(fvec4)
30586(@entryPointOutput):     85(ptr) Variable Output
306         4(main):           2 Function None 3
307               5:             Label
308         81(pos):      8(ptr) Variable Function
309       87(param):      8(ptr) Variable Function
310              84:    7(fvec4) Load 83(pos)
311                              Store 81(pos) 84
312              88:    7(fvec4) Load 81(pos)
313                              Store 87(param) 88
314              89:    7(fvec4) FunctionCall 11(@main(vf4;) 87(param)
315                              Store 86(@entryPointOutput) 89
316                              Return
317                              FunctionEnd
318  11(@main(vf4;):    7(fvec4) Function None 9
319         10(pos):      8(ptr) FunctionParameter
320              12:             Label
321      24(packed):     23(ptr) Variable Function
322           47(i):     45(ptr) Variable Function
323     69(packed2):     23(ptr) Variable Function
324              28:          13 Load 27(tex)
325              30:     29(ptr) AccessChain 24(packed) 25
326                              Store 30 28
327              35:     34(ptr) AccessChain 24(packed) 31 25
328                              Store 35 33
329              40:     39(ptr) AccessChain 24(packed) 36 25
330                              Store 40 38
331              43:     42(ptr) AccessChain 24(packed) 41
332                              Store 43 37
333              46:     45(ptr) AccessChain 24(packed) 44
334                              Store 46 41
335                              Store 47(i) 25
336                              Branch 48
337              48:             Label
338                              LoopMerge 50 51 None
339                              Branch 52
340              52:             Label
341              53:     21(int) Load 47(i)
342              55:    54(bool) SLessThan 53 31
343                              BranchConditional 55 49 50
344              49:               Label
345              56:     21(int)   Load 47(i)
346              57:     21(int)   Load 47(i)
347              58:     39(ptr)   AccessChain 24(packed) 36 57
348              59:   18(fvec2)   Load 58
349              60:     34(ptr)   AccessChain 24(packed) 31 56
350              61:   14(fvec3)   Load 60
351              62:   18(fvec2)   VectorShuffle 61 61 0 1
352              63:   18(fvec2)   FAdd 62 59
353              64:     34(ptr)   AccessChain 24(packed) 31 56
354              65:   14(fvec3)   Load 64
355              66:   14(fvec3)   VectorShuffle 65 63 3 4 2
356                                Store 64 66
357                                Branch 51
358              51:               Label
359              67:     21(int)   Load 47(i)
360              68:     21(int)   IAdd 67 31
361                                Store 47(i) 68
362                                Branch 48
363              50:             Label
364              70:  22(Packed) Load 24(packed)
365                              Store 69(packed2) 70
366              71:    7(fvec4) Load 10(pos)
367              72:     34(ptr) AccessChain 69(packed2) 31 25
368              73:   14(fvec3) Load 72
369              74:    6(float) CompositeExtract 73 0
370              75:    6(float) CompositeExtract 73 1
371              76:    6(float) CompositeExtract 73 2
372              77:    7(fvec4) CompositeConstruct 74 75 76 32
373              78:    7(fvec4) FAdd 71 77
374                              ReturnValue 78
375                              FunctionEnd
376