| 1 |
; SPIR-V |
| 2 |
; Version: 1.0 |
| 3 |
; Generator: Google spiregg; 0 |
| 4 |
; Bound: 39 |
| 5 |
; Schema: 0 |
| 6 |
OpCapability Shader |
| 7 |
OpMemoryModel Logical GLSL450 |
| 8 |
OpEntryPoint Vertex %vs_main "main" %gl_Position |
| 9 |
OpSource HLSL 600 |
| 10 |
OpName %vs_main "vs_main" |
| 11 |
OpDecorate %gl_Position BuiltIn Position |
| 12 |
%int = OpTypeInt 32 1 |
| 13 |
%int_0 = OpConstant %int 0 |
| 14 |
%int_2 = OpConstant %int 2 |
| 15 |
%float = OpTypeFloat 32 |
| 16 |
%float_0 = OpConstant %float 0 |
| 17 |
%int_1 = OpConstant %int 1 |
| 18 |
%float_3 = OpConstant %float 3 |
| 19 |
%uint = OpTypeInt 32 0 |
| 20 |
%uint_0 = OpConstant %uint 0 |
| 21 |
%v4float = OpTypeVector %float 4 |
| 22 |
%_ptr_Output_v4float = OpTypePointer Output %v4float |
| 23 |
%void = OpTypeVoid |
| 24 |
%15 = OpTypeFunction %void |
| 25 |
%uint_2 = OpConstant %uint 2 |
| 26 |
%_arr_float_uint_2 = OpTypeArray %float %uint_2 |
| 27 |
%_ptr_Function__arr_float_uint_2 = OpTypePointer Function %_arr_float_uint_2 |
| 28 |
%_ptr_Function_float = OpTypePointer Function %float |
| 29 |
%bool = OpTypeBool |
| 30 |
%gl_Position = OpVariable %_ptr_Output_v4float Output |
| 31 |
%21 = OpUndef %float |
| 32 |
%vs_main = OpFunction %void None %15 |
| 33 |
%22 = OpLabel |
| 34 |
%23 = OpVariable %_ptr_Function__arr_float_uint_2 Function |
| 35 |
OpBranch %24 |
| 36 |
%24 = OpLabel |
| 37 |
%25 = OpPhi %int %int_0 %22 %26 %27 |
| 38 |
%28 = OpSLessThan %bool %25 %int_2 |
| 39 |
OpLoopMerge %29 %27 None |
| 40 |
OpBranchConditional %28 %27 %29 |
| 41 |
%27 = OpLabel |
| 42 |
%30 = OpAccessChain %_ptr_Function_float %23 %25 |
| 43 |
OpStore %30 %float_0 |
| 44 |
%26 = OpIAdd %int %25 %int_1 |
| 45 |
OpBranch %24 |
| 46 |
%29 = OpLabel |
| 47 |
%31 = OpLoad %_arr_float_uint_2 %23 |
| 48 |
%32 = OpBitcast %uint %float_3 |
| 49 |
%33 = OpINotEqual %bool %32 %uint_0 |
| 50 |
OpSelectionMerge %34 None |
| 51 |
OpBranchConditional %33 %35 %34 |
| 52 |
%35 = OpLabel |
| 53 |
%36 = OpCompositeExtract %float %31 0 |
| 54 |
OpBranch %34 |
| 55 |
%34 = OpLabel |
| 56 |
%37 = OpPhi %float %21 %29 %36 %35 |
| 57 |
%38 = OpCompositeConstruct %v4float %float_0 %float_0 %float_0 %37 |
| 58 |
OpStore %gl_Position %38 |
| 59 |
OpReturn |
| 60 |
OpFunctionEnd |