| ; SPIR-V | |
| ; Version: 1.3 | |
| ; Generator: Google Tint Compiler; 1 | |
| ; Bound: 29 | |
| ; Schema: 0 | |
| OpCapability Shader | |
| OpMemoryModel Logical GLSL450 | |
| OpEntryPoint GLCompute %main "main" | |
| OpExecutionMode %main LocalSize 1 1 1 | |
| OpName %deref "deref" | |
| OpName %a "a" | |
| OpName %a "p" | |
| OpName %no_deref "no_deref" | |
| OpName %a_0 "a" | |
| OpName %a_0 "p" | |
| OpName %main "main" | |
| %void = OpTypeVoid | |
| %3 = OpTypeFunction %void | |
| %int = OpTypeInt 32 1 | |
| %v3int = OpTypeVector %int 3 | |
| %_ptr_Function_v3int = OpTypePointer Function %v3int | |
| %9 = OpConstantNull %v3int | |
| %_ptr_Function_int = OpTypePointer Function %int | |
| %uint = OpTypeInt 32 0 | |
| %uint_0 = OpConstant %uint 0 | |
| %int_42 = OpConstant %int 42 | |
| %deref = OpFunction %void None %3 | |
| %4 = OpLabel | |
| %a = OpVariable %_ptr_Function_v3int Function %9 | |
| %10 = OpAccessChain %_ptr_Function_int %a %uint_0 | |
| %14 = OpLoad %int %10 None | |
| %15 = OpIAdd %int %14 %int_42 | |
| %17 = OpAccessChain %_ptr_Function_int %a %uint_0 | |
| OpStore %17 %15 None | |
| OpReturn | |
| OpFunctionEnd | |
| %no_deref = OpFunction %void None %3 | |
| %19 = OpLabel | |
| %a_0 = OpVariable %_ptr_Function_v3int Function %9 | |
| %21 = OpAccessChain %_ptr_Function_int %a_0 %uint_0 | |
| %22 = OpLoad %int %21 None | |
| %23 = OpIAdd %int %22 %int_42 | |
| %24 = OpAccessChain %_ptr_Function_int %a_0 %uint_0 | |
| OpStore %24 %23 None | |
| OpReturn | |
| OpFunctionEnd | |
| %main = OpFunction %void None %3 | |
| %26 = OpLabel | |
| %27 = OpFunctionCall %void %deref | |
| %28 = OpFunctionCall %void %no_deref | |
| OpReturn | |
| OpFunctionEnd |