2022-06-02 14:36:10 +00:00
|
|
|
; SPIR-V
|
|
|
|
; Version: 1.3
|
|
|
|
; Generator: Google Tint Compiler; 0
|
2023-03-06 18:25:08 +00:00
|
|
|
; Bound: 94
|
2022-06-02 14:36:10 +00:00
|
|
|
; Schema: 0
|
|
|
|
OpCapability Shader
|
|
|
|
OpMemoryModel Logical GLSL450
|
|
|
|
OpEntryPoint Vertex %vertex_main "vertex_main" %value %vertex_point_size
|
|
|
|
OpEntryPoint Fragment %fragment_main "fragment_main"
|
|
|
|
OpEntryPoint GLCompute %compute_main "compute_main"
|
|
|
|
OpExecutionMode %fragment_main OriginUpperLeft
|
|
|
|
OpExecutionMode %compute_main LocalSize 1 1 1
|
|
|
|
OpName %value "value"
|
|
|
|
OpName %vertex_point_size "vertex_point_size"
|
2023-03-06 18:25:08 +00:00
|
|
|
OpName %prevent_dce_block "prevent_dce_block"
|
|
|
|
OpMemberName %prevent_dce_block 0 "inner"
|
|
|
|
OpName %prevent_dce "prevent_dce"
|
2022-06-02 14:36:10 +00:00
|
|
|
OpName %tint_first_leading_bit "tint_first_leading_bit"
|
|
|
|
OpName %v "v"
|
|
|
|
OpName %x "x"
|
|
|
|
OpName %firstLeadingBit_f0779d "firstLeadingBit_f0779d"
|
|
|
|
OpName %arg_0 "arg_0"
|
|
|
|
OpName %res "res"
|
|
|
|
OpName %vertex_main_inner "vertex_main_inner"
|
|
|
|
OpName %vertex_main "vertex_main"
|
|
|
|
OpName %fragment_main "fragment_main"
|
|
|
|
OpName %compute_main "compute_main"
|
|
|
|
OpDecorate %value BuiltIn Position
|
|
|
|
OpDecorate %vertex_point_size BuiltIn PointSize
|
2023-03-06 18:25:08 +00:00
|
|
|
OpDecorate %prevent_dce_block Block
|
|
|
|
OpMemberDecorate %prevent_dce_block 0 Offset 0
|
|
|
|
OpDecorate %prevent_dce DescriptorSet 2
|
|
|
|
OpDecorate %prevent_dce Binding 0
|
2022-06-02 14:36:10 +00:00
|
|
|
%float = OpTypeFloat 32
|
|
|
|
%v4float = OpTypeVector %float 4
|
|
|
|
%_ptr_Output_v4float = OpTypePointer Output %v4float
|
|
|
|
%5 = OpConstantNull %v4float
|
|
|
|
%value = OpVariable %_ptr_Output_v4float Output %5
|
|
|
|
%_ptr_Output_float = OpTypePointer Output %float
|
|
|
|
%8 = OpConstantNull %float
|
|
|
|
%vertex_point_size = OpVariable %_ptr_Output_float Output %8
|
|
|
|
%uint = OpTypeInt 32 0
|
2023-03-06 18:25:08 +00:00
|
|
|
%prevent_dce_block = OpTypeStruct %uint
|
|
|
|
%_ptr_StorageBuffer_prevent_dce_block = OpTypePointer StorageBuffer %prevent_dce_block
|
|
|
|
%prevent_dce = OpVariable %_ptr_StorageBuffer_prevent_dce_block StorageBuffer
|
|
|
|
%13 = OpTypeFunction %uint %uint
|
2022-06-02 14:36:10 +00:00
|
|
|
%_ptr_Function_uint = OpTypePointer Function %uint
|
2023-03-06 18:25:08 +00:00
|
|
|
%19 = OpConstantNull %uint
|
2022-06-02 14:36:10 +00:00
|
|
|
%bool = OpTypeBool
|
|
|
|
%uint_4294901760 = OpConstant %uint 4294901760
|
|
|
|
%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_1 = OpConstant %uint 1
|
|
|
|
%uint_4294967295 = OpConstant %uint 4294967295
|
|
|
|
%void = OpTypeVoid
|
2023-03-06 18:25:08 +00:00
|
|
|
%68 = OpTypeFunction %void
|
|
|
|
%uint_0 = OpConstant %uint 0
|
|
|
|
%_ptr_StorageBuffer_uint = OpTypePointer StorageBuffer %uint
|
|
|
|
%80 = OpTypeFunction %v4float
|
2022-06-02 14:36:10 +00:00
|
|
|
%float_1 = OpConstant %float 1
|
2023-03-06 18:25:08 +00:00
|
|
|
%tint_first_leading_bit = OpFunction %uint None %13
|
2022-06-02 14:36:10 +00:00
|
|
|
%v = OpFunctionParameter %uint
|
2023-03-06 18:25:08 +00:00
|
|
|
%16 = OpLabel
|
|
|
|
%x = OpVariable %_ptr_Function_uint Function %19
|
2022-06-02 14:36:10 +00:00
|
|
|
OpStore %x %v
|
2023-03-06 18:25:08 +00:00
|
|
|
%23 = OpLoad %uint %x
|
|
|
|
%25 = OpBitwiseAnd %uint %23 %uint_4294901760
|
|
|
|
%21 = OpINotEqual %bool %25 %19
|
|
|
|
%20 = OpSelect %uint %21 %uint_16 %19
|
|
|
|
%27 = OpLoad %uint %x
|
|
|
|
%28 = OpShiftRightLogical %uint %27 %20
|
|
|
|
OpStore %x %28
|
|
|
|
%31 = OpLoad %uint %x
|
|
|
|
%33 = OpBitwiseAnd %uint %31 %uint_65280
|
|
|
|
%30 = OpINotEqual %bool %33 %19
|
|
|
|
%29 = OpSelect %uint %30 %uint_8 %19
|
|
|
|
%35 = OpLoad %uint %x
|
|
|
|
%36 = OpShiftRightLogical %uint %35 %29
|
|
|
|
OpStore %x %36
|
|
|
|
%39 = OpLoad %uint %x
|
|
|
|
%41 = OpBitwiseAnd %uint %39 %uint_240
|
|
|
|
%38 = OpINotEqual %bool %41 %19
|
|
|
|
%37 = OpSelect %uint %38 %uint_4 %19
|
|
|
|
%43 = OpLoad %uint %x
|
|
|
|
%44 = OpShiftRightLogical %uint %43 %37
|
|
|
|
OpStore %x %44
|
|
|
|
%47 = OpLoad %uint %x
|
|
|
|
%49 = OpBitwiseAnd %uint %47 %uint_12
|
|
|
|
%46 = OpINotEqual %bool %49 %19
|
|
|
|
%45 = OpSelect %uint %46 %uint_2 %19
|
|
|
|
%51 = OpLoad %uint %x
|
|
|
|
%52 = OpShiftRightLogical %uint %51 %45
|
|
|
|
OpStore %x %52
|
|
|
|
%55 = OpLoad %uint %x
|
|
|
|
%56 = OpBitwiseAnd %uint %55 %uint_2
|
|
|
|
%54 = OpINotEqual %bool %56 %19
|
|
|
|
%53 = OpSelect %uint %54 %uint_1 %19
|
|
|
|
%59 = OpLoad %uint %x
|
|
|
|
%60 = OpIEqual %bool %59 %19
|
|
|
|
%58 = OpSelect %uint %60 %uint_4294967295 %19
|
|
|
|
%63 = OpBitwiseOr %uint %20 %29
|
|
|
|
%64 = OpBitwiseOr %uint %63 %37
|
|
|
|
%65 = OpBitwiseOr %uint %64 %45
|
|
|
|
%66 = OpBitwiseOr %uint %65 %53
|
|
|
|
%67 = OpBitwiseOr %uint %66 %58
|
|
|
|
OpReturnValue %67
|
2022-06-02 14:36:10 +00:00
|
|
|
OpFunctionEnd
|
2023-03-06 18:25:08 +00:00
|
|
|
%firstLeadingBit_f0779d = OpFunction %void None %68
|
|
|
|
%71 = OpLabel
|
|
|
|
%arg_0 = OpVariable %_ptr_Function_uint Function %19
|
|
|
|
%res = OpVariable %_ptr_Function_uint Function %19
|
2022-06-02 14:36:10 +00:00
|
|
|
OpStore %arg_0 %uint_1
|
2023-03-06 18:25:08 +00:00
|
|
|
%74 = OpLoad %uint %arg_0
|
|
|
|
%73 = OpFunctionCall %uint %tint_first_leading_bit %74
|
|
|
|
OpStore %res %73
|
|
|
|
%78 = OpAccessChain %_ptr_StorageBuffer_uint %prevent_dce %uint_0
|
|
|
|
%79 = OpLoad %uint %res
|
|
|
|
OpStore %78 %79
|
2022-06-02 14:36:10 +00:00
|
|
|
OpReturn
|
|
|
|
OpFunctionEnd
|
2023-03-06 18:25:08 +00:00
|
|
|
%vertex_main_inner = OpFunction %v4float None %80
|
|
|
|
%82 = OpLabel
|
|
|
|
%83 = OpFunctionCall %void %firstLeadingBit_f0779d
|
2022-06-02 14:36:10 +00:00
|
|
|
OpReturnValue %5
|
|
|
|
OpFunctionEnd
|
2023-03-06 18:25:08 +00:00
|
|
|
%vertex_main = OpFunction %void None %68
|
|
|
|
%85 = OpLabel
|
|
|
|
%86 = OpFunctionCall %v4float %vertex_main_inner
|
|
|
|
OpStore %value %86
|
2022-06-02 14:36:10 +00:00
|
|
|
OpStore %vertex_point_size %float_1
|
|
|
|
OpReturn
|
|
|
|
OpFunctionEnd
|
2023-03-06 18:25:08 +00:00
|
|
|
%fragment_main = OpFunction %void None %68
|
|
|
|
%89 = OpLabel
|
|
|
|
%90 = OpFunctionCall %void %firstLeadingBit_f0779d
|
2022-06-02 14:36:10 +00:00
|
|
|
OpReturn
|
|
|
|
OpFunctionEnd
|
2023-03-06 18:25:08 +00:00
|
|
|
%compute_main = OpFunction %void None %68
|
|
|
|
%92 = OpLabel
|
|
|
|
%93 = OpFunctionCall %void %firstLeadingBit_f0779d
|
2022-06-02 14:36:10 +00:00
|
|
|
OpReturn
|
|
|
|
OpFunctionEnd
|