HLSL: Flesh out the loop grammar and productions.
This commit is contained in:
parent
0d2b6de45b
commit
119f8f6906
11 changed files with 645 additions and 2 deletions
145
Test/baseResults/hlsl.whileLoop.frag.out
Executable file
145
Test/baseResults/hlsl.whileLoop.frag.out
Executable file
|
|
@ -0,0 +1,145 @@
|
|||
hlsl.whileLoop.frag
|
||||
Shader version: 450
|
||||
gl_FragCoord origin is upper left
|
||||
0:? Sequence
|
||||
0:8 Function Definition: PixelShaderFunction(vf4; (temp 4-component vector of float)
|
||||
0:2 Function Parameters:
|
||||
0:2 'input' (temp 4-component vector of float)
|
||||
0:? Sequence
|
||||
0:3 Loop with condition tested first
|
||||
0:3 Loop Condition
|
||||
0:3 Compare Not Equal (temp bool)
|
||||
0:3 'input' (temp 4-component vector of float)
|
||||
0:3 'input' (temp 4-component vector of float)
|
||||
0:3 Loop Body
|
||||
0:? Sequence
|
||||
0:3 Branch: Return with expression
|
||||
0:3 'input' (temp 4-component vector of float)
|
||||
0:4 Loop with condition tested first
|
||||
0:4 Loop Condition
|
||||
0:4 Constant:
|
||||
0:4 false (const bool)
|
||||
0:4 No loop body
|
||||
0:5 Loop with condition tested first
|
||||
0:5 Loop Condition
|
||||
0:5 Constant:
|
||||
0:5 false (const bool)
|
||||
0:5 No loop body
|
||||
0:6 Loop with condition tested first
|
||||
0:6 Loop Condition
|
||||
0:6 Constant:
|
||||
0:6 false (const bool)
|
||||
0:6 No loop body
|
||||
0:? Linker Objects
|
||||
|
||||
|
||||
Linked fragment stage:
|
||||
|
||||
|
||||
Shader version: 450
|
||||
gl_FragCoord origin is upper left
|
||||
0:? Sequence
|
||||
0:8 Function Definition: PixelShaderFunction(vf4; (temp 4-component vector of float)
|
||||
0:2 Function Parameters:
|
||||
0:2 'input' (temp 4-component vector of float)
|
||||
0:? Sequence
|
||||
0:3 Loop with condition tested first
|
||||
0:3 Loop Condition
|
||||
0:3 Compare Not Equal (temp bool)
|
||||
0:3 'input' (temp 4-component vector of float)
|
||||
0:3 'input' (temp 4-component vector of float)
|
||||
0:3 Loop Body
|
||||
0:? Sequence
|
||||
0:3 Branch: Return with expression
|
||||
0:3 'input' (temp 4-component vector of float)
|
||||
0:4 Loop with condition tested first
|
||||
0:4 Loop Condition
|
||||
0:4 Constant:
|
||||
0:4 false (const bool)
|
||||
0:4 No loop body
|
||||
0:5 Loop with condition tested first
|
||||
0:5 Loop Condition
|
||||
0:5 Constant:
|
||||
0:5 false (const bool)
|
||||
0:5 No loop body
|
||||
0:6 Loop with condition tested first
|
||||
0:6 Loop Condition
|
||||
0:6 Constant:
|
||||
0:6 false (const bool)
|
||||
0:6 No loop body
|
||||
0:? Linker Objects
|
||||
|
||||
// Module Version 10000
|
||||
// Generated by (magic number): 80001
|
||||
// Id's are bound by 39
|
||||
|
||||
Capability Shader
|
||||
1: ExtInstImport "GLSL.std.450"
|
||||
MemoryModel Logical GLSL450
|
||||
EntryPoint Fragment 4 "PixelShaderFunction"
|
||||
ExecutionMode 4 OriginUpperLeft
|
||||
Source HLSL 450
|
||||
Name 4 "PixelShaderFunction"
|
||||
Name 14 "input"
|
||||
2: TypeVoid
|
||||
3: TypeFunction 2
|
||||
11: TypeFloat 32
|
||||
12: TypeVector 11(float) 4
|
||||
13: TypePointer Function 12(fvec4)
|
||||
17: TypeBool
|
||||
18: TypeVector 17(bool) 4
|
||||
28: 17(bool) ConstantFalse
|
||||
4(PixelShaderFunction): 2 Function None 3
|
||||
5: Label
|
||||
14(input): 13(ptr) Variable Function
|
||||
Branch 6
|
||||
6: Label
|
||||
LoopMerge 8 9 None
|
||||
Branch 10
|
||||
10: Label
|
||||
15: 12(fvec4) Load 14(input)
|
||||
16: 12(fvec4) Load 14(input)
|
||||
19: 18(bvec4) FOrdNotEqual 15 16
|
||||
20: 17(bool) Any 19
|
||||
BranchConditional 20 7 8
|
||||
7: Label
|
||||
21: 12(fvec4) Load 14(input)
|
||||
ReturnValue 21
|
||||
9: Label
|
||||
Branch 6
|
||||
8: Label
|
||||
Branch 23
|
||||
23: Label
|
||||
LoopMerge 25 26 None
|
||||
Branch 27
|
||||
27: Label
|
||||
BranchConditional 28 24 25
|
||||
24: Label
|
||||
Branch 26
|
||||
26: Label
|
||||
Branch 23
|
||||
25: Label
|
||||
Branch 29
|
||||
29: Label
|
||||
LoopMerge 31 32 None
|
||||
Branch 33
|
||||
33: Label
|
||||
BranchConditional 28 30 31
|
||||
30: Label
|
||||
Branch 32
|
||||
32: Label
|
||||
Branch 29
|
||||
31: Label
|
||||
Branch 34
|
||||
34: Label
|
||||
LoopMerge 36 37 None
|
||||
Branch 38
|
||||
38: Label
|
||||
BranchConditional 28 35 36
|
||||
35: Label
|
||||
Branch 37
|
||||
37: Label
|
||||
Branch 34
|
||||
36: Label
|
||||
Return
|
||||
FunctionEnd
|
||||
Loading…
Add table
Add a link
Reference in a new issue