HLSL: Make the entry-point shadow function have non-IO params and return.

This also removes an no longer needed makeTemporary() and rationalizes
makeTypeNonIo()'s interface.
This commit is contained in:
John Kessenich 2017-02-01 18:09:17 -07:00
parent 5d3023af03
commit abd8dca86d
24 changed files with 1146 additions and 1346 deletions

View file

@ -1,7 +1,7 @@
hlsl.getdimensions.dx10.vert
Shader version: 450
0:? Sequence
0:11 Function Definition: @main( (temp structure{temp 4-component vector of float Position Pos})
0:11 Function Definition: @main( (temp structure{temp 4-component vector of float Pos})
0:11 Function Parameters:
0:? Sequence
0:21 Sequence
@ -44,8 +44,8 @@ Shader version: 450
0:11 Sequence
0:11 move second child to first child (temp 4-component vector of float)
0:? '@entryPointOutput_Pos' (out 4-component vector of float Position)
0:11 Pos: direct index for structure (temp 4-component vector of float Position)
0:11 Function Call: @main( (temp structure{temp 4-component vector of float Position Pos})
0:11 Pos: direct index for structure (temp 4-component vector of float)
0:11 Function Call: @main( (temp structure{temp 4-component vector of float Pos})
0:11 Constant:
0:11 0 (const int)
0:? Linker Objects
@ -59,7 +59,7 @@ Linked vertex stage:
Shader version: 450
0:? Sequence
0:11 Function Definition: @main( (temp structure{temp 4-component vector of float Position Pos})
0:11 Function Definition: @main( (temp structure{temp 4-component vector of float Pos})
0:11 Function Parameters:
0:? Sequence
0:21 Sequence
@ -102,8 +102,8 @@ Shader version: 450
0:11 Sequence
0:11 move second child to first child (temp 4-component vector of float)
0:? '@entryPointOutput_Pos' (out 4-component vector of float Position)
0:11 Pos: direct index for structure (temp 4-component vector of float Position)
0:11 Function Call: @main( (temp structure{temp 4-component vector of float Position Pos})
0:11 Pos: direct index for structure (temp 4-component vector of float)
0:11 Function Call: @main( (temp structure{temp 4-component vector of float Pos})
0:11 Constant:
0:11 0 (const int)
0:? Linker Objects
@ -113,14 +113,14 @@ Shader version: 450
// Module Version 10000
// Generated by (magic number): 80001
// Id's are bound by 57
// Id's are bound by 51
Capability Shader
Capability Sampled1D
Capability ImageQuery
1: ExtInstImport "GLSL.std.450"
MemoryModel Logical GLSL450
EntryPoint Vertex 4 "main" 48 56
EntryPoint Vertex 4 "main" 42 50
Name 4 "main"
Name 8 "VS_OUTPUT"
MemberName 8(VS_OUTPUT) 0 "Pos"
@ -130,22 +130,19 @@ Shader version: 450
Name 21 "WidthU"
Name 23 "sizeQueryTemp"
Name 28 "NumberOfLevelsU"
Name 31 "VS_OUTPUT"
MemberName 31(VS_OUTPUT) 0 "Pos"
Name 33 "vsout"
Name 48 "@entryPointOutput_Pos"
Name 53 "g_sSamp"
Name 54 "PerVertex_out"
MemberName 54(PerVertex_out) 0 "@entryPointOutput_Pos"
Name 56 "PerVertex_out"
MemberDecorate 8(VS_OUTPUT) 0 BuiltIn Position
Name 32 "vsout"
Name 42 "@entryPointOutput_Pos"
Name 47 "g_sSamp"
Name 48 "PerVertex_out"
MemberName 48(PerVertex_out) 0 "@entryPointOutput_Pos"
Name 50 "PerVertex_out"
Decorate 17(g_tTex1df4) DescriptorSet 0
Decorate 17(g_tTex1df4) Binding 0
Decorate 48(@entryPointOutput_Pos) BuiltIn Position
Decorate 53(g_sSamp) DescriptorSet 0
Decorate 53(g_sSamp) Binding 0
MemberDecorate 54(PerVertex_out) 0 BuiltIn Position
Decorate 54(PerVertex_out) Block
Decorate 42(@entryPointOutput_Pos) BuiltIn Position
Decorate 47(g_sSamp) DescriptorSet 0
Decorate 47(g_sSamp) Binding 0
MemberDecorate 48(PerVertex_out) 0 BuiltIn Position
Decorate 48(PerVertex_out) Block
2: TypeVoid
3: TypeFunction 2
6: TypeFloat 32
@ -159,26 +156,24 @@ Shader version: 450
17(g_tTex1df4): 16(ptr) Variable UniformConstant
19: TypeInt 32 1
25: 12(int) Constant 6
31(VS_OUTPUT): TypeStruct 7(fvec4)
32: TypePointer Function 31(VS_OUTPUT)
34: 19(int) Constant 0
35: 6(float) Constant 0
36: 7(fvec4) ConstantComposite 35 35 35 35
37: TypePointer Function 7(fvec4)
40: TypePointer Function 8(VS_OUTPUT)
47: TypePointer Output 7(fvec4)
48(@entryPointOutput_Pos): 47(ptr) Variable Output
51: TypeSampler
52: TypePointer UniformConstant 51
53(g_sSamp): 52(ptr) Variable UniformConstant
54(PerVertex_out): TypeStruct 7(fvec4)
55: TypePointer Output 54(PerVertex_out)
56(PerVertex_out): 55(ptr) Variable Output
31: TypePointer Function 8(VS_OUTPUT)
33: 19(int) Constant 0
34: 6(float) Constant 0
35: 7(fvec4) ConstantComposite 34 34 34 34
36: TypePointer Function 7(fvec4)
41: TypePointer Output 7(fvec4)
42(@entryPointOutput_Pos): 41(ptr) Variable Output
45: TypeSampler
46: TypePointer UniformConstant 45
47(g_sSamp): 46(ptr) Variable UniformConstant
48(PerVertex_out): TypeStruct 7(fvec4)
49: TypePointer Output 48(PerVertex_out)
50(PerVertex_out): 49(ptr) Variable Output
4(main): 2 Function None 3
5: Label
49:8(VS_OUTPUT) FunctionCall 10(@main()
50: 7(fvec4) CompositeExtract 49 0
Store 48(@entryPointOutput_Pos) 50
43:8(VS_OUTPUT) FunctionCall 10(@main()
44: 7(fvec4) CompositeExtract 43 0
Store 42(@entryPointOutput_Pos) 44
Return
FunctionEnd
10(@main():8(VS_OUTPUT) Function None 9
@ -187,8 +182,7 @@ Shader version: 450
21(WidthU): 13(ptr) Variable Function
23(sizeQueryTemp): 13(ptr) Variable Function
28(NumberOfLevelsU): 13(ptr) Variable Function
33(vsout): 32(ptr) Variable Function
41: 40(ptr) Variable Function
32(vsout): 31(ptr) Variable Function
18: 15 Load 17(g_tTex1df4)
20: 19(int) ImageQuerySize 18
Store 14(sizeQueryTemp) 20
@ -202,12 +196,8 @@ Shader version: 450
29: 15 Load 17(g_tTex1df4)
30: 19(int) ImageQueryLevels 29
Store 28(NumberOfLevelsU) 30
38: 37(ptr) AccessChain 33(vsout) 34
Store 38 36
39:31(VS_OUTPUT) Load 33(vsout)
42: 7(fvec4) CompositeExtract 39 0
43: 37(ptr) AccessChain 41 34
Store 43 42
44:8(VS_OUTPUT) Load 41
ReturnValue 44
37: 36(ptr) AccessChain 32(vsout) 33
Store 37 35
38:8(VS_OUTPUT) Load 32(vsout)
ReturnValue 38
FunctionEnd