blob: caae540f1d8a67f3e62dc62d19db2f7aef001fef [file] [log] [blame]
James Price94ac0782021-06-02 17:23:03 +00001; SPIR-V
2; Version: 1.3
3; Generator: Google Tint Compiler; 0
Stephen White863d9ed2022-09-02 19:19:10 +00004; Bound: 66
James Price94ac0782021-06-02 17:23:03 +00005; Schema: 0
6 OpCapability Shader
7 OpMemoryModel Logical GLSL450
8 OpEntryPoint GLCompute %unused_entry_point "unused_entry_point"
9 OpExecutionMode %unused_entry_point LocalSize 1 1 1
10 OpName %src_private "src_private"
11 OpName %src_workgroup "src_workgroup"
Stephen White863d9ed2022-09-02 19:19:10 +000012 OpName %src_uniform_block "src_uniform_block"
13 OpMemberName %src_uniform_block 0 "inner"
James Price94ac0782021-06-02 17:23:03 +000014 OpName %S "S"
15 OpMemberName %S 0 "arr"
16 OpName %src_uniform "src_uniform"
17 OpName %src_storage "src_storage"
18 OpName %dst "dst"
19 OpName %dst_nested "dst_nested"
20 OpName %unused_entry_point "unused_entry_point"
21 OpName %ret_arr "ret_arr"
22 OpName %ret_struct_arr "ret_struct_arr"
23 OpName %foo "foo"
24 OpName %src_param "src_param"
25 OpName %src_function "src_function"
26 OpName %src_nested "src_nested"
James Pricef6e5cc02022-01-20 22:11:07 +000027 OpDecorate %_arr_v4int_uint_4 ArrayStride 16
Stephen White863d9ed2022-09-02 19:19:10 +000028 OpDecorate %src_uniform_block Block
29 OpMemberDecorate %src_uniform_block 0 Offset 0
James Price94ac0782021-06-02 17:23:03 +000030 OpMemberDecorate %S 0 Offset 0
Ben Clayton18588542021-06-04 22:17:37 +000031 OpDecorate %src_uniform NonWritable
James Price94ac0782021-06-02 17:23:03 +000032 OpDecorate %src_uniform DescriptorSet 0
33 OpDecorate %src_uniform Binding 0
34 OpDecorate %src_storage DescriptorSet 0
35 OpDecorate %src_storage Binding 1
36 OpDecorate %_arr_int_uint_2 ArrayStride 4
37 OpDecorate %_arr__arr_int_uint_2_uint_3 ArrayStride 8
38 OpDecorate %_arr__arr__arr_int_uint_2_uint_3_uint_4 ArrayStride 24
39 %int = OpTypeInt 32 1
James Pricef6e5cc02022-01-20 22:11:07 +000040 %v4int = OpTypeVector %int 4
James Price94ac0782021-06-02 17:23:03 +000041 %uint = OpTypeInt 32 0
42 %uint_4 = OpConstant %uint 4
James Pricef6e5cc02022-01-20 22:11:07 +000043%_arr_v4int_uint_4 = OpTypeArray %v4int %uint_4
44%_ptr_Private__arr_v4int_uint_4 = OpTypePointer Private %_arr_v4int_uint_4
45 %8 = OpConstantNull %_arr_v4int_uint_4
46%src_private = OpVariable %_ptr_Private__arr_v4int_uint_4 Private %8
47%_ptr_Workgroup__arr_v4int_uint_4 = OpTypePointer Workgroup %_arr_v4int_uint_4
48%src_workgroup = OpVariable %_ptr_Workgroup__arr_v4int_uint_4 Workgroup
49 %S = OpTypeStruct %_arr_v4int_uint_4
Stephen White863d9ed2022-09-02 19:19:10 +000050%src_uniform_block = OpTypeStruct %S
51%_ptr_Uniform_src_uniform_block = OpTypePointer Uniform %src_uniform_block
52%src_uniform = OpVariable %_ptr_Uniform_src_uniform_block Uniform
53%_ptr_StorageBuffer_src_uniform_block = OpTypePointer StorageBuffer %src_uniform_block
54%src_storage = OpVariable %_ptr_StorageBuffer_src_uniform_block StorageBuffer
James Pricef6e5cc02022-01-20 22:11:07 +000055 %dst = OpVariable %_ptr_Private__arr_v4int_uint_4 Private %8
James Price94ac0782021-06-02 17:23:03 +000056 %uint_2 = OpConstant %uint 2
57%_arr_int_uint_2 = OpTypeArray %int %uint_2
58 %uint_3 = OpConstant %uint 3
59%_arr__arr_int_uint_2_uint_3 = OpTypeArray %_arr_int_uint_2 %uint_3
60%_arr__arr__arr_int_uint_2_uint_3_uint_4 = OpTypeArray %_arr__arr_int_uint_2_uint_3 %uint_4
61%_ptr_Private__arr__arr__arr_int_uint_2_uint_3_uint_4 = OpTypePointer Private %_arr__arr__arr_int_uint_2_uint_3_uint_4
Stephen White863d9ed2022-09-02 19:19:10 +000062 %25 = OpConstantNull %_arr__arr__arr_int_uint_2_uint_3_uint_4
63 %dst_nested = OpVariable %_ptr_Private__arr__arr__arr_int_uint_2_uint_3_uint_4 Private %25
James Price94ac0782021-06-02 17:23:03 +000064 %void = OpTypeVoid
Stephen White863d9ed2022-09-02 19:19:10 +000065 %26 = OpTypeFunction %void
66 %30 = OpTypeFunction %_arr_v4int_uint_4
67 %33 = OpTypeFunction %S
68 %36 = OpConstantNull %S
69 %37 = OpTypeFunction %void %_arr_v4int_uint_4
James Pricef6e5cc02022-01-20 22:11:07 +000070%_ptr_Function__arr_v4int_uint_4 = OpTypePointer Function %_arr_v4int_uint_4
James Price94ac0782021-06-02 17:23:03 +000071 %int_1 = OpConstant %int 1
Stephen White863d9ed2022-09-02 19:19:10 +000072 %44 = OpConstantComposite %v4int %int_1 %int_1 %int_1 %int_1
James Price94ac0782021-06-02 17:23:03 +000073 %int_2 = OpConstant %int 2
Stephen White863d9ed2022-09-02 19:19:10 +000074 %46 = OpConstantComposite %v4int %int_2 %int_2 %int_2 %int_2
James Price94ac0782021-06-02 17:23:03 +000075 %int_3 = OpConstant %int 3
Stephen White863d9ed2022-09-02 19:19:10 +000076 %48 = OpConstantComposite %v4int %int_3 %int_3 %int_3 %int_3
77 %49 = OpConstantComposite %_arr_v4int_uint_4 %44 %46 %48 %48
James Price94ac0782021-06-02 17:23:03 +000078 %uint_0 = OpConstant %uint 0
James Pricef6e5cc02022-01-20 22:11:07 +000079%_ptr_Uniform__arr_v4int_uint_4 = OpTypePointer Uniform %_arr_v4int_uint_4
80%_ptr_StorageBuffer__arr_v4int_uint_4 = OpTypePointer StorageBuffer %_arr_v4int_uint_4
James Price94ac0782021-06-02 17:23:03 +000081%_ptr_Function__arr__arr__arr_int_uint_2_uint_3_uint_4 = OpTypePointer Function %_arr__arr__arr_int_uint_2_uint_3_uint_4
Stephen White863d9ed2022-09-02 19:19:10 +000082%unused_entry_point = OpFunction %void None %26
83 %29 = OpLabel
James Price94ac0782021-06-02 17:23:03 +000084 OpReturn
85 OpFunctionEnd
Stephen White863d9ed2022-09-02 19:19:10 +000086 %ret_arr = OpFunction %_arr_v4int_uint_4 None %30
87 %32 = OpLabel
James Pricef6e5cc02022-01-20 22:11:07 +000088 OpReturnValue %8
James Price94ac0782021-06-02 17:23:03 +000089 OpFunctionEnd
Stephen White863d9ed2022-09-02 19:19:10 +000090%ret_struct_arr = OpFunction %S None %33
91 %35 = OpLabel
92 OpReturnValue %36
James Price94ac0782021-06-02 17:23:03 +000093 OpFunctionEnd
Stephen White863d9ed2022-09-02 19:19:10 +000094 %foo = OpFunction %void None %37
James Pricef6e5cc02022-01-20 22:11:07 +000095 %src_param = OpFunctionParameter %_arr_v4int_uint_4
Stephen White863d9ed2022-09-02 19:19:10 +000096 %40 = OpLabel
James Pricef6e5cc02022-01-20 22:11:07 +000097%src_function = OpVariable %_ptr_Function__arr_v4int_uint_4 Function %8
Stephen White863d9ed2022-09-02 19:19:10 +000098 %src_nested = OpVariable %_ptr_Function__arr__arr__arr_int_uint_2_uint_3_uint_4 Function %25
James Pricef6e5cc02022-01-20 22:11:07 +000099 OpStore %dst %49
Stephen White863d9ed2022-09-02 19:19:10 +0000100 OpStore %dst %src_param
101 %50 = OpFunctionCall %_arr_v4int_uint_4 %ret_arr
James Price94ac0782021-06-02 17:23:03 +0000102 OpStore %dst %50
Stephen White863d9ed2022-09-02 19:19:10 +0000103 OpStore %dst %8
104 %51 = OpLoad %_arr_v4int_uint_4 %src_function
James Pricef6e5cc02022-01-20 22:11:07 +0000105 OpStore %dst %51
Stephen White863d9ed2022-09-02 19:19:10 +0000106 %52 = OpLoad %_arr_v4int_uint_4 %src_private
James Pricef6e5cc02022-01-20 22:11:07 +0000107 OpStore %dst %52
Stephen White863d9ed2022-09-02 19:19:10 +0000108 %53 = OpLoad %_arr_v4int_uint_4 %src_workgroup
109 OpStore %dst %53
110 %54 = OpFunctionCall %S %ret_struct_arr
111 %55 = OpCompositeExtract %_arr_v4int_uint_4 %54 0
112 OpStore %dst %55
113 %58 = OpAccessChain %_ptr_Uniform__arr_v4int_uint_4 %src_uniform %uint_0 %uint_0
114 %59 = OpLoad %_arr_v4int_uint_4 %58
115 OpStore %dst %59
116 %61 = OpAccessChain %_ptr_StorageBuffer__arr_v4int_uint_4 %src_storage %uint_0 %uint_0
117 %62 = OpLoad %_arr_v4int_uint_4 %61
118 OpStore %dst %62
119 %65 = OpLoad %_arr__arr__arr_int_uint_2_uint_3_uint_4 %src_nested
120 OpStore %dst_nested %65
James Price94ac0782021-06-02 17:23:03 +0000121 OpReturn
122 OpFunctionEnd