|
| 1 | +; SPIR-V |
| 2 | +; Version: 1.5 |
| 3 | +; Generator: Khronos Slang Compiler; 0 |
| 4 | +; Bound: 65 |
| 5 | +; Schema: 0 |
| 6 | + OpCapability StorageImageMultisample |
| 7 | + OpCapability Shader |
| 8 | + OpMemoryModel Logical GLSL450 |
| 9 | + OpEntryPoint Fragment %fs_main "main" %texture %entryPointParam_fs_main %gl_FragCoord |
| 10 | + OpExecutionMode %fs_main OriginUpperLeft |
| 11 | + OpSource Slang 1 |
| 12 | + OpName %index "index" |
| 13 | + OpName %index "index" |
| 14 | + OpName %color "color" |
| 15 | + OpName %color "color" |
| 16 | + OpName %color_0 "color" |
| 17 | + OpName %entryPointParam_fs_main "entryPointParam_fs_main" |
| 18 | + OpName %texture "texture" |
| 19 | + OpName %sampled "sampled" |
| 20 | + OpName %color_1 "color" |
| 21 | + OpName %fs_main "fs_main" |
| 22 | + OpDecorate %gl_FragCoord BuiltIn FragCoord |
| 23 | + OpDecorate %entryPointParam_fs_main Location 0 |
| 24 | + OpDecorate %texture Binding 0 |
| 25 | + OpDecorate %texture DescriptorSet 0 |
| 26 | + %void = OpTypeVoid |
| 27 | + %3 = OpTypeFunction %void |
| 28 | + %int = OpTypeInt 32 1 |
| 29 | +%_ptr_Function_int = OpTypePointer Function %int |
| 30 | + %float = OpTypeFloat 32 |
| 31 | + %v4float = OpTypeVector %float 4 |
| 32 | +%_ptr_Function_v4float = OpTypePointer Function %v4float |
| 33 | +%_ptr_Input_v4float = OpTypePointer Input %v4float |
| 34 | + %v2float = OpTypeVector %float 2 |
| 35 | + %v2int = OpTypeVector %int 2 |
| 36 | + %int_0 = OpConstant %int 0 |
| 37 | + %bool = OpTypeBool |
| 38 | + %int_8 = OpConstant %int 8 |
| 39 | +%_ptr_Output_v4float = OpTypePointer Output %v4float |
| 40 | + %45 = OpTypeImage %float 2D 2 0 1 1 Unknown |
| 41 | +%_ptr_UniformConstant_45 = OpTypePointer UniformConstant %45 |
| 42 | + %int_1 = OpConstant %int 1 |
| 43 | +%gl_FragCoord = OpVariable %_ptr_Input_v4float Input |
| 44 | +%entryPointParam_fs_main = OpVariable %_ptr_Output_v4float Output |
| 45 | + %texture = OpVariable %_ptr_UniformConstant_45 UniformConstant |
| 46 | +%float_0_125 = OpConstant %float 0.125 |
| 47 | + %64 = OpConstantComposite %v4float %float_0_125 %float_0_125 %float_0_125 %float_0_125 |
| 48 | + %fs_main = OpFunction %void None %3 |
| 49 | + %4 = OpLabel |
| 50 | + %index = OpVariable %_ptr_Function_int Function |
| 51 | + %color = OpVariable %_ptr_Function_v4float Function |
| 52 | + %22 = OpLoad %v4float %gl_FragCoord |
| 53 | + %26 = OpVectorShuffle %v2float %22 %22 0 1 |
| 54 | + %28 = OpConvertFToS %v2int %26 |
| 55 | + OpStore %index %int_0 |
| 56 | + OpBranch %12 |
| 57 | + %12 = OpLabel |
| 58 | + OpLoopMerge %17 %21 None |
| 59 | + OpBranch %13 |
| 60 | + %13 = OpLabel |
| 61 | + OpBranch %14 |
| 62 | + %14 = OpLabel |
| 63 | + OpBranch %15 |
| 64 | + %15 = OpLabel |
| 65 | + %31 = OpLoad %int %index |
| 66 | + %33 = OpSLessThan %bool %31 %int_8 |
| 67 | + OpSelectionMerge %18 None |
| 68 | + OpBranchConditional %33 %18 %16 |
| 69 | + %16 = OpLabel |
| 70 | + OpBranch %17 |
| 71 | + %18 = OpLabel |
| 72 | + %46 = OpLoad %45 %texture |
| 73 | + %49 = OpLoad %int %index |
| 74 | + %sampled = OpImageFetch %v4float %46 %28 Sample %49 |
| 75 | + %52 = OpLoad %v4float %color |
| 76 | + %color_1 = OpFAdd %v4float %52 %sampled |
| 77 | + OpBranch %19 |
| 78 | + %19 = OpLabel |
| 79 | + OpBranch %20 |
| 80 | + %20 = OpLabel |
| 81 | + %56 = OpLoad %int %index |
| 82 | + %57 = OpIAdd %int %56 %int_1 |
| 83 | + OpStore %index %57 |
| 84 | + OpStore %color %color_1 |
| 85 | + OpBranch %21 |
| 86 | + %21 = OpLabel |
| 87 | + OpBranch %12 |
| 88 | + %17 = OpLabel |
| 89 | + %37 = OpLoad %v4float %color |
| 90 | + %color_0 = OpFMul %v4float %37 %64 |
| 91 | + OpStore %entryPointParam_fs_main %color_0 |
| 92 | + OpReturn |
| 93 | + OpFunctionEnd |
0 commit comments