|
| 1 | +; SPIR-V |
| 2 | +; Version: 1.0 |
| 3 | +; Generator: Khronos Glslang Reference Front End; 8 |
| 4 | +; Bound: 31 |
| 5 | +; Schema: 0 |
| 6 | + OpCapability Shader |
| 7 | + %1 = OpExtInstImport "GLSL.std.450" |
| 8 | + OpMemoryModel Logical GLSL450 |
| 9 | + OpEntryPoint GLCompute %main "main" |
| 10 | + OpExecutionMode %main LocalSize 1 1 1 |
| 11 | + OpSource GLSL 450 |
| 12 | + OpName %main "main" |
| 13 | + OpName %Foo "Foo" |
| 14 | + OpMemberName %Foo 0 "abs" |
| 15 | + OpName %f "f" |
| 16 | + OpName %Foo_0 "Foo" |
| 17 | + OpMemberName %Foo_0 0 "abs" |
| 18 | + OpName %SSBO "SSBO" |
| 19 | + OpMemberName %SSBO 0 "foo" |
| 20 | + OpMemberName %SSBO 1 "foo2" |
| 21 | + OpName %_ "" |
| 22 | + OpName %linear "abs" |
| 23 | + OpMemberDecorate %Foo_0 0 Offset 0 |
| 24 | + OpMemberDecorate %SSBO 0 Offset 0 |
| 25 | + OpMemberDecorate %SSBO 1 Offset 4 |
| 26 | + OpDecorate %SSBO BufferBlock |
| 27 | + OpDecorate %_ DescriptorSet 0 |
| 28 | + OpDecorate %_ Binding 0 |
| 29 | + %void = OpTypeVoid |
| 30 | + %3 = OpTypeFunction %void |
| 31 | + %float = OpTypeFloat 32 |
| 32 | + %Foo = OpTypeStruct %float |
| 33 | +%_ptr_Function_Foo = OpTypePointer Function %Foo |
| 34 | + %Foo_0 = OpTypeStruct %float |
| 35 | + %SSBO = OpTypeStruct %Foo_0 %Foo_0 |
| 36 | +%_ptr_Uniform_SSBO = OpTypePointer Uniform %SSBO |
| 37 | + %_ = OpVariable %_ptr_Uniform_SSBO Uniform |
| 38 | + %int = OpTypeInt 32 1 |
| 39 | + %int_0 = OpConstant %int 0 |
| 40 | +%_ptr_Uniform_Foo_0 = OpTypePointer Uniform %Foo_0 |
| 41 | +%_ptr_Function_float = OpTypePointer Function %float |
| 42 | +%_ptr_Function_int = OpTypePointer Function %int |
| 43 | + %int_10 = OpConstant %int 10 |
| 44 | + %int_1 = OpConstant %int 1 |
| 45 | +%_ptr_Uniform_float = OpTypePointer Uniform %float |
| 46 | + %main = OpFunction %void None %3 |
| 47 | + %5 = OpLabel |
| 48 | + %f = OpVariable %_ptr_Function_Foo Function |
| 49 | + %linear = OpVariable %_ptr_Function_int Function |
| 50 | + %17 = OpAccessChain %_ptr_Uniform_Foo_0 %_ %int_0 |
| 51 | + %18 = OpLoad %Foo_0 %17 |
| 52 | + %19 = OpCompositeExtract %float %18 0 |
| 53 | + %21 = OpAccessChain %_ptr_Function_float %f %int_0 |
| 54 | + OpStore %21 %19 |
| 55 | + OpStore %linear %int_10 |
| 56 | + %26 = OpLoad %Foo %f |
| 57 | + %27 = OpAccessChain %_ptr_Uniform_Foo_0 %_ %int_1 |
| 58 | + %28 = OpCompositeExtract %float %26 0 |
| 59 | + %30 = OpAccessChain %_ptr_Uniform_float %27 %int_0 |
| 60 | + OpStore %30 %28 |
| 61 | + OpReturn |
| 62 | + OpFunctionEnd |
0 commit comments