HLSL: Flatten whole-struct assigns and returns when targeting flattened I/O structs.
This commit is contained in:
parent
f8e494c18c
commit
d21baed6bc
67 changed files with 4024 additions and 2886 deletions
|
|
@ -31,10 +31,20 @@ gl_FragCoord origin is upper left
|
|||
0:127 1 (const int)
|
||||
0:127 Constant:
|
||||
0:127 1.000000
|
||||
0:129 Sequence
|
||||
0:129 move second child to first child (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:? '@entryPointOutput' (out structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:129 'psout' (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:? Sequence
|
||||
0:? Sequence
|
||||
0:129 move second child to first child (temp 4-component vector of float)
|
||||
0:? 'Color' (layout(location=0 ) out 4-component vector of float)
|
||||
0:129 Color: direct index for structure (temp 4-component vector of float)
|
||||
0:129 'psout' (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:129 Constant:
|
||||
0:129 0 (const int)
|
||||
0:129 move second child to first child (temp float)
|
||||
0:? 'Depth' (out float FragDepth)
|
||||
0:129 Depth: direct index for structure (temp float FragDepth)
|
||||
0:129 'psout' (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:129 Constant:
|
||||
0:129 1 (const int)
|
||||
0:129 Branch: Return
|
||||
0:? Linker Objects
|
||||
0:? 'Color' (layout(location=0 ) out 4-component vector of float)
|
||||
|
|
@ -76,10 +86,20 @@ gl_FragCoord origin is upper left
|
|||
0:127 1 (const int)
|
||||
0:127 Constant:
|
||||
0:127 1.000000
|
||||
0:129 Sequence
|
||||
0:129 move second child to first child (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:? '@entryPointOutput' (out structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:129 'psout' (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:? Sequence
|
||||
0:? Sequence
|
||||
0:129 move second child to first child (temp 4-component vector of float)
|
||||
0:? 'Color' (layout(location=0 ) out 4-component vector of float)
|
||||
0:129 Color: direct index for structure (temp 4-component vector of float)
|
||||
0:129 'psout' (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:129 Constant:
|
||||
0:129 0 (const int)
|
||||
0:129 move second child to first child (temp float)
|
||||
0:? 'Depth' (out float FragDepth)
|
||||
0:129 Depth: direct index for structure (temp float FragDepth)
|
||||
0:129 'psout' (temp structure{temp 4-component vector of float Color, temp float FragDepth Depth})
|
||||
0:129 Constant:
|
||||
0:129 1 (const int)
|
||||
0:129 Branch: Return
|
||||
0:? Linker Objects
|
||||
0:? 'Color' (layout(location=0 ) out 4-component vector of float)
|
||||
|
|
@ -87,12 +107,12 @@ gl_FragCoord origin is upper left
|
|||
|
||||
// Module Version 10000
|
||||
// Generated by (magic number): 80001
|
||||
// Id's are bound by 34
|
||||
// Id's are bound by 35
|
||||
|
||||
Capability Shader
|
||||
1: ExtInstImport "GLSL.std.450"
|
||||
MemoryModel Logical GLSL450
|
||||
EntryPoint Fragment 4 "main" 27 31 33
|
||||
EntryPoint Fragment 4 "main" 27 31
|
||||
ExecutionMode 4 OriginUpperLeft
|
||||
Name 4 "main"
|
||||
Name 8 "thisLineIs"
|
||||
|
|
@ -100,12 +120,11 @@ gl_FragCoord origin is upper left
|
|||
MemberName 12(PS_OUTPUT) 0 "Color"
|
||||
MemberName 12(PS_OUTPUT) 1 "Depth"
|
||||
Name 14 "psout"
|
||||
Name 27 "@entryPointOutput"
|
||||
Name 31 "Color"
|
||||
Name 33 "Depth"
|
||||
Name 27 "Color"
|
||||
Name 31 "Depth"
|
||||
MemberDecorate 12(PS_OUTPUT) 1 BuiltIn FragDepth
|
||||
Decorate 31(Color) Location 0
|
||||
Decorate 33(Depth) BuiltIn FragDepth
|
||||
Decorate 27(Color) Location 0
|
||||
Decorate 31(Depth) BuiltIn FragDepth
|
||||
2: TypeVoid
|
||||
3: TypeFunction 2
|
||||
6: TypeInt 32 1
|
||||
|
|
@ -121,12 +140,10 @@ gl_FragCoord origin is upper left
|
|||
21: TypePointer Function 11(fvec4)
|
||||
23: 6(int) Constant 1
|
||||
24: TypePointer Function 10(float)
|
||||
26: TypePointer Output 12(PS_OUTPUT)
|
||||
27(@entryPointOutput): 26(ptr) Variable Output
|
||||
30: TypePointer Output 11(fvec4)
|
||||
31(Color): 30(ptr) Variable Output
|
||||
32: TypePointer Output 10(float)
|
||||
33(Depth): 32(ptr) Variable Output
|
||||
26: TypePointer Output 11(fvec4)
|
||||
27(Color): 26(ptr) Variable Output
|
||||
30: TypePointer Output 10(float)
|
||||
31(Depth): 30(ptr) Variable Output
|
||||
4(main): 2 Function None 3
|
||||
5: Label
|
||||
8(thisLineIs): 7(ptr) Variable Function
|
||||
|
|
@ -139,7 +156,11 @@ gl_FragCoord origin is upper left
|
|||
Store 22 20
|
||||
25: 24(ptr) AccessChain 14(psout) 23
|
||||
Store 25 19
|
||||
28:12(PS_OUTPUT) Load 14(psout)
|
||||
Store 27(@entryPointOutput) 28
|
||||
28: 21(ptr) AccessChain 14(psout) 15
|
||||
29: 11(fvec4) Load 28
|
||||
Store 27(Color) 29
|
||||
32: 24(ptr) AccessChain 14(psout) 23
|
||||
33: 10(float) Load 32
|
||||
Store 31(Depth) 33
|
||||
Return
|
||||
FunctionEnd
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue