HLSL: Fix #1332: consistently use uint for counter buf typing.

This commit is contained in:
John Kessenich
2018-04-10 11:57:20 -06:00
parent 1dcd162399
commit 6ae18707f9
9 changed files with 345 additions and 347 deletions

View File

@@ -1,7 +1,7 @@
hlsl.noSemantic.functionality1.comp
// Module Version 10000
// Generated by (magic number): 80006
// Id's are bound by 31
// Id's are bound by 30
Capability Shader
Extension "SPV_GOOGLE_hlsl_functionality1"
@@ -15,18 +15,18 @@ hlsl.noSemantic.functionality1.comp
Name 11 "Buf"
MemberName 11(Buf) 0 "@data"
Name 13 "Buf"
Name 16 "Buf@count"
MemberName 16(Buf@count) 0 "@count"
Name 18 "Buf@count"
Name 17 "Buf@count"
MemberName 17(Buf@count) 0 "@count"
Name 19 "Buf@count"
Decorate 10 ArrayStride 16
MemberDecorate 11(Buf) 0 Offset 0
Decorate 11(Buf) BufferBlock
Decorate 13(Buf) DescriptorSet 0
Decorate 13(Buf) Binding 0
MemberDecorate 16(Buf@count) 0 Offset 0
Decorate 16(Buf@count) BufferBlock
Decorate 18(Buf@count) DescriptorSet 0
DecorateId 13(Buf) DecorationHlslCounterBufferGOOGLE 18(Buf@count)
MemberDecorate 17(Buf@count) 0 Offset 0
Decorate 17(Buf@count) BufferBlock
Decorate 19(Buf@count) DescriptorSet 0
DecorateId 13(Buf) DecorationHlslCounterBufferGOOGLE 19(Buf@count)
2: TypeVoid
3: TypeFunction 2
8: TypeFloat 32
@@ -37,27 +37,26 @@ hlsl.noSemantic.functionality1.comp
13(Buf): 12(ptr) Variable Uniform
14: TypeInt 32 1
15: 14(int) Constant 0
16(Buf@count): TypeStruct 14(int)
17: TypePointer Uniform 16(Buf@count)
18(Buf@count): 17(ptr) Variable Uniform
19: TypePointer Uniform 14(int)
21: 14(int) Constant 1
22: TypeInt 32 0
23: 22(int) Constant 1
24: 22(int) Constant 0
26: 8(float) Constant 1065353216
27: 9(fvec4) ConstantComposite 26 26 26 26
28: TypePointer Uniform 9(fvec4)
16: TypeInt 32 0
17(Buf@count): TypeStruct 16(int)
18: TypePointer Uniform 17(Buf@count)
19(Buf@count): 18(ptr) Variable Uniform
20: TypePointer Uniform 16(int)
22: 16(int) Constant 1
23: 16(int) Constant 0
25: 8(float) Constant 1065353216
26: 9(fvec4) ConstantComposite 25 25 25 25
27: TypePointer Uniform 9(fvec4)
4(main): 2 Function None 3
5: Label
30: 2 FunctionCall 6(@main()
29: 2 FunctionCall 6(@main()
Return
FunctionEnd
6(@main(): 2 Function None 3
7: Label
20: 19(ptr) AccessChain 18(Buf@count) 15
25: 22(int) AtomicIAdd 20 23 24 21
29: 28(ptr) AccessChain 13(Buf) 15 25
Store 29 27
21: 20(ptr) AccessChain 19(Buf@count) 15
24: 16(int) AtomicIAdd 21 22 23 22
28: 27(ptr) AccessChain 13(Buf) 15 24
Store 28 26
Return
FunctionEnd