| ; |
| ; fragment_main |
| ; |
| ; SPIR-V |
| ; Version: 1.3 |
| ; Generator: Google Tint Compiler; 1 |
| ; Bound: 57 |
| ; Schema: 0 |
| OpCapability Shader |
| OpMemoryModel Logical GLSL450 |
| OpEntryPoint Fragment %fragment_main "fragment_main" |
| OpExecutionMode %fragment_main OriginUpperLeft |
| OpMemberName %prevent_dce_block 0 "inner" |
| OpName %prevent_dce_block "prevent_dce_block" |
| OpName %firstLeadingBit_f0779d "firstLeadingBit_f0779d" |
| OpName %arg_0 "arg_0" |
| OpName %res "res" |
| OpName %fragment_main "fragment_main" |
| OpMemberDecorate %prevent_dce_block 0 Offset 0 |
| OpDecorate %prevent_dce_block Block |
| OpDecorate %1 DescriptorSet 0 |
| OpDecorate %1 Binding 0 |
| OpDecorate %1 Coherent |
| %uint = OpTypeInt 32 0 |
| %prevent_dce_block = OpTypeStruct %uint |
| %_ptr_StorageBuffer_prevent_dce_block = OpTypePointer StorageBuffer %prevent_dce_block |
| %1 = OpVariable %_ptr_StorageBuffer_prevent_dce_block StorageBuffer |
| %6 = OpTypeFunction %uint |
| %_ptr_Function_uint = OpTypePointer Function %uint |
| %uint_1 = OpConstant %uint 1 |
| %uint_4294901760 = OpConstant %uint 4294901760 |
| %uint_0 = OpConstant %uint 0 |
| %bool = OpTypeBool |
| %uint_16 = OpConstant %uint 16 |
| %uint_65280 = OpConstant %uint 65280 |
| %uint_8 = OpConstant %uint 8 |
| %uint_240 = OpConstant %uint 240 |
| %uint_4 = OpConstant %uint 4 |
| %uint_12 = OpConstant %uint 12 |
| %uint_2 = OpConstant %uint 2 |
| %uint_4294967295 = OpConstant %uint 4294967295 |
| %void = OpTypeVoid |
| %52 = OpTypeFunction %void |
| %_ptr_StorageBuffer_uint = OpTypePointer StorageBuffer %uint |
| %firstLeadingBit_f0779d = OpFunction %uint None %6 |
| %7 = OpLabel |
| %arg_0 = OpVariable %_ptr_Function_uint Function |
| %res = OpVariable %_ptr_Function_uint Function |
| OpStore %arg_0 %uint_1 |
| %11 = OpLoad %uint %arg_0 None |
| %12 = OpBitwiseAnd %uint %11 %uint_4294901760 |
| %14 = OpIEqual %bool %12 %uint_0 |
| %17 = OpSelect %uint %14 %uint_0 %uint_16 |
| %19 = OpShiftRightLogical %uint %11 %17 |
| %20 = OpBitwiseAnd %uint %19 %uint_65280 |
| %22 = OpIEqual %bool %20 %uint_0 |
| %23 = OpSelect %uint %22 %uint_0 %uint_8 |
| %25 = OpShiftRightLogical %uint %19 %23 |
| %26 = OpBitwiseAnd %uint %25 %uint_240 |
| %28 = OpIEqual %bool %26 %uint_0 |
| %29 = OpSelect %uint %28 %uint_0 %uint_4 |
| %31 = OpShiftRightLogical %uint %25 %29 |
| %32 = OpBitwiseAnd %uint %31 %uint_12 |
| %34 = OpIEqual %bool %32 %uint_0 |
| %35 = OpSelect %uint %34 %uint_0 %uint_2 |
| %37 = OpShiftRightLogical %uint %31 %35 |
| %38 = OpBitwiseAnd %uint %37 %uint_2 |
| %39 = OpIEqual %bool %38 %uint_0 |
| %40 = OpSelect %uint %39 %uint_0 %uint_1 |
| %41 = OpBitwiseOr %uint %35 %40 |
| %42 = OpBitwiseOr %uint %29 %41 |
| %43 = OpBitwiseOr %uint %23 %42 |
| %44 = OpBitwiseOr %uint %17 %43 |
| %45 = OpIEqual %bool %37 %uint_0 |
| %46 = OpSelect %uint %45 %uint_4294967295 %44 |
| OpStore %res %46 |
| %49 = OpLoad %uint %res None |
| OpReturnValue %49 |
| OpFunctionEnd |
| %fragment_main = OpFunction %void None %52 |
| %53 = OpLabel |
| %54 = OpFunctionCall %uint %firstLeadingBit_f0779d |
| %55 = OpAccessChain %_ptr_StorageBuffer_uint %1 %uint_0 |
| OpStore %55 %54 None |
| OpReturn |
| OpFunctionEnd |
| ; |
| ; compute_main |
| ; |
| ; SPIR-V |
| ; Version: 1.3 |
| ; Generator: Google Tint Compiler; 1 |
| ; Bound: 57 |
| ; Schema: 0 |
| OpCapability Shader |
| OpMemoryModel Logical GLSL450 |
| OpEntryPoint GLCompute %compute_main "compute_main" |
| OpExecutionMode %compute_main LocalSize 1 1 1 |
| OpMemberName %prevent_dce_block 0 "inner" |
| OpName %prevent_dce_block "prevent_dce_block" |
| OpName %firstLeadingBit_f0779d "firstLeadingBit_f0779d" |
| OpName %arg_0 "arg_0" |
| OpName %res "res" |
| OpName %compute_main "compute_main" |
| OpMemberDecorate %prevent_dce_block 0 Offset 0 |
| OpDecorate %prevent_dce_block Block |
| OpDecorate %1 DescriptorSet 0 |
| OpDecorate %1 Binding 0 |
| OpDecorate %1 Coherent |
| %uint = OpTypeInt 32 0 |
| %prevent_dce_block = OpTypeStruct %uint |
| %_ptr_StorageBuffer_prevent_dce_block = OpTypePointer StorageBuffer %prevent_dce_block |
| %1 = OpVariable %_ptr_StorageBuffer_prevent_dce_block StorageBuffer |
| %6 = OpTypeFunction %uint |
| %_ptr_Function_uint = OpTypePointer Function %uint |
| %uint_1 = OpConstant %uint 1 |
| %uint_4294901760 = OpConstant %uint 4294901760 |
| %uint_0 = OpConstant %uint 0 |
| %bool = OpTypeBool |
| %uint_16 = OpConstant %uint 16 |
| %uint_65280 = OpConstant %uint 65280 |
| %uint_8 = OpConstant %uint 8 |
| %uint_240 = OpConstant %uint 240 |
| %uint_4 = OpConstant %uint 4 |
| %uint_12 = OpConstant %uint 12 |
| %uint_2 = OpConstant %uint 2 |
| %uint_4294967295 = OpConstant %uint 4294967295 |
| %void = OpTypeVoid |
| %52 = OpTypeFunction %void |
| %_ptr_StorageBuffer_uint = OpTypePointer StorageBuffer %uint |
| %firstLeadingBit_f0779d = OpFunction %uint None %6 |
| %7 = OpLabel |
| %arg_0 = OpVariable %_ptr_Function_uint Function |
| %res = OpVariable %_ptr_Function_uint Function |
| OpStore %arg_0 %uint_1 |
| %11 = OpLoad %uint %arg_0 None |
| %12 = OpBitwiseAnd %uint %11 %uint_4294901760 |
| %14 = OpIEqual %bool %12 %uint_0 |
| %17 = OpSelect %uint %14 %uint_0 %uint_16 |
| %19 = OpShiftRightLogical %uint %11 %17 |
| %20 = OpBitwiseAnd %uint %19 %uint_65280 |
| %22 = OpIEqual %bool %20 %uint_0 |
| %23 = OpSelect %uint %22 %uint_0 %uint_8 |
| %25 = OpShiftRightLogical %uint %19 %23 |
| %26 = OpBitwiseAnd %uint %25 %uint_240 |
| %28 = OpIEqual %bool %26 %uint_0 |
| %29 = OpSelect %uint %28 %uint_0 %uint_4 |
| %31 = OpShiftRightLogical %uint %25 %29 |
| %32 = OpBitwiseAnd %uint %31 %uint_12 |
| %34 = OpIEqual %bool %32 %uint_0 |
| %35 = OpSelect %uint %34 %uint_0 %uint_2 |
| %37 = OpShiftRightLogical %uint %31 %35 |
| %38 = OpBitwiseAnd %uint %37 %uint_2 |
| %39 = OpIEqual %bool %38 %uint_0 |
| %40 = OpSelect %uint %39 %uint_0 %uint_1 |
| %41 = OpBitwiseOr %uint %35 %40 |
| %42 = OpBitwiseOr %uint %29 %41 |
| %43 = OpBitwiseOr %uint %23 %42 |
| %44 = OpBitwiseOr %uint %17 %43 |
| %45 = OpIEqual %bool %37 %uint_0 |
| %46 = OpSelect %uint %45 %uint_4294967295 %44 |
| OpStore %res %46 |
| %49 = OpLoad %uint %res None |
| OpReturnValue %49 |
| OpFunctionEnd |
| %compute_main = OpFunction %void None %52 |
| %53 = OpLabel |
| %54 = OpFunctionCall %uint %firstLeadingBit_f0779d |
| %55 = OpAccessChain %_ptr_StorageBuffer_uint %1 %uint_0 |
| OpStore %55 %54 None |
| OpReturn |
| OpFunctionEnd |
| ; |
| ; vertex_main |
| ; |
| ; SPIR-V |
| ; Version: 1.3 |
| ; Generator: Google Tint Compiler; 1 |
| ; Bound: 76 |
| ; Schema: 0 |
| OpCapability Shader |
| OpMemoryModel Logical GLSL450 |
| OpEntryPoint Vertex %vertex_main "vertex_main" %vertex_main_position_Output %vertex_main_loc0_Output %vertex_main___point_size_Output |
| OpName %vertex_main_position_Output "vertex_main_position_Output" |
| OpName %vertex_main_loc0_Output "vertex_main_loc0_Output" |
| OpName %vertex_main___point_size_Output "vertex_main___point_size_Output" |
| OpName %firstLeadingBit_f0779d "firstLeadingBit_f0779d" |
| OpName %arg_0 "arg_0" |
| OpName %res "res" |
| OpName %vertex_main_inner "vertex_main_inner" |
| OpMemberName %VertexOutput 0 "pos" |
| OpMemberName %VertexOutput 1 "prevent_dce" |
| OpName %VertexOutput "VertexOutput" |
| OpName %out "out" |
| OpName %vertex_main "vertex_main" |
| OpDecorate %vertex_main_position_Output BuiltIn Position |
| OpDecorate %vertex_main_loc0_Output Location 0 |
| OpDecorate %vertex_main_loc0_Output Flat |
| OpDecorate %vertex_main___point_size_Output BuiltIn PointSize |
| %float = OpTypeFloat 32 |
| %v4float = OpTypeVector %float 4 |
| %_ptr_Output_v4float = OpTypePointer Output %v4float |
| %vertex_main_position_Output = OpVariable %_ptr_Output_v4float Output |
| %uint = OpTypeInt 32 0 |
| %_ptr_Output_uint = OpTypePointer Output %uint |
| %vertex_main_loc0_Output = OpVariable %_ptr_Output_uint Output |
| %_ptr_Output_float = OpTypePointer Output %float |
| %vertex_main___point_size_Output = OpVariable %_ptr_Output_float Output |
| %11 = OpTypeFunction %uint |
| %_ptr_Function_uint = OpTypePointer Function %uint |
| %uint_1 = OpConstant %uint 1 |
| %uint_4294901760 = OpConstant %uint 4294901760 |
| %uint_0 = OpConstant %uint 0 |
| %bool = OpTypeBool |
| %uint_16 = OpConstant %uint 16 |
| %uint_65280 = OpConstant %uint 65280 |
| %uint_8 = OpConstant %uint 8 |
| %uint_240 = OpConstant %uint 240 |
| %uint_4 = OpConstant %uint 4 |
| %uint_12 = OpConstant %uint 12 |
| %uint_2 = OpConstant %uint 2 |
| %uint_4294967295 = OpConstant %uint 4294967295 |
| %VertexOutput = OpTypeStruct %v4float %uint |
| %57 = OpTypeFunction %VertexOutput |
| %_ptr_Function_VertexOutput = OpTypePointer Function %VertexOutput |
| %61 = OpConstantNull %VertexOutput |
| %_ptr_Function_v4float = OpTypePointer Function %v4float |
| %64 = OpConstantNull %v4float |
| %void = OpTypeVoid |
| %70 = OpTypeFunction %void |
| %float_1 = OpConstant %float 1 |
| %firstLeadingBit_f0779d = OpFunction %uint None %11 |
| %12 = OpLabel |
| %arg_0 = OpVariable %_ptr_Function_uint Function |
| %res = OpVariable %_ptr_Function_uint Function |
| OpStore %arg_0 %uint_1 |
| %16 = OpLoad %uint %arg_0 None |
| %17 = OpBitwiseAnd %uint %16 %uint_4294901760 |
| %19 = OpIEqual %bool %17 %uint_0 |
| %22 = OpSelect %uint %19 %uint_0 %uint_16 |
| %24 = OpShiftRightLogical %uint %16 %22 |
| %25 = OpBitwiseAnd %uint %24 %uint_65280 |
| %27 = OpIEqual %bool %25 %uint_0 |
| %28 = OpSelect %uint %27 %uint_0 %uint_8 |
| %30 = OpShiftRightLogical %uint %24 %28 |
| %31 = OpBitwiseAnd %uint %30 %uint_240 |
| %33 = OpIEqual %bool %31 %uint_0 |
| %34 = OpSelect %uint %33 %uint_0 %uint_4 |
| %36 = OpShiftRightLogical %uint %30 %34 |
| %37 = OpBitwiseAnd %uint %36 %uint_12 |
| %39 = OpIEqual %bool %37 %uint_0 |
| %40 = OpSelect %uint %39 %uint_0 %uint_2 |
| %42 = OpShiftRightLogical %uint %36 %40 |
| %43 = OpBitwiseAnd %uint %42 %uint_2 |
| %44 = OpIEqual %bool %43 %uint_0 |
| %45 = OpSelect %uint %44 %uint_0 %uint_1 |
| %46 = OpBitwiseOr %uint %40 %45 |
| %47 = OpBitwiseOr %uint %34 %46 |
| %48 = OpBitwiseOr %uint %28 %47 |
| %49 = OpBitwiseOr %uint %22 %48 |
| %50 = OpIEqual %bool %42 %uint_0 |
| %51 = OpSelect %uint %50 %uint_4294967295 %49 |
| OpStore %res %51 |
| %54 = OpLoad %uint %res None |
| OpReturnValue %54 |
| OpFunctionEnd |
| %vertex_main_inner = OpFunction %VertexOutput None %57 |
| %58 = OpLabel |
| %out = OpVariable %_ptr_Function_VertexOutput Function %61 |
| %62 = OpAccessChain %_ptr_Function_v4float %out %uint_0 |
| OpStore %62 %64 None |
| %65 = OpAccessChain %_ptr_Function_uint %out %uint_1 |
| %66 = OpFunctionCall %uint %firstLeadingBit_f0779d |
| OpStore %65 %66 None |
| %67 = OpLoad %VertexOutput %out None |
| OpReturnValue %67 |
| OpFunctionEnd |
| %vertex_main = OpFunction %void None %70 |
| %71 = OpLabel |
| %72 = OpFunctionCall %VertexOutput %vertex_main_inner |
| %73 = OpCompositeExtract %v4float %72 0 |
| OpStore %vertex_main_position_Output %73 None |
| %74 = OpCompositeExtract %uint %72 1 |
| OpStore %vertex_main_loc0_Output %74 None |
| OpStore %vertex_main___point_size_Output %float_1 None |
| OpReturn |
| OpFunctionEnd |