HLSL: Refactor attribute implementation.
- make it sharable with GLSL - correct the case insensitivity - remove the map; queries are not needed, all entries need processing - make it easier to build bottom up (will help GLSL parsing) - support semantic checking and reporting - allow front-end dependent semantics and attribute name mapping
This commit is contained in:
parent
e349af7e20
commit
e18fd20d5c
17 changed files with 638 additions and 500 deletions
|
|
@ -1,20 +1,20 @@
|
|||
hlsl.numthreads.comp
|
||||
Shader version: 500
|
||||
local_size = (4, 4, 2)
|
||||
local_size = (1, 4, 8)
|
||||
0:? Sequence
|
||||
0:4 Function Definition: main(vu3; ( temp void)
|
||||
0:4 Function Parameters:
|
||||
0:4 'tid' ( in 3-component vector of uint)
|
||||
0:9 Function Definition: @main_aux1(vu3; ( temp void)
|
||||
0:9 Function Definition: @main_aux2(vu3; ( temp void)
|
||||
0:9 Function Parameters:
|
||||
0:9 'tid' ( in 3-component vector of uint)
|
||||
0:9 Function Definition: main_aux1( ( temp void)
|
||||
0:9 Function Definition: main_aux2( ( temp void)
|
||||
0:9 Function Parameters:
|
||||
0:? Sequence
|
||||
0:9 move second child to first child ( temp 3-component vector of uint)
|
||||
0:? 'tid' ( temp 3-component vector of uint)
|
||||
0:? 'tid' ( in 3-component vector of uint GlobalInvocationID)
|
||||
0:9 Function Call: @main_aux1(vu3; ( temp void)
|
||||
0:9 Function Call: @main_aux2(vu3; ( temp void)
|
||||
0:? 'tid' ( temp 3-component vector of uint)
|
||||
0:? Linker Objects
|
||||
0:? 'tid' ( in 3-component vector of uint GlobalInvocationID)
|
||||
|
|
@ -24,21 +24,21 @@ Linked compute stage:
|
|||
|
||||
|
||||
Shader version: 500
|
||||
local_size = (4, 4, 2)
|
||||
local_size = (1, 4, 8)
|
||||
0:? Sequence
|
||||
0:4 Function Definition: main(vu3; ( temp void)
|
||||
0:4 Function Parameters:
|
||||
0:4 'tid' ( in 3-component vector of uint)
|
||||
0:9 Function Definition: @main_aux1(vu3; ( temp void)
|
||||
0:9 Function Definition: @main_aux2(vu3; ( temp void)
|
||||
0:9 Function Parameters:
|
||||
0:9 'tid' ( in 3-component vector of uint)
|
||||
0:9 Function Definition: main_aux1( ( temp void)
|
||||
0:9 Function Definition: main_aux2( ( temp void)
|
||||
0:9 Function Parameters:
|
||||
0:? Sequence
|
||||
0:9 move second child to first child ( temp 3-component vector of uint)
|
||||
0:? 'tid' ( temp 3-component vector of uint)
|
||||
0:? 'tid' ( in 3-component vector of uint GlobalInvocationID)
|
||||
0:9 Function Call: @main_aux1(vu3; ( temp void)
|
||||
0:9 Function Call: @main_aux2(vu3; ( temp void)
|
||||
0:? 'tid' ( temp 3-component vector of uint)
|
||||
0:? Linker Objects
|
||||
0:? 'tid' ( in 3-component vector of uint GlobalInvocationID)
|
||||
|
|
@ -50,13 +50,13 @@ local_size = (4, 4, 2)
|
|||
Capability Shader
|
||||
1: ExtInstImport "GLSL.std.450"
|
||||
MemoryModel Logical GLSL450
|
||||
EntryPoint GLCompute 4 "main_aux1" 18
|
||||
ExecutionMode 4 LocalSize 4 4 2
|
||||
EntryPoint GLCompute 4 "main_aux2" 18
|
||||
ExecutionMode 4 LocalSize 1 4 8
|
||||
Source HLSL 500
|
||||
Name 4 "main_aux1"
|
||||
Name 4 "main_aux2"
|
||||
Name 11 "main(vu3;"
|
||||
Name 10 "tid"
|
||||
Name 14 "@main_aux1(vu3;"
|
||||
Name 14 "@main_aux2(vu3;"
|
||||
Name 13 "tid"
|
||||
Name 16 "tid"
|
||||
Name 18 "tid"
|
||||
|
|
@ -70,7 +70,7 @@ local_size = (4, 4, 2)
|
|||
9: TypeFunction 2 8(ptr)
|
||||
17: TypePointer Input 7(ivec3)
|
||||
18(tid): 17(ptr) Variable Input
|
||||
4(main_aux1): 2 Function None 3
|
||||
4(main_aux2): 2 Function None 3
|
||||
5: Label
|
||||
16(tid): 8(ptr) Variable Function
|
||||
20(param): 8(ptr) Variable Function
|
||||
|
|
@ -78,7 +78,7 @@ local_size = (4, 4, 2)
|
|||
Store 16(tid) 19
|
||||
21: 7(ivec3) Load 16(tid)
|
||||
Store 20(param) 21
|
||||
22: 2 FunctionCall 14(@main_aux1(vu3;) 20(param)
|
||||
22: 2 FunctionCall 14(@main_aux2(vu3;) 20(param)
|
||||
Return
|
||||
FunctionEnd
|
||||
11(main(vu3;): 2 Function None 9
|
||||
|
|
@ -86,7 +86,7 @@ local_size = (4, 4, 2)
|
|||
12: Label
|
||||
Return
|
||||
FunctionEnd
|
||||
14(@main_aux1(vu3;): 2 Function None 9
|
||||
14(@main_aux2(vu3;): 2 Function None 9
|
||||
13(tid): 8(ptr) FunctionParameter
|
||||
15: Label
|
||||
Return
|
||||
|
|
|
|||
|
|
@ -4,11 +4,8 @@ void main(uint3 tid : SV_DispatchThreadID )
|
|||
{
|
||||
}
|
||||
|
||||
[numTHreaDs(4,4,2)] // case insensitive
|
||||
void main_aux1(uint3 tid : SV_DispatchThreadID )
|
||||
[numthreads(1,4,8)]
|
||||
void main_aux2(uint3 tid : SV_DispatchThreadID )
|
||||
{
|
||||
}
|
||||
|
||||
[numthreads(1,4,8)]
|
||||
void main_aux2(uint3 tid : SV_DispatchThreadID );
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue