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: 102
|
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_count_leading_zeros "tint_count_leading_zeros"
|
|
|
|
OpName %v "v"
|
|
|
|
OpName %x "x"
|
|
|
|
OpName %countLeadingZeros_ab6345 "countLeadingZeros_ab6345"
|
|
|
|
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
|
|
|
|
%v3uint = OpTypeVector %uint 3
|
2023-03-06 18:25:08 +00:00
|
|
|
%prevent_dce_block = OpTypeStruct %v3uint
|
|
|
|
%_ptr_StorageBuffer_prevent_dce_block = OpTypePointer StorageBuffer %prevent_dce_block
|
|
|
|
%prevent_dce = OpVariable %_ptr_StorageBuffer_prevent_dce_block StorageBuffer
|
|
|
|
%14 = OpTypeFunction %v3uint %v3uint
|
2022-06-02 14:36:10 +00:00
|
|
|
%_ptr_Function_v3uint = OpTypePointer Function %v3uint
|
2023-03-06 18:25:08 +00:00
|
|
|
%21 = OpConstantNull %v3uint
|
2022-06-02 14:36:10 +00:00
|
|
|
%uint_65535 = OpConstant %uint 65535
|
2023-03-06 18:25:08 +00:00
|
|
|
%25 = OpConstantComposite %v3uint %uint_65535 %uint_65535 %uint_65535
|
2022-06-02 14:36:10 +00:00
|
|
|
%bool = OpTypeBool
|
|
|
|
%v3bool = OpTypeVector %bool 3
|
|
|
|
%uint_16 = OpConstant %uint 16
|
2023-03-06 18:25:08 +00:00
|
|
|
%30 = OpConstantComposite %v3uint %uint_16 %uint_16 %uint_16
|
2022-06-02 14:36:10 +00:00
|
|
|
%uint_16777215 = OpConstant %uint 16777215
|
2023-03-06 18:25:08 +00:00
|
|
|
%36 = OpConstantComposite %v3uint %uint_16777215 %uint_16777215 %uint_16777215
|
2022-06-02 14:36:10 +00:00
|
|
|
%uint_8 = OpConstant %uint 8
|
2023-03-06 18:25:08 +00:00
|
|
|
%39 = OpConstantComposite %v3uint %uint_8 %uint_8 %uint_8
|
2022-06-02 14:36:10 +00:00
|
|
|
%uint_268435455 = OpConstant %uint 268435455
|
2023-03-06 18:25:08 +00:00
|
|
|
%45 = OpConstantComposite %v3uint %uint_268435455 %uint_268435455 %uint_268435455
|
2022-06-02 14:36:10 +00:00
|
|
|
%uint_4 = OpConstant %uint 4
|
2023-03-06 18:25:08 +00:00
|
|
|
%48 = OpConstantComposite %v3uint %uint_4 %uint_4 %uint_4
|
2022-06-02 14:36:10 +00:00
|
|
|
%uint_1073741823 = OpConstant %uint 1073741823
|
2023-03-06 18:25:08 +00:00
|
|
|
%54 = OpConstantComposite %v3uint %uint_1073741823 %uint_1073741823 %uint_1073741823
|
2022-06-02 14:36:10 +00:00
|
|
|
%uint_2 = OpConstant %uint 2
|
2023-03-06 18:25:08 +00:00
|
|
|
%57 = OpConstantComposite %v3uint %uint_2 %uint_2 %uint_2
|
2022-06-02 14:36:10 +00:00
|
|
|
%uint_2147483647 = OpConstant %uint 2147483647
|
2023-03-06 18:25:08 +00:00
|
|
|
%63 = OpConstantComposite %v3uint %uint_2147483647 %uint_2147483647 %uint_2147483647
|
2022-06-02 14:36:10 +00:00
|
|
|
%uint_1 = OpConstant %uint 1
|
2023-03-06 18:25:08 +00:00
|
|
|
%66 = OpConstantComposite %v3uint %uint_1 %uint_1 %uint_1
|
2022-06-02 14:36:10 +00:00
|
|
|
%void = OpTypeVoid
|
2023-03-06 18:25:08 +00:00
|
|
|
%76 = OpTypeFunction %void
|
|
|
|
%uint_0 = OpConstant %uint 0
|
|
|
|
%_ptr_StorageBuffer_v3uint = OpTypePointer StorageBuffer %v3uint
|
|
|
|
%88 = OpTypeFunction %v4float
|
2022-06-02 14:36:10 +00:00
|
|
|
%float_1 = OpConstant %float 1
|
2023-03-06 18:25:08 +00:00
|
|
|
%tint_count_leading_zeros = OpFunction %v3uint None %14
|
2022-06-02 14:36:10 +00:00
|
|
|
%v = OpFunctionParameter %v3uint
|
2023-03-06 18:25:08 +00:00
|
|
|
%17 = OpLabel
|
|
|
|
%x = OpVariable %_ptr_Function_v3uint Function %21
|
2022-06-02 14:36:10 +00:00
|
|
|
OpStore %x %v
|
2023-03-06 18:25:08 +00:00
|
|
|
%23 = OpLoad %v3uint %x
|
|
|
|
%26 = OpULessThanEqual %v3bool %23 %25
|
|
|
|
%22 = OpSelect %v3uint %26 %30 %21
|
2022-06-02 14:36:10 +00:00
|
|
|
%31 = OpLoad %v3uint %x
|
2023-03-06 18:25:08 +00:00
|
|
|
%32 = OpShiftLeftLogical %v3uint %31 %22
|
|
|
|
OpStore %x %32
|
|
|
|
%34 = OpLoad %v3uint %x
|
|
|
|
%37 = OpULessThanEqual %v3bool %34 %36
|
|
|
|
%33 = OpSelect %v3uint %37 %39 %21
|
2022-06-02 14:36:10 +00:00
|
|
|
%40 = OpLoad %v3uint %x
|
2023-03-06 18:25:08 +00:00
|
|
|
%41 = OpShiftLeftLogical %v3uint %40 %33
|
|
|
|
OpStore %x %41
|
|
|
|
%43 = OpLoad %v3uint %x
|
|
|
|
%46 = OpULessThanEqual %v3bool %43 %45
|
|
|
|
%42 = OpSelect %v3uint %46 %48 %21
|
2022-06-02 14:36:10 +00:00
|
|
|
%49 = OpLoad %v3uint %x
|
2023-03-06 18:25:08 +00:00
|
|
|
%50 = OpShiftLeftLogical %v3uint %49 %42
|
|
|
|
OpStore %x %50
|
|
|
|
%52 = OpLoad %v3uint %x
|
|
|
|
%55 = OpULessThanEqual %v3bool %52 %54
|
|
|
|
%51 = OpSelect %v3uint %55 %57 %21
|
2022-06-02 14:36:10 +00:00
|
|
|
%58 = OpLoad %v3uint %x
|
2023-03-06 18:25:08 +00:00
|
|
|
%59 = OpShiftLeftLogical %v3uint %58 %51
|
|
|
|
OpStore %x %59
|
|
|
|
%61 = OpLoad %v3uint %x
|
|
|
|
%64 = OpULessThanEqual %v3bool %61 %63
|
|
|
|
%60 = OpSelect %v3uint %64 %66 %21
|
|
|
|
%68 = OpLoad %v3uint %x
|
|
|
|
%69 = OpIEqual %v3bool %68 %21
|
|
|
|
%67 = OpSelect %v3uint %69 %66 %21
|
|
|
|
%71 = OpBitwiseOr %v3uint %22 %33
|
|
|
|
%72 = OpBitwiseOr %v3uint %71 %42
|
|
|
|
%73 = OpBitwiseOr %v3uint %72 %51
|
|
|
|
%74 = OpBitwiseOr %v3uint %73 %60
|
|
|
|
%75 = OpIAdd %v3uint %74 %67
|
|
|
|
OpReturnValue %75
|
2022-06-02 14:36:10 +00:00
|
|
|
OpFunctionEnd
|
2023-03-06 18:25:08 +00:00
|
|
|
%countLeadingZeros_ab6345 = OpFunction %void None %76
|
|
|
|
%79 = OpLabel
|
|
|
|
%arg_0 = OpVariable %_ptr_Function_v3uint Function %21
|
|
|
|
%res = OpVariable %_ptr_Function_v3uint Function %21
|
|
|
|
OpStore %arg_0 %66
|
|
|
|
%82 = OpLoad %v3uint %arg_0
|
|
|
|
%81 = OpFunctionCall %v3uint %tint_count_leading_zeros %82
|
|
|
|
OpStore %res %81
|
|
|
|
%86 = OpAccessChain %_ptr_StorageBuffer_v3uint %prevent_dce %uint_0
|
|
|
|
%87 = OpLoad %v3uint %res
|
|
|
|
OpStore %86 %87
|
2022-06-02 14:36:10 +00:00
|
|
|
OpReturn
|
|
|
|
OpFunctionEnd
|
2023-03-06 18:25:08 +00:00
|
|
|
%vertex_main_inner = OpFunction %v4float None %88
|
|
|
|
%90 = OpLabel
|
|
|
|
%91 = OpFunctionCall %void %countLeadingZeros_ab6345
|
2022-06-02 14:36:10 +00:00
|
|
|
OpReturnValue %5
|
|
|
|
OpFunctionEnd
|
2023-03-06 18:25:08 +00:00
|
|
|
%vertex_main = OpFunction %void None %76
|
|
|
|
%93 = OpLabel
|
|
|
|
%94 = OpFunctionCall %v4float %vertex_main_inner
|
|
|
|
OpStore %value %94
|
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 %76
|
|
|
|
%97 = OpLabel
|
|
|
|
%98 = OpFunctionCall %void %countLeadingZeros_ab6345
|
2022-06-02 14:36:10 +00:00
|
|
|
OpReturn
|
|
|
|
OpFunctionEnd
|
2023-03-06 18:25:08 +00:00
|
|
|
%compute_main = OpFunction %void None %76
|
|
|
|
%100 = OpLabel
|
|
|
|
%101 = OpFunctionCall %void %countLeadingZeros_ab6345
|
2022-06-02 14:36:10 +00:00
|
|
|
OpReturn
|
|
|
|
OpFunctionEnd
|