Antonio Maiorano | 08d9279 | 2024-01-11 20:51:50 +0000 | [diff] [blame] | 1 | ; SPIR-V |
| 2 | ; Version: 1.3 |
| 3 | ; Generator: Google Tint Compiler; 0 |
| 4 | ; Bound: 62 |
| 5 | ; Schema: 0 |
| 6 | OpCapability Shader |
| 7 | OpMemoryModel Logical GLSL450 |
| 8 | OpEntryPoint GLCompute %main "main" |
| 9 | OpExecutionMode %main LocalSize 1 1 1 |
| 10 | OpName %deref_const "deref_const" |
| 11 | OpName %a "a" |
| 12 | OpName %b "b" |
| 13 | OpName %no_deref_const "no_deref_const" |
| 14 | OpName %a_0 "a" |
| 15 | OpName %b_0 "b" |
| 16 | OpName %deref_let "deref_let" |
| 17 | OpName %a_1 "a" |
| 18 | OpName %b_1 "b" |
| 19 | OpName %no_deref_let "no_deref_let" |
| 20 | OpName %a_2 "a" |
| 21 | OpName %b_2 "b" |
| 22 | OpName %deref_var "deref_var" |
| 23 | OpName %a_3 "a" |
| 24 | OpName %i "i" |
| 25 | OpName %b_3 "b" |
| 26 | OpName %no_deref_var "no_deref_var" |
| 27 | OpName %a_4 "a" |
| 28 | OpName %b_4 "b" |
| 29 | OpName %main "main" |
| 30 | %void = OpTypeVoid |
| 31 | %1 = OpTypeFunction %void |
| 32 | %int = OpTypeInt 32 1 |
| 33 | %v3int = OpTypeVector %int 3 |
| 34 | %_ptr_Function_v3int = OpTypePointer Function %v3int |
| 35 | %9 = OpConstantNull %v3int |
| 36 | %10 = OpConstantNull %int |
| 37 | %_ptr_Function_int = OpTypePointer Function %int |
| 38 | %int_42 = OpConstant %int 42 |
| 39 | %deref_const = OpFunction %void None %1 |
| 40 | %4 = OpLabel |
| 41 | %a = OpVariable %_ptr_Function_v3int Function %9 |
| 42 | %b = OpVariable %_ptr_Function_int Function %10 |
| 43 | %12 = OpAccessChain %_ptr_Function_int %a %10 |
| 44 | %13 = OpLoad %int %12 |
| 45 | OpStore %b %13 |
| 46 | %15 = OpAccessChain %_ptr_Function_int %a %10 |
| 47 | OpStore %15 %int_42 |
| 48 | OpReturn |
| 49 | OpFunctionEnd |
| 50 | %no_deref_const = OpFunction %void None %1 |
| 51 | %18 = OpLabel |
| 52 | %a_0 = OpVariable %_ptr_Function_v3int Function %9 |
| 53 | %b_0 = OpVariable %_ptr_Function_int Function %10 |
| 54 | %20 = OpAccessChain %_ptr_Function_int %a_0 %10 |
| 55 | %21 = OpLoad %int %20 |
| 56 | OpStore %b_0 %21 |
| 57 | %23 = OpAccessChain %_ptr_Function_int %a_0 %10 |
| 58 | OpStore %23 %int_42 |
| 59 | OpReturn |
| 60 | OpFunctionEnd |
| 61 | %deref_let = OpFunction %void None %1 |
| 62 | %25 = OpLabel |
| 63 | %a_1 = OpVariable %_ptr_Function_v3int Function %9 |
| 64 | %b_1 = OpVariable %_ptr_Function_int Function %10 |
| 65 | %27 = OpAccessChain %_ptr_Function_int %a_1 %10 |
| 66 | %28 = OpLoad %int %27 |
| 67 | OpStore %b_1 %28 |
| 68 | %30 = OpAccessChain %_ptr_Function_int %a_1 %10 |
| 69 | OpStore %30 %int_42 |
| 70 | OpReturn |
| 71 | OpFunctionEnd |
| 72 | %no_deref_let = OpFunction %void None %1 |
| 73 | %32 = OpLabel |
| 74 | %a_2 = OpVariable %_ptr_Function_v3int Function %9 |
| 75 | %b_2 = OpVariable %_ptr_Function_int Function %10 |
| 76 | %34 = OpAccessChain %_ptr_Function_int %a_2 %10 |
| 77 | %35 = OpLoad %int %34 |
| 78 | OpStore %b_2 %35 |
| 79 | %37 = OpAccessChain %_ptr_Function_int %a_2 %10 |
| 80 | OpStore %37 %int_42 |
| 81 | OpReturn |
| 82 | OpFunctionEnd |
| 83 | %deref_var = OpFunction %void None %1 |
| 84 | %39 = OpLabel |
| 85 | %a_3 = OpVariable %_ptr_Function_v3int Function %9 |
| 86 | %i = OpVariable %_ptr_Function_int Function %10 |
| 87 | %b_3 = OpVariable %_ptr_Function_int Function %10 |
| 88 | OpStore %i %10 |
| 89 | %42 = OpLoad %int %i |
| 90 | %43 = OpAccessChain %_ptr_Function_int %a_3 %42 |
| 91 | %44 = OpLoad %int %43 |
| 92 | OpStore %b_3 %44 |
| 93 | %46 = OpAccessChain %_ptr_Function_int %a_3 %10 |
| 94 | OpStore %46 %int_42 |
| 95 | OpReturn |
| 96 | OpFunctionEnd |
| 97 | %no_deref_var = OpFunction %void None %1 |
| 98 | %48 = OpLabel |
| 99 | %a_4 = OpVariable %_ptr_Function_v3int Function %9 |
| 100 | %b_4 = OpVariable %_ptr_Function_int Function %10 |
| 101 | %50 = OpAccessChain %_ptr_Function_int %a_4 %10 |
| 102 | %51 = OpLoad %int %50 |
| 103 | OpStore %b_4 %51 |
| 104 | %53 = OpAccessChain %_ptr_Function_int %a_4 %10 |
| 105 | OpStore %53 %int_42 |
| 106 | OpReturn |
| 107 | OpFunctionEnd |
| 108 | %main = OpFunction %void None %1 |
| 109 | %55 = OpLabel |
| 110 | %56 = OpFunctionCall %void %deref_const |
| 111 | %57 = OpFunctionCall %void %no_deref_const |
| 112 | %58 = OpFunctionCall %void %deref_let |
| 113 | %59 = OpFunctionCall %void %no_deref_let |
| 114 | %60 = OpFunctionCall %void %deref_var |
| 115 | %61 = OpFunctionCall %void %no_deref_var |
| 116 | OpReturn |
| 117 | OpFunctionEnd |