xref: /aosp_15_r20/external/skia/tests/sksl/blend/BlendLighten.asm.frag (revision c8dee2aa9b3f27cf6c858bd81872bdeb2c07ed17)
1               OpCapability Shader
2          %1 = OpExtInstImport "GLSL.std.450"
3               OpMemoryModel Logical GLSL450
4               OpEntryPoint Fragment %main "main" %sk_FragColor
5               OpExecutionMode %main OriginUpperLeft
6               OpName %sk_FragColor "sk_FragColor"
7               OpName %_UniformBuffer "_UniformBuffer"
8               OpMemberName %_UniformBuffer 0 "src"
9               OpMemberName %_UniformBuffer 1 "dst"
10               OpName %main "main"
11               OpName %_0_result "_0_result"
12               OpDecorate %sk_FragColor RelaxedPrecision
13               OpDecorate %sk_FragColor Location 0
14               OpDecorate %sk_FragColor Index 0
15               OpMemberDecorate %_UniformBuffer 0 Offset 0
16               OpMemberDecorate %_UniformBuffer 0 RelaxedPrecision
17               OpMemberDecorate %_UniformBuffer 1 Offset 16
18               OpMemberDecorate %_UniformBuffer 1 RelaxedPrecision
19               OpDecorate %_UniformBuffer Block
20               OpDecorate %7 Binding 0
21               OpDecorate %7 DescriptorSet 0
22               OpDecorate %_0_result RelaxedPrecision
23               OpDecorate %19 RelaxedPrecision
24               OpDecorate %22 RelaxedPrecision
25               OpDecorate %23 RelaxedPrecision
26               OpDecorate %24 RelaxedPrecision
27               OpDecorate %27 RelaxedPrecision
28               OpDecorate %28 RelaxedPrecision
29               OpDecorate %29 RelaxedPrecision
30               OpDecorate %31 RelaxedPrecision
31               OpDecorate %34 RelaxedPrecision
32               OpDecorate %35 RelaxedPrecision
33               OpDecorate %36 RelaxedPrecision
34               OpDecorate %38 RelaxedPrecision
35               OpDecorate %39 RelaxedPrecision
36               OpDecorate %40 RelaxedPrecision
37               OpDecorate %42 RelaxedPrecision
38               OpDecorate %43 RelaxedPrecision
39               OpDecorate %44 RelaxedPrecision
40               OpDecorate %45 RelaxedPrecision
41               OpDecorate %46 RelaxedPrecision
42      %float = OpTypeFloat 32
43    %v4float = OpTypeVector %float 4
44%_ptr_Output_v4float = OpTypePointer Output %v4float
45%sk_FragColor = OpVariable %_ptr_Output_v4float Output
46%_UniformBuffer = OpTypeStruct %v4float %v4float
47%_ptr_Uniform__UniformBuffer = OpTypePointer Uniform %_UniformBuffer
48          %7 = OpVariable %_ptr_Uniform__UniformBuffer Uniform
49       %void = OpTypeVoid
50         %11 = OpTypeFunction %void
51%_ptr_Function_v4float = OpTypePointer Function %v4float
52%_ptr_Uniform_v4float = OpTypePointer Uniform %v4float
53        %int = OpTypeInt 32 1
54      %int_0 = OpConstant %int 0
55    %float_1 = OpConstant %float 1
56      %int_1 = OpConstant %int 1
57    %v3float = OpTypeVector %float 3
58       %main = OpFunction %void None %11
59         %12 = OpLabel
60  %_0_result = OpVariable %_ptr_Function_v4float Function
61         %15 = OpAccessChain %_ptr_Uniform_v4float %7 %int_0
62         %19 = OpLoad %v4float %15
63         %21 = OpAccessChain %_ptr_Uniform_v4float %7 %int_0
64         %22 = OpLoad %v4float %21
65         %23 = OpCompositeExtract %float %22 3
66         %24 = OpFSub %float %float_1 %23
67         %25 = OpAccessChain %_ptr_Uniform_v4float %7 %int_1
68         %27 = OpLoad %v4float %25
69         %28 = OpVectorTimesScalar %v4float %27 %24
70         %29 = OpFAdd %v4float %19 %28
71               OpStore %_0_result %29
72         %31 = OpVectorShuffle %v3float %29 %29 0 1 2
73         %33 = OpAccessChain %_ptr_Uniform_v4float %7 %int_1
74         %34 = OpLoad %v4float %33
75         %35 = OpCompositeExtract %float %34 3
76         %36 = OpFSub %float %float_1 %35
77         %37 = OpAccessChain %_ptr_Uniform_v4float %7 %int_0
78         %38 = OpLoad %v4float %37
79         %39 = OpVectorShuffle %v3float %38 %38 0 1 2
80         %40 = OpVectorTimesScalar %v3float %39 %36
81         %41 = OpAccessChain %_ptr_Uniform_v4float %7 %int_1
82         %42 = OpLoad %v4float %41
83         %43 = OpVectorShuffle %v3float %42 %42 0 1 2
84         %44 = OpFAdd %v3float %40 %43
85         %30 = OpExtInst %v3float %1 FMax %31 %44
86         %45 = OpLoad %v4float %_0_result
87         %46 = OpVectorShuffle %v4float %45 %30 4 5 6 3
88               OpStore %_0_result %46
89               OpStore %sk_FragColor %46
90               OpReturn
91               OpFunctionEnd
92