diff --git a/ci/licenses_golden/licenses_flutter b/ci/licenses_golden/licenses_flutter index 5f46b12511dea..b52c469b2f816 100644 --- a/ci/licenses_golden/licenses_flutter +++ b/ci/licenses_golden/licenses_flutter @@ -40372,8 +40372,6 @@ ORIGIN: ../../../flutter/impeller/entity/render_target_cache.cc + ../../../flutt ORIGIN: ../../../flutter/impeller/entity/render_target_cache.h + ../../../flutter/LICENSE ORIGIN: ../../../flutter/impeller/entity/shaders/blending/advanced_blend.frag + ../../../flutter/LICENSE ORIGIN: ../../../flutter/impeller/entity/shaders/blending/advanced_blend.vert + ../../../flutter/LICENSE -ORIGIN: ../../../flutter/impeller/entity/shaders/blending/blend.frag + ../../../flutter/LICENSE -ORIGIN: ../../../flutter/impeller/entity/shaders/blending/blend.vert + ../../../flutter/LICENSE ORIGIN: ../../../flutter/impeller/entity/shaders/blending/blend_select.glsl + ../../../flutter/LICENSE ORIGIN: ../../../flutter/impeller/entity/shaders/blending/framebuffer_blend.frag + ../../../flutter/LICENSE ORIGIN: ../../../flutter/impeller/entity/shaders/blending/framebuffer_blend.vert + ../../../flutter/LICENSE @@ -40418,7 +40416,6 @@ ORIGIN: ../../../flutter/impeller/entity/shaders/solid_fill.frag + ../../../flut ORIGIN: ../../../flutter/impeller/entity/shaders/solid_fill.vert + ../../../flutter/LICENSE ORIGIN: ../../../flutter/impeller/entity/shaders/texture_fill.frag + ../../../flutter/LICENSE ORIGIN: ../../../flutter/impeller/entity/shaders/texture_fill.vert + ../../../flutter/LICENSE -ORIGIN: ../../../flutter/impeller/entity/shaders/texture_fill_external.frag + ../../../flutter/LICENSE ORIGIN: ../../../flutter/impeller/entity/shaders/texture_fill_strict_src.frag + ../../../flutter/LICENSE ORIGIN: ../../../flutter/impeller/entity/shaders/tiled_texture_fill.frag + ../../../flutter/LICENSE ORIGIN: ../../../flutter/impeller/entity/shaders/tiled_texture_fill_external.frag + ../../../flutter/LICENSE @@ -43255,8 +43252,6 @@ FILE: ../../../flutter/impeller/entity/render_target_cache.cc FILE: ../../../flutter/impeller/entity/render_target_cache.h FILE: ../../../flutter/impeller/entity/shaders/blending/advanced_blend.frag FILE: ../../../flutter/impeller/entity/shaders/blending/advanced_blend.vert -FILE: ../../../flutter/impeller/entity/shaders/blending/blend.frag -FILE: ../../../flutter/impeller/entity/shaders/blending/blend.vert FILE: ../../../flutter/impeller/entity/shaders/blending/blend_select.glsl FILE: ../../../flutter/impeller/entity/shaders/blending/framebuffer_blend.frag FILE: ../../../flutter/impeller/entity/shaders/blending/framebuffer_blend.vert @@ -43301,7 +43296,6 @@ FILE: ../../../flutter/impeller/entity/shaders/solid_fill.frag FILE: ../../../flutter/impeller/entity/shaders/solid_fill.vert FILE: ../../../flutter/impeller/entity/shaders/texture_fill.frag FILE: ../../../flutter/impeller/entity/shaders/texture_fill.vert -FILE: ../../../flutter/impeller/entity/shaders/texture_fill_external.frag FILE: ../../../flutter/impeller/entity/shaders/texture_fill_strict_src.frag FILE: ../../../flutter/impeller/entity/shaders/tiled_texture_fill.frag FILE: ../../../flutter/impeller/entity/shaders/tiled_texture_fill_external.frag diff --git a/impeller/entity/BUILD.gn b/impeller/entity/BUILD.gn index d2c3428fd1a59..42d0a32a3f244 100644 --- a/impeller/entity/BUILD.gn +++ b/impeller/entity/BUILD.gn @@ -16,8 +16,6 @@ impeller_shaders("entity_shaders") { shaders = [ "shaders/blending/advanced_blend.vert", "shaders/blending/advanced_blend.frag", - "shaders/blending/blend.frag", - "shaders/blending/blend.vert", "shaders/border_mask_blur.frag", "shaders/border_mask_blur.vert", "shaders/clip.frag", @@ -41,10 +39,9 @@ impeller_shaders("entity_shaders") { "shaders/gradients/sweep_gradient_fill.frag", "shaders/texture_fill.frag", "shaders/texture_fill.vert", - "shaders/texture_fill_external.frag", - "shaders/texture_fill_strict_src.frag", "shaders/tiled_texture_fill.frag", "shaders/tiled_texture_fill_external.frag", + "shaders/texture_fill_strict_src.frag", "shaders/vertices.frag", "shaders/blending/porter_duff_blend.frag", "shaders/blending/porter_duff_blend.vert", diff --git a/impeller/entity/contents/atlas_contents.cc b/impeller/entity/contents/atlas_contents.cc index 9e01411f56a76..f8171692f2d8b 100644 --- a/impeller/entity/contents/atlas_contents.cc +++ b/impeller/entity/contents/atlas_contents.cc @@ -405,12 +405,16 @@ bool AtlasTextureContents::Render(const ContentContext& renderer, VS::FrameInfo frame_info; frame_info.mvp = entity.GetShaderTransform(pass); frame_info.texture_sampler_y_coord_scale = texture->GetYCoordScale(); - frame_info.alpha = alpha_; auto options = OptionsFromPassAndEntity(pass, entity); pass.SetPipeline(renderer.GetTexturePipeline(options)); pass.SetVertexBuffer(vertex_builder.CreateVertexBuffer(host_buffer)); VS::BindFrameInfo(pass, host_buffer.EmplaceUniform(frame_info)); + + FS::FragInfo frag_info; + frag_info.alpha = alpha_; + + FS::BindFragInfo(pass, host_buffer.EmplaceUniform(frag_info)); FS::BindTextureSampler(pass, texture, renderer.GetContext()->GetSamplerLibrary()->GetSampler( parent_.GetSamplerDescriptor())); diff --git a/impeller/entity/contents/content_context.cc b/impeller/entity/contents/content_context.cc index 1a7a8a9b026f0..bd3e05c135f6a 100644 --- a/impeller/entity/contents/content_context.cc +++ b/impeller/entity/contents/content_context.cc @@ -421,7 +421,6 @@ ContentContext::ContentContext( {static_cast(BlendSelectValues::kSoftLight), supports_decal}); rrect_blur_pipelines_.CreateDefault(*context_, options_trianglestrip); - texture_blend_pipelines_.CreateDefault(*context_, options); texture_strict_src_pipelines_.CreateDefault(*context_, options); position_uv_pipelines_.CreateDefault(*context_, options); tiled_texture_pipelines_.CreateDefault(*context_, options); @@ -448,9 +447,6 @@ ContentContext::ContentContext( {supports_decal}); // GLES only shader that is unsupported on macOS. #if defined(IMPELLER_ENABLE_OPENGLES) && !defined(FML_OS_MACOSX) - if (GetContext()->GetBackendType() == Context::BackendType::kOpenGLES) { - texture_external_pipelines_.CreateDefault(*context_, options); - } if (GetContext()->GetBackendType() == Context::BackendType::kOpenGLES) { tiled_texture_external_pipelines_.CreateDefault(*context_, options); } diff --git a/impeller/entity/contents/content_context.h b/impeller/entity/contents/content_context.h index bd4dfb7ad3d47..361cd6650dc2e 100644 --- a/impeller/entity/contents/content_context.h +++ b/impeller/entity/contents/content_context.h @@ -29,8 +29,6 @@ #include "impeller/entity/checkerboard.vert.h" #endif // IMPELLER_DEBUG -#include "impeller/entity/blend.frag.h" -#include "impeller/entity/blend.vert.h" #include "impeller/entity/border_mask_blur.frag.h" #include "impeller/entity/border_mask_blur.vert.h" #include "impeller/entity/clip.frag.h" @@ -84,7 +82,6 @@ #include "impeller/entity/framebuffer_blend.vert.h" #ifdef IMPELLER_ENABLE_OPENGLES -#include "impeller/entity/texture_fill_external.frag.h" #include "impeller/entity/tiled_texture_fill_external.frag.h" #endif // IMPELLER_ENABLE_OPENGLES @@ -127,8 +124,6 @@ using SweepGradientSSBOFillPipeline = SweepGradientSsboFillFragmentShader>; using RRectBlurPipeline = RenderPipelineHandle; -using BlendPipeline = - RenderPipelineHandle; using TexturePipeline = RenderPipelineHandle; using TextureStrictSrcPipeline = @@ -261,10 +256,6 @@ using PointsComputeShaderPipeline = ComputePipelineBuilder; using UvComputeShaderPipeline = ComputePipelineBuilder; #ifdef IMPELLER_ENABLE_OPENGLES -using TextureExternalPipeline = - RenderPipelineHandle; - using TiledTextureExternalPipeline = RenderPipelineHandle; @@ -468,11 +459,6 @@ class ContentContext { return GetPipeline(solid_fill_pipelines_, opts); } - std::shared_ptr> GetBlendPipeline( - ContentContextOptions opts) const { - return GetPipeline(texture_blend_pipelines_, opts); - } - std::shared_ptr> GetTexturePipeline( ContentContextOptions opts) const { return GetPipeline(texture_pipelines_, opts); @@ -484,13 +470,6 @@ class ContentContext { } #ifdef IMPELLER_ENABLE_OPENGLES - std::shared_ptr> GetTextureExternalPipeline( - ContentContextOptions opts) const { - FML_DCHECK(GetContext()->GetBackendType() == - Context::BackendType::kOpenGLES); - return GetPipeline(texture_external_pipelines_, opts); - } - std::shared_ptr> GetTiledTextureExternalPipeline( ContentContextOptions opts) const { FML_DCHECK(GetContext()->GetBackendType() == @@ -947,11 +926,9 @@ class ContentContext { mutable Variants sweep_gradient_ssbo_fill_pipelines_; mutable Variants rrect_blur_pipelines_; - mutable Variants texture_blend_pipelines_; mutable Variants texture_pipelines_; mutable Variants texture_strict_src_pipelines_; #ifdef IMPELLER_ENABLE_OPENGLES - mutable Variants texture_external_pipelines_; mutable Variants tiled_texture_external_pipelines_; #endif // IMPELLER_ENABLE_OPENGLES diff --git a/impeller/entity/contents/filters/blend_filter_contents.cc b/impeller/entity/contents/filters/blend_filter_contents.cc index 93550da403e4c..3497c5bdd8e80 100644 --- a/impeller/entity/contents/filters/blend_filter_contents.cc +++ b/impeller/entity/contents/filters/blend_filter_contents.cc @@ -505,8 +505,8 @@ static std::optional PipelineBlend( std::optional foreground_color, ColorFilterContents::AbsorbOpacity absorb_opacity, std::optional alpha) { - using VS = BlendPipeline::VertexShader; - using FS = BlendPipeline::FragmentShader; + using VS = TexturePipeline::VertexShader; + using FS = TexturePipeline::FragmentShader; auto dst_snapshot = inputs[0]->GetSnapshot("PipelineBlend(Dst)", renderer, entity); @@ -552,7 +552,7 @@ static std::optional PipelineBlend( const std::unique_ptr& sampler = renderer.GetContext()->GetSamplerLibrary()->GetSampler( input->sampler_descriptor); - FS::BindTextureSamplerSrc(pass, input->texture, sampler); + FS::BindTextureSampler(pass, input->texture, sampler); auto size = input->texture->GetSize(); VertexBufferBuilder vtx_builder; @@ -572,7 +572,7 @@ static std::optional PipelineBlend( input->texture->GetYCoordScale(); FS::FragInfo frag_info; - frag_info.input_alpha = + frag_info.alpha = absorb_opacity == ColorFilterContents::AbsorbOpacity::kYes ? input->opacity : 1.0; @@ -584,7 +584,7 @@ static std::optional PipelineBlend( // Draw the first texture using kSource. options.blend_mode = BlendMode::kSource; - pass.SetPipeline(renderer.GetBlendPipeline(options)); + pass.SetPipeline(renderer.GetTexturePipeline(options)); if (!add_blend_command(dst_snapshot)) { return true; } @@ -593,7 +593,7 @@ static std::optional PipelineBlend( if (inputs.size() >= 2) { options.blend_mode = blend_mode; - pass.SetPipeline(renderer.GetBlendPipeline(options)); + pass.SetPipeline(renderer.GetTexturePipeline(options)); for (auto texture_i = inputs.begin() + 1; texture_i < inputs.end(); texture_i++) { diff --git a/impeller/entity/contents/filters/gaussian_blur_filter_contents.cc b/impeller/entity/contents/filters/gaussian_blur_filter_contents.cc index 3d324233b5e4d..9ac17dff218bc 100644 --- a/impeller/entity/contents/filters/gaussian_blur_filter_contents.cc +++ b/impeller/entity/contents/filters/gaussian_blur_filter_contents.cc @@ -95,7 +95,9 @@ fml::StatusOr MakeDownsampleSubpass( TextureFillVertexShader::FrameInfo frame_info; frame_info.mvp = Matrix::MakeOrthographic(ISize(1, 1)); frame_info.texture_sampler_y_coord_scale = 1.0; - frame_info.alpha = 1.0; + + TextureFillFragmentShader::FragInfo frag_info; + frag_info.alpha = 1.0; BindVertices(pass, host_buffer, { @@ -111,6 +113,8 @@ fml::StatusOr MakeDownsampleSubpass( linear_sampler_descriptor.min_filter = MinMagFilter::kLinear; TextureFillVertexShader::BindFrameInfo( pass, host_buffer.EmplaceUniform(frame_info)); + TextureFillFragmentShader::BindFragInfo( + pass, host_buffer.EmplaceUniform(frag_info)); TextureFillFragmentShader::BindTextureSampler( pass, input_texture, renderer.GetContext()->GetSamplerLibrary()->GetSampler( diff --git a/impeller/entity/contents/texture_contents.cc b/impeller/entity/contents/texture_contents.cc index f2f10207bf4be..d48b4b6eaace2 100644 --- a/impeller/entity/contents/texture_contents.cc +++ b/impeller/entity/contents/texture_contents.cc @@ -13,7 +13,8 @@ #include "impeller/entity/entity.h" #include "impeller/entity/texture_fill.frag.h" #include "impeller/entity/texture_fill.vert.h" -#include "impeller/entity/texture_fill_external.frag.h" +#include "impeller/entity/texture_fill_strict_src.frag.h" +#include "impeller/entity/tiled_texture_fill_external.frag.h" #include "impeller/geometry/constants.h" #include "impeller/renderer/render_pass.h" #include "impeller/renderer/vertex_buffer_builder.h" @@ -113,8 +114,8 @@ bool TextureContents::Render(const ContentContext& renderer, using VS = TextureFillVertexShader; using FS = TextureFillFragmentShader; - using FSStrictSrc = TextureFillStrictSrcFragmentShader; - using FSExternal = TextureFillExternalFragmentShader; + using FSExternal = TiledTextureFillExternalFragmentShader; + using FSStrict = TextureFillStrictSrcFragmentShader; if (destination_rect_.IsEmpty() || source_rect_.IsEmpty() || texture_ == nullptr || texture_->GetSize().IsEmpty()) { @@ -129,7 +130,6 @@ bool TextureContents::Render(const ContentContext& renderer, Rect::MakeSize(texture_->GetSize()).Project(source_rect); VertexBufferBuilder vertex_builder; - auto destination_rect = capture.AddRect("Destination rect", destination_rect_); vertex_builder.AddVertices({ @@ -144,7 +144,6 @@ bool TextureContents::Render(const ContentContext& renderer, VS::FrameInfo frame_info; frame_info.mvp = entity.GetShaderTransform(pass); frame_info.texture_sampler_y_coord_scale = texture_->GetYCoordScale(); - frame_info.alpha = capture.AddScalar("Alpha", GetOpacity()); #ifdef IMPELLER_DEBUG if (label_.empty()) { @@ -163,7 +162,7 @@ bool TextureContents::Render(const ContentContext& renderer, std::shared_ptr> pipeline; #ifdef IMPELLER_ENABLE_OPENGLES if (is_external_texture) { - pipeline = renderer.GetTextureExternalPipeline(pipeline_options); + pipeline = renderer.GetTiledTextureExternalPipeline(pipeline_options); } #endif // IMPELLER_ENABLE_OPENGLES @@ -178,11 +177,27 @@ bool TextureContents::Render(const ContentContext& renderer, pass.SetVertexBuffer(vertex_builder.CreateVertexBuffer(host_buffer)); VS::BindFrameInfo(pass, host_buffer.EmplaceUniform(frame_info)); + if (is_external_texture) { + FSExternal::FragInfo frag_info; + frag_info.x_tile_mode = + static_cast(sampler_descriptor_.width_address_mode); + frag_info.y_tile_mode = + static_cast(sampler_descriptor_.height_address_mode); + frag_info.alpha = capture.AddScalar("Alpha", GetOpacity()); + + auto sampler_descriptor = sampler_descriptor_; + // OES_EGL_image_external states that only CLAMP_TO_EDGE is valid, so + // we emulate all other tile modes here by remapping the texture + // coordinates. + sampler_descriptor.width_address_mode = SamplerAddressMode::kClampToEdge; + sampler_descriptor.height_address_mode = SamplerAddressMode::kClampToEdge; + + FSExternal::BindFragInfo(pass, host_buffer.EmplaceUniform((frag_info))); FSExternal::BindSAMPLEREXTERNALOESTextureSampler( pass, texture_, renderer.GetContext()->GetSamplerLibrary()->GetSampler( - sampler_descriptor_)); + sampler_descriptor)); } else if (strict_source_rect_enabled_) { // For a strict source rect, shrink the texture coordinate range by half a // texel to ensure that linear filtering does not sample anything outside @@ -190,14 +205,18 @@ bool TextureContents::Render(const ContentContext& renderer, auto strict_texture_coords = Rect::MakeSize(texture_->GetSize()).Project(source_rect.Expand(-0.5)); - FSStrictSrc::FragInfo frag_info; + FSStrict::FragInfo frag_info; frag_info.source_rect = Vector4(strict_texture_coords.GetLTRB()); - FSStrictSrc::BindFragInfo(pass, host_buffer.EmplaceUniform(frag_info)); - FSStrictSrc::BindTextureSampler( + frag_info.alpha = capture.AddScalar("Alpha", GetOpacity()); + FSStrict::BindFragInfo(pass, host_buffer.EmplaceUniform((frag_info))); + FSStrict::BindTextureSampler( pass, texture_, renderer.GetContext()->GetSamplerLibrary()->GetSampler( sampler_descriptor_)); } else { + FS::FragInfo frag_info; + frag_info.alpha = capture.AddScalar("Alpha", GetOpacity()); + FS::BindFragInfo(pass, host_buffer.EmplaceUniform((frag_info))); FS::BindTextureSampler( pass, texture_, renderer.GetContext()->GetSamplerLibrary()->GetSampler( diff --git a/impeller/entity/contents/tiled_texture_contents.cc b/impeller/entity/contents/tiled_texture_contents.cc index b8baa2fef8f92..de6497033a307 100644 --- a/impeller/entity/contents/tiled_texture_contents.cc +++ b/impeller/entity/contents/tiled_texture_contents.cc @@ -6,6 +6,7 @@ #include "fml/logging.h" #include "impeller/entity/contents/content_context.h" +#include "impeller/entity/texture_fill.frag.h" #include "impeller/entity/texture_fill.vert.h" #include "impeller/entity/tiled_texture_fill.frag.h" #include "impeller/entity/tiled_texture_fill_external.frag.h" @@ -132,7 +133,6 @@ bool TiledTextureContents::Render(const ContentContext& renderer, VS::FrameInfo frame_info; frame_info.texture_sampler_y_coord_scale = texture_->GetYCoordScale(); - frame_info.alpha = GetOpacityFactor(); PipelineBuilderMethod pipeline_method; @@ -170,12 +170,19 @@ bool TiledTextureContents::Render(const ContentContext& renderer, FSExternal::FragInfo frag_info; frag_info.x_tile_mode = static_cast(x_tile_mode_); frag_info.y_tile_mode = static_cast(y_tile_mode_); + frag_info.alpha = GetOpacityFactor(); FSExternal::BindFragInfo(pass, host_buffer.EmplaceUniform(frag_info)); } else if (uses_emulated_tile_mode) { FS::FragInfo frag_info; frag_info.x_tile_mode = static_cast(x_tile_mode_); frag_info.y_tile_mode = static_cast(y_tile_mode_); + frag_info.alpha = GetOpacityFactor(); FS::BindFragInfo(pass, host_buffer.EmplaceUniform(frag_info)); + } else { + TextureFillFragmentShader::FragInfo frag_info; + frag_info.alpha = GetOpacityFactor(); + TextureFillFragmentShader::BindFragInfo( + pass, host_buffer.EmplaceUniform(frag_info)); } if (is_external_texture) { diff --git a/impeller/entity/contents/vertices_contents.cc b/impeller/entity/contents/vertices_contents.cc index 2db730e4e815a..9aeaa83023b83 100644 --- a/impeller/entity/contents/vertices_contents.cc +++ b/impeller/entity/contents/vertices_contents.cc @@ -169,9 +169,11 @@ bool VerticesUVContents::Render(const ContentContext& renderer, frame_info.mvp = geometry_result.transform; frame_info.texture_sampler_y_coord_scale = snapshot->texture->GetYCoordScale(); - frame_info.alpha = alpha_ * snapshot->opacity; VS::BindFrameInfo(pass, host_buffer.EmplaceUniform(frame_info)); + FS::FragInfo frag_info; + frag_info.alpha = alpha_ * snapshot->opacity; + FS::BindFragInfo(pass, host_buffer.EmplaceUniform(frag_info)); FS::BindTextureSampler(pass, snapshot->texture, renderer.GetContext()->GetSamplerLibrary()->GetSampler( snapshot->sampler_descriptor)); diff --git a/impeller/entity/shaders/blending/blend.frag b/impeller/entity/shaders/blending/blend.frag deleted file mode 100644 index d8eb5b806f894..0000000000000 --- a/impeller/entity/shaders/blending/blend.frag +++ /dev/null @@ -1,24 +0,0 @@ -// Copyright 2013 The Flutter Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -precision mediump float; - -#include -#include - -uniform f16sampler2D texture_sampler_src; - -uniform FragInfo { - float16_t input_alpha; -} -frag_info; - -in vec2 v_texture_coords; - -out f16vec4 frag_color; - -void main() { - frag_color = - texture(texture_sampler_src, v_texture_coords) * frag_info.input_alpha; -} diff --git a/impeller/entity/shaders/blending/blend.vert b/impeller/entity/shaders/blending/blend.vert deleted file mode 100644 index f8a08ecee3b37..0000000000000 --- a/impeller/entity/shaders/blending/blend.vert +++ /dev/null @@ -1,23 +0,0 @@ -// Copyright 2013 The Flutter Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#include -#include - -uniform FrameInfo { - mat4 mvp; - float texture_sampler_y_coord_scale; -} -frame_info; - -in vec2 vertices; -in vec2 texture_coords; - -out vec2 v_texture_coords; - -void main() { - gl_Position = frame_info.mvp * vec4(vertices, 0.0, 1.0); - v_texture_coords = - IPRemapCoords(texture_coords, frame_info.texture_sampler_y_coord_scale); -} diff --git a/impeller/entity/shaders/texture_fill.frag b/impeller/entity/shaders/texture_fill.frag index 9bebdeb53973b..bd9dbd30c374e 100644 --- a/impeller/entity/shaders/texture_fill.frag +++ b/impeller/entity/shaders/texture_fill.frag @@ -9,13 +9,17 @@ precision mediump float; uniform f16sampler2D texture_sampler; +uniform FragInfo { + float alpha; +} +frag_info; + in highp vec2 v_texture_coords; -IMPELLER_MAYBE_FLAT in float16_t v_alpha; out f16vec4 frag_color; void main() { f16vec4 sampled = texture(texture_sampler, v_texture_coords, float16_t(kDefaultMipBias)); - frag_color = sampled * v_alpha; + frag_color = sampled * float16_t(frag_info.alpha); } diff --git a/impeller/entity/shaders/texture_fill.vert b/impeller/entity/shaders/texture_fill.vert index baf56360fe72b..0dbc6fd4bfad4 100644 --- a/impeller/entity/shaders/texture_fill.vert +++ b/impeller/entity/shaders/texture_fill.vert @@ -8,7 +8,6 @@ uniform FrameInfo { mat4 mvp; float texture_sampler_y_coord_scale; - float16_t alpha; } frame_info; @@ -16,11 +15,9 @@ in vec2 position; in vec2 texture_coords; out vec2 v_texture_coords; -IMPELLER_MAYBE_FLAT out mediump float16_t v_alpha; void main() { gl_Position = frame_info.mvp * vec4(position, 0.0, 1.0); - v_alpha = frame_info.alpha; v_texture_coords = IPRemapCoords(texture_coords, frame_info.texture_sampler_y_coord_scale); } diff --git a/impeller/entity/shaders/texture_fill_external.frag b/impeller/entity/shaders/texture_fill_external.frag deleted file mode 100644 index b402c113eb950..0000000000000 --- a/impeller/entity/shaders/texture_fill_external.frag +++ /dev/null @@ -1,16 +0,0 @@ -// Copyright 2013 The Flutter Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -uniform sampler2D SAMPLER_EXTERNAL_OES_texture_sampler; - -in vec2 v_texture_coords; -in float v_alpha; - -out vec4 frag_color; - -void main() { - vec4 sampled = - texture(SAMPLER_EXTERNAL_OES_texture_sampler, v_texture_coords); - frag_color = sampled * v_alpha; -} diff --git a/impeller/entity/shaders/texture_fill_strict_src.frag b/impeller/entity/shaders/texture_fill_strict_src.frag index 6381598be8f25..0165250b8a968 100644 --- a/impeller/entity/shaders/texture_fill_strict_src.frag +++ b/impeller/entity/shaders/texture_fill_strict_src.frag @@ -11,11 +11,11 @@ uniform f16sampler2D texture_sampler; uniform FragInfo { vec4 source_rect; + float alpha; } frag_info; in highp vec2 v_texture_coords; -IMPELLER_MAYBE_FLAT in float16_t v_alpha; out f16vec4 frag_color; @@ -26,5 +26,5 @@ void main() { frag_info.source_rect.w)); f16vec4 sampled = texture(texture_sampler, texture_coords, float16_t(kDefaultMipBias)); - frag_color = sampled * v_alpha; + frag_color = sampled * float16_t(frag_info.alpha); } diff --git a/impeller/entity/shaders/tiled_texture_fill.frag b/impeller/entity/shaders/tiled_texture_fill.frag index 5e8413ef98f9c..747bb646dac3d 100644 --- a/impeller/entity/shaders/tiled_texture_fill.frag +++ b/impeller/entity/shaders/tiled_texture_fill.frag @@ -10,22 +10,22 @@ precision mediump float; uniform f16sampler2D texture_sampler; uniform FragInfo { - float16_t x_tile_mode; - float16_t y_tile_mode; + float x_tile_mode; + float y_tile_mode; + float alpha; } frag_info; in highp vec2 v_texture_coords; -IMPELLER_MAYBE_FLAT in float16_t v_alpha; out f16vec4 frag_color; void main() { frag_color = - IPHalfSampleWithTileMode(texture_sampler, // sampler - v_texture_coords, // texture coordinates - frag_info.x_tile_mode, // x tile mode - frag_info.y_tile_mode // y tile mode + IPHalfSampleWithTileMode(texture_sampler, // sampler + v_texture_coords, // texture coordinates + float16_t(frag_info.x_tile_mode), // x tile mode + float16_t(frag_info.y_tile_mode) // y tile mode ) * - v_alpha; + float16_t(frag_info.alpha); } diff --git a/impeller/entity/shaders/tiled_texture_fill_external.frag b/impeller/entity/shaders/tiled_texture_fill_external.frag index b0ece73193b66..7d744553ab066 100644 --- a/impeller/entity/shaders/tiled_texture_fill_external.frag +++ b/impeller/entity/shaders/tiled_texture_fill_external.frag @@ -11,11 +11,11 @@ uniform sampler2D SAMPLER_EXTERNAL_OES_texture_sampler; uniform FragInfo { float x_tile_mode; float y_tile_mode; + float alpha; } frag_info; in vec2 v_texture_coords; -in float v_alpha; out vec4 frag_color; @@ -26,5 +26,5 @@ void main() { frag_info.x_tile_mode, // x tile mode frag_info.y_tile_mode // y tile mode ) * - v_alpha; + frag_info.alpha; } diff --git a/impeller/tools/malioc.json b/impeller/tools/malioc.json index a94fac3acce2b..a0e3a966be0aa 100644 --- a/impeller/tools/malioc.json +++ b/impeller/tools/malioc.json @@ -184,191 +184,6 @@ } } }, - "flutter/impeller/entity/blend.frag.vkspv": { - "Mali-G78": { - "core": "Mali-G78", - "filename": "flutter/impeller/entity/blend.frag.vkspv", - "has_side_effects": false, - "has_uniform_computation": true, - "modifies_coverage": false, - "reads_color_buffer": false, - "type": "Fragment", - "uses_late_zs_test": false, - "uses_late_zs_update": false, - "variants": { - "Main": { - "fp16_arithmetic": 100, - "has_stack_spilling": false, - "performance": { - "longest_path_bound_pipelines": [ - "varying", - "texture" - ], - "longest_path_cycles": [ - 0.03125, - 0.03125, - 0.0, - 0.0, - 0.0, - 0.25, - 0.25 - ], - "pipelines": [ - "arith_total", - "arith_fma", - "arith_cvt", - "arith_sfu", - "load_store", - "varying", - "texture" - ], - "shortest_path_bound_pipelines": [ - "varying", - "texture" - ], - "shortest_path_cycles": [ - 0.03125, - 0.03125, - 0.0, - 0.0, - 0.0, - 0.25, - 0.25 - ], - "total_bound_pipelines": [ - "varying", - "texture" - ], - "total_cycles": [ - 0.03125, - 0.03125, - 0.0, - 0.0, - 0.0, - 0.25, - 0.25 - ] - }, - "stack_spill_bytes": 0, - "thread_occupancy": 100, - "uniform_registers_used": 4, - "work_registers_used": 4 - } - } - } - }, - "flutter/impeller/entity/blend.vert.vkspv": { - "Mali-G78": { - "core": "Mali-G78", - "filename": "flutter/impeller/entity/blend.vert.vkspv", - "has_uniform_computation": true, - "type": "Vertex", - "variants": { - "Position": { - "fp16_arithmetic": 0, - "has_stack_spilling": false, - "performance": { - "longest_path_bound_pipelines": [ - "load_store" - ], - "longest_path_cycles": [ - 0.125, - 0.125, - 0.0, - 0.0, - 2.0, - 0.0 - ], - "pipelines": [ - "arith_total", - "arith_fma", - "arith_cvt", - "arith_sfu", - "load_store", - "texture" - ], - "shortest_path_bound_pipelines": [ - "load_store" - ], - "shortest_path_cycles": [ - 0.125, - 0.125, - 0.0, - 0.0, - 2.0, - 0.0 - ], - "total_bound_pipelines": [ - "load_store" - ], - "total_cycles": [ - 0.125, - 0.125, - 0.0, - 0.0, - 2.0, - 0.0 - ] - }, - "stack_spill_bytes": 0, - "thread_occupancy": 100, - "uniform_registers_used": 30, - "work_registers_used": 32 - }, - "Varying": { - "fp16_arithmetic": 0, - "has_stack_spilling": false, - "performance": { - "longest_path_bound_pipelines": [ - "load_store" - ], - "longest_path_cycles": [ - 0.015625, - 0.015625, - 0.015625, - 0.0, - 3.0, - 0.0 - ], - "pipelines": [ - "arith_total", - "arith_fma", - "arith_cvt", - "arith_sfu", - "load_store", - "texture" - ], - "shortest_path_bound_pipelines": [ - "load_store" - ], - "shortest_path_cycles": [ - 0.015625, - 0.015625, - 0.015625, - 0.0, - 3.0, - 0.0 - ], - "total_bound_pipelines": [ - "load_store" - ], - "total_cycles": [ - 0.015625, - 0.015625, - 0.015625, - 0.0, - 3.0, - 0.0 - ] - }, - "stack_spill_bytes": 0, - "thread_occupancy": 100, - "uniform_registers_used": 22, - "work_registers_used": 8 - } - } - } - }, "flutter/impeller/entity/border_mask_blur.frag.vkspv": { "Mali-G78": { "core": "Mali-G78", @@ -1178,284 +993,9 @@ 0.578125, 0.265625, 0.125, - 0.0, - 0.5, - 0.5 - ], - "pipelines": [ - "arith_total", - "arith_fma", - "arith_cvt", - "arith_sfu", - "load_store", - "varying", - "texture" - ], - "shortest_path_bound_pipelines": [ - "arith_total", - "arith_fma" - ], - "shortest_path_cycles": [ - 0.53125, - 0.53125, - 0.21875, - 0.0625, - 0.0, - 0.25, - 0.25 - ], - "total_bound_pipelines": [ - "arith_total", - "arith_fma" - ], - "total_cycles": [ - 0.578125, - 0.578125, - 0.34375, - 0.125, - 0.0, - 0.5, - 0.5 - ] - }, - "stack_spill_bytes": 0, - "thread_occupancy": 100, - "uniform_registers_used": 14, - "work_registers_used": 23 - } - } - }, - "Mali-T880": { - "core": "Mali-T880", - "filename": "flutter/impeller/entity/gles/advanced_blend.frag.gles", - "has_uniform_computation": false, - "type": "Fragment", - "variants": { - "Main": { - "has_stack_spilling": false, - "performance": { - "longest_path_bound_pipelines": [ - "arithmetic" - ], - "longest_path_cycles": [ - 4.289999961853027, - 2.0, - 2.0 - ], - "pipelines": [ - "arithmetic", - "load_store", - "texture" - ], - "shortest_path_bound_pipelines": [ - "arithmetic" - ], - "shortest_path_cycles": [ - 3.299999952316284, - 1.0, - 1.0 - ], - "total_bound_pipelines": [ - "arithmetic" - ], - "total_cycles": [ - 4.666666507720947, - 2.0, - 2.0 - ] - }, - "thread_occupancy": 100, - "uniform_registers_used": 2, - "work_registers_used": 4 - } - } - } - }, - "flutter/impeller/entity/gles/advanced_blend.vert.gles": { - "Mali-G78": { - "core": "Mali-G78", - "filename": "flutter/impeller/entity/gles/advanced_blend.vert.gles", - "has_uniform_computation": true, - "type": "Vertex", - "variants": { - "Position": { - "fp16_arithmetic": 0, - "has_stack_spilling": false, - "performance": { - "longest_path_bound_pipelines": [ - "load_store" - ], - "longest_path_cycles": [ - 0.140625, - 0.140625, - 0.0, - 0.0, - 2.0, - 0.0 - ], - "pipelines": [ - "arith_total", - "arith_fma", - "arith_cvt", - "arith_sfu", - "load_store", - "texture" - ], - "shortest_path_bound_pipelines": [ - "load_store" - ], - "shortest_path_cycles": [ - 0.140625, - 0.140625, - 0.0, - 0.0, - 2.0, - 0.0 - ], - "total_bound_pipelines": [ - "load_store" - ], - "total_cycles": [ - 0.140625, - 0.140625, - 0.0, - 0.0, - 2.0, - 0.0 - ] - }, - "stack_spill_bytes": 0, - "thread_occupancy": 100, - "uniform_registers_used": 22, - "work_registers_used": 32 - }, - "Varying": { - "fp16_arithmetic": 0, - "has_stack_spilling": false, - "performance": { - "longest_path_bound_pipelines": [ - "load_store" - ], - "longest_path_cycles": [ - 0.03125, - 0.03125, - 0.03125, - 0.0, - 4.0, - 0.0 - ], - "pipelines": [ - "arith_total", - "arith_fma", - "arith_cvt", - "arith_sfu", - "load_store", - "texture" - ], - "shortest_path_bound_pipelines": [ - "load_store" - ], - "shortest_path_cycles": [ - 0.03125, - 0.03125, - 0.03125, - 0.0, - 4.0, - 0.0 - ], - "total_bound_pipelines": [ - "load_store" - ], - "total_cycles": [ - 0.03125, - 0.03125, - 0.03125, - 0.0, - 4.0, - 0.0 - ] - }, - "stack_spill_bytes": 0, - "thread_occupancy": 100, - "uniform_registers_used": 10, - "work_registers_used": 10 - } - } - }, - "Mali-T880": { - "core": "Mali-T880", - "filename": "flutter/impeller/entity/gles/advanced_blend.vert.gles", - "has_uniform_computation": false, - "type": "Vertex", - "variants": { - "Main": { - "has_stack_spilling": false, - "performance": { - "longest_path_bound_pipelines": [ - "load_store" - ], - "longest_path_cycles": [ - 3.299999952316284, - 7.0, - 0.0 - ], - "pipelines": [ - "arithmetic", - "load_store", - "texture" - ], - "shortest_path_bound_pipelines": [ - "load_store" - ], - "shortest_path_cycles": [ - 3.299999952316284, - 7.0, - 0.0 - ], - "total_bound_pipelines": [ - "load_store" - ], - "total_cycles": [ - 3.3333332538604736, - 7.0, - 0.0 - ] - }, - "thread_occupancy": 100, - "uniform_registers_used": 6, - "work_registers_used": 3 - } - } - } - }, - "flutter/impeller/entity/gles/blend.frag.gles": { - "Mali-G78": { - "core": "Mali-G78", - "filename": "flutter/impeller/entity/gles/blend.frag.gles", - "has_side_effects": false, - "has_uniform_computation": false, - "modifies_coverage": false, - "reads_color_buffer": false, - "type": "Fragment", - "uses_late_zs_test": false, - "uses_late_zs_update": false, - "variants": { - "Main": { - "fp16_arithmetic": 100, - "has_stack_spilling": false, - "performance": { - "longest_path_bound_pipelines": [ - "varying", - "texture" - ], - "longest_path_cycles": [ - 0.03125, - 0.03125, - 0.03125, - 0.0, - 0.0, - 0.25, - 0.25 + 0.0, + 0.5, + 0.5 ], "pipelines": [ "arith_total", @@ -1467,42 +1007,42 @@ "texture" ], "shortest_path_bound_pipelines": [ - "varying", - "texture" + "arith_total", + "arith_fma" ], "shortest_path_cycles": [ - 0.03125, - 0.03125, - 0.0, - 0.0, + 0.53125, + 0.53125, + 0.21875, + 0.0625, 0.0, 0.25, 0.25 ], "total_bound_pipelines": [ - "varying", - "texture" + "arith_total", + "arith_fma" ], "total_cycles": [ - 0.03125, - 0.03125, - 0.03125, - 0.0, + 0.578125, + 0.578125, + 0.34375, + 0.125, 0.0, - 0.25, - 0.25 + 0.5, + 0.5 ] }, "stack_spill_bytes": 0, "thread_occupancy": 100, - "uniform_registers_used": 4, - "work_registers_used": 19 + "uniform_registers_used": 14, + "work_registers_used": 23 } } }, "Mali-T880": { "core": "Mali-T880", - "filename": "flutter/impeller/entity/gles/blend.frag.gles", + "filename": "flutter/impeller/entity/gles/advanced_blend.frag.gles", "has_uniform_computation": false, "type": "Fragment", "variants": { @@ -1510,14 +1050,12 @@ "has_stack_spilling": false, "performance": { "longest_path_bound_pipelines": [ - "arithmetic", - "load_store", - "texture" + "arithmetic" ], "longest_path_cycles": [ - 1.0, - 1.0, - 1.0 + 4.289999961853027, + 2.0, + 2.0 ], "pipelines": [ "arithmetic", @@ -1525,36 +1063,33 @@ "texture" ], "shortest_path_bound_pipelines": [ - "arithmetic", - "load_store", - "texture" + "arithmetic" ], "shortest_path_cycles": [ - 1.0, + 3.299999952316284, 1.0, 1.0 ], "total_bound_pipelines": [ - "load_store", - "texture" + "arithmetic" ], "total_cycles": [ - 0.6666666865348816, - 1.0, - 1.0 + 4.666666507720947, + 2.0, + 2.0 ] }, "thread_occupancy": 100, - "uniform_registers_used": 1, - "work_registers_used": 2 + "uniform_registers_used": 2, + "work_registers_used": 4 } } } }, - "flutter/impeller/entity/gles/blend.vert.gles": { + "flutter/impeller/entity/gles/advanced_blend.vert.gles": { "Mali-G78": { "core": "Mali-G78", - "filename": "flutter/impeller/entity/gles/blend.vert.gles", + "filename": "flutter/impeller/entity/gles/advanced_blend.vert.gles", "has_uniform_computation": true, "type": "Vertex", "variants": { @@ -1617,11 +1152,11 @@ "load_store" ], "longest_path_cycles": [ - 0.015625, - 0.015625, - 0.015625, + 0.03125, + 0.03125, + 0.03125, 0.0, - 3.0, + 4.0, 0.0 ], "pipelines": [ @@ -1636,35 +1171,35 @@ "load_store" ], "shortest_path_cycles": [ - 0.015625, - 0.015625, - 0.015625, + 0.03125, + 0.03125, + 0.03125, 0.0, - 3.0, + 4.0, 0.0 ], "total_bound_pipelines": [ "load_store" ], "total_cycles": [ - 0.015625, - 0.015625, - 0.015625, + 0.03125, + 0.03125, + 0.03125, 0.0, - 3.0, + 4.0, 0.0 ] }, "stack_spill_bytes": 0, "thread_occupancy": 100, "uniform_registers_used": 10, - "work_registers_used": 8 + "work_registers_used": 10 } } }, "Mali-T880": { "core": "Mali-T880", - "filename": "flutter/impeller/entity/gles/blend.vert.gles", + "filename": "flutter/impeller/entity/gles/advanced_blend.vert.gles", "has_uniform_computation": false, "type": "Vertex", "variants": { @@ -1675,8 +1210,8 @@ "load_store" ], "longest_path_cycles": [ - 2.9700000286102295, - 5.0, + 3.299999952316284, + 7.0, 0.0 ], "pipelines": [ @@ -1688,22 +1223,22 @@ "load_store" ], "shortest_path_cycles": [ - 2.9700000286102295, - 5.0, + 3.299999952316284, + 7.0, 0.0 ], "total_bound_pipelines": [ "load_store" ], "total_cycles": [ - 3.0, - 5.0, + 3.3333332538604736, + 7.0, 0.0 ] }, "thread_occupancy": 100, "uniform_registers_used": 6, - "work_registers_used": 2 + "work_registers_used": 3 } } } @@ -5788,7 +5323,8 @@ "has_stack_spilling": false, "performance": { "longest_path_bound_pipelines": [ - "varying" + "varying", + "texture" ], "longest_path_cycles": [ 0.046875, @@ -5796,7 +5332,7 @@ 0.046875, 0.0, 0.0, - 0.375, + 0.25, 0.25 ], "pipelines": [ @@ -5809,7 +5345,8 @@ "texture" ], "shortest_path_bound_pipelines": [ - "varying" + "varying", + "texture" ], "shortest_path_cycles": [ 0.03125, @@ -5817,11 +5354,12 @@ 0.015625, 0.0, 0.0, - 0.375, + 0.25, 0.25 ], "total_bound_pipelines": [ - "varying" + "varying", + "texture" ], "total_cycles": [ 0.046875, @@ -5829,13 +5367,13 @@ 0.046875, 0.0, 0.0, - 0.375, + 0.25, 0.25 ] }, "stack_spill_bytes": 0, "thread_occupancy": 100, - "uniform_registers_used": 2, + "uniform_registers_used": 4, "work_registers_used": 19 } } @@ -5885,7 +5423,7 @@ ] }, "thread_occupancy": 100, - "uniform_registers_used": 0, + "uniform_registers_used": 1, "work_registers_used": 2 } } @@ -5957,11 +5495,11 @@ "load_store" ], "longest_path_cycles": [ - 0.03125, 0.015625, - 0.03125, + 0.015625, + 0.015625, 0.0, - 4.0, + 3.0, 0.0 ], "pipelines": [ @@ -5976,163 +5514,48 @@ "load_store" ], "shortest_path_cycles": [ - 0.03125, 0.015625, - 0.03125, + 0.015625, + 0.015625, 0.0, - 4.0, + 3.0, 0.0 ], "total_bound_pipelines": [ "load_store" ], "total_cycles": [ - 0.03125, 0.015625, - 0.03125, + 0.015625, + 0.015625, 0.0, - 4.0, - 0.0 - ] - }, - "stack_spill_bytes": 0, - "thread_occupancy": 100, - "uniform_registers_used": 10, - "work_registers_used": 7 - } - } - }, - "Mali-T880": { - "core": "Mali-T880", - "filename": "flutter/impeller/entity/gles/texture_fill.vert.gles", - "has_uniform_computation": false, - "type": "Vertex", - "variants": { - "Main": { - "has_stack_spilling": false, - "performance": { - "longest_path_bound_pipelines": [ - "load_store" - ], - "longest_path_cycles": [ - 2.9700000286102295, - 6.0, - 0.0 - ], - "pipelines": [ - "arithmetic", - "load_store", - "texture" - ], - "shortest_path_bound_pipelines": [ - "load_store" - ], - "shortest_path_cycles": [ - 2.9700000286102295, - 6.0, - 0.0 - ], - "total_bound_pipelines": [ - "load_store" - ], - "total_cycles": [ 3.0, - 6.0, 0.0 ] }, - "thread_occupancy": 100, - "uniform_registers_used": 6, - "work_registers_used": 2 - } - } - } - }, - "flutter/impeller/entity/gles/texture_fill_external.frag.gles": { - "Mali-G78": { - "core": "Mali-G78", - "filename": "flutter/impeller/entity/gles/texture_fill_external.frag.gles", - "has_side_effects": false, - "has_uniform_computation": true, - "modifies_coverage": false, - "reads_color_buffer": false, - "type": "Fragment", - "uses_late_zs_test": false, - "uses_late_zs_update": false, - "variants": { - "Main": { - "fp16_arithmetic": 0, - "has_stack_spilling": false, - "performance": { - "longest_path_bound_pipelines": [ - "varying" - ], - "longest_path_cycles": [ - 0.203125, - 0.203125, - 0.03125, - 0.0, - 0.0, - 0.375, - 0.25 - ], - "pipelines": [ - "arith_total", - "arith_fma", - "arith_cvt", - "arith_sfu", - "load_store", - "varying", - "texture" - ], - "shortest_path_bound_pipelines": [ - "varying" - ], - "shortest_path_cycles": [ - 0.203125, - 0.203125, - 0.0, - 0.0, - 0.0, - 0.375, - 0.25 - ], - "total_bound_pipelines": [ - "varying" - ], - "total_cycles": [ - 0.203125, - 0.203125, - 0.03125, - 0.0, - 0.0, - 0.375, - 0.25 - ] - }, "stack_spill_bytes": 0, - "thread_occupancy": 100, - "uniform_registers_used": 14, - "work_registers_used": 19 + "thread_occupancy": 100, + "uniform_registers_used": 10, + "work_registers_used": 8 } } }, "Mali-T880": { "core": "Mali-T880", - "filename": "flutter/impeller/entity/gles/texture_fill_external.frag.gles", + "filename": "flutter/impeller/entity/gles/texture_fill.vert.gles", "has_uniform_computation": false, - "type": "Fragment", + "type": "Vertex", "variants": { "Main": { "has_stack_spilling": false, "performance": { "longest_path_bound_pipelines": [ - "arithmetic" + "load_store" ], "longest_path_cycles": [ - 1.649999976158142, - 1.0, - 1.0 + 2.9700000286102295, + 5.0, + 0.0 ], "pipelines": [ "arithmetic", @@ -6140,25 +5563,25 @@ "texture" ], "shortest_path_bound_pipelines": [ - "arithmetic" + "load_store" ], "shortest_path_cycles": [ - 1.649999976158142, - 1.0, - 1.0 + 2.9700000286102295, + 5.0, + 0.0 ], "total_bound_pipelines": [ - "arithmetic" + "load_store" ], "total_cycles": [ - 2.0, - 1.0, - 1.0 + 3.0, + 5.0, + 0.0 ] }, "thread_occupancy": 100, - "uniform_registers_used": 2, - "work_registers_used": 3 + "uniform_registers_used": 6, + "work_registers_used": 2 } } } @@ -6180,7 +5603,8 @@ "has_stack_spilling": false, "performance": { "longest_path_bound_pipelines": [ - "varying" + "varying", + "texture" ], "longest_path_cycles": [ 0.109375, @@ -6188,7 +5612,7 @@ 0.109375, 0.0, 0.0, - 0.375, + 0.25, 0.25 ], "pipelines": [ @@ -6201,7 +5625,8 @@ "texture" ], "shortest_path_bound_pipelines": [ - "varying" + "varying", + "texture" ], "shortest_path_cycles": [ 0.078125, @@ -6209,11 +5634,12 @@ 0.078125, 0.0, 0.0, - 0.375, + 0.25, 0.25 ], "total_bound_pipelines": [ - "varying" + "varying", + "texture" ], "total_cycles": [ 0.109375, @@ -6221,14 +5647,14 @@ 0.109375, 0.0, 0.0, - 0.375, + 0.25, 0.25 ] }, "stack_spill_bytes": 0, "thread_occupancy": 100, - "uniform_registers_used": 4, - "work_registers_used": 20 + "uniform_registers_used": 6, + "work_registers_used": 19 } } }, @@ -6301,15 +5727,16 @@ "has_stack_spilling": false, "performance": { "longest_path_bound_pipelines": [ - "varying" + "arith_total", + "arith_cvt" ], "longest_path_cycles": [ - 0.25, + 0.265625, 0.03125, - 0.25, + 0.265625, 0.0, 0.0, - 0.375, + 0.25, 0.25 ], "pipelines": [ @@ -6322,27 +5749,29 @@ "texture" ], "shortest_path_bound_pipelines": [ - "varying" + "varying", + "texture" ], "shortest_path_cycles": [ - 0.046875, + 0.0625, 0.03125, - 0.046875, + 0.0625, 0.0, 0.0, - 0.375, + 0.25, 0.25 ], "total_bound_pipelines": [ - "varying" + "arith_total", + "arith_cvt" ], "total_cycles": [ - 0.25, + 0.265625, 0.03125, - 0.25, + 0.265625, 0.0, 0.0, - 0.375, + 0.25, 0.25 ] }, @@ -6367,7 +5796,7 @@ ], "longest_path_cycles": [ 3.299999952316284, - 2.0, + 1.0, 1.0 ], "pipelines": [ @@ -6376,11 +5805,11 @@ "texture" ], "shortest_path_bound_pipelines": [ - "load_store" + "arithmetic" ], "shortest_path_cycles": [ 1.3200000524520874, - 2.0, + 1.0, 0.0 ], "total_bound_pipelines": [ @@ -6388,7 +5817,7 @@ ], "total_cycles": [ 3.6666667461395264, - 2.0, + 1.0, 1.0 ] }, @@ -6425,7 +5854,7 @@ 0.421875, 0.0, 0.0, - 0.25, + 0.125, 0.25 ], "pipelines": [ @@ -6446,7 +5875,7 @@ 0.09375, 0.0, 0.0, - 0.25, + 0.125, 0.0 ], "total_bound_pipelines": [ @@ -6459,7 +5888,7 @@ 0.515625, 0.0, 0.0, - 0.25, + 0.125, 0.25 ] }, @@ -6484,7 +5913,7 @@ ], "longest_path_cycles": [ 7.920000076293945, - 2.0, + 1.0, 1.0 ], "pipelines": [ @@ -6493,11 +5922,11 @@ "texture" ], "shortest_path_bound_pipelines": [ - "load_store" + "arithmetic" ], "shortest_path_cycles": [ 1.3200000524520874, - 2.0, + 1.0, 0.0 ], "total_bound_pipelines": [ @@ -6505,7 +5934,7 @@ ], "total_cycles": [ 9.0, - 2.0, + 1.0, 1.0 ] }, @@ -8969,7 +8398,7 @@ "core": "Mali-G78", "filename": "flutter/impeller/entity/texture_fill.frag.vkspv", "has_side_effects": false, - "has_uniform_computation": false, + "has_uniform_computation": true, "modifies_coverage": false, "reads_color_buffer": false, "type": "Fragment", @@ -8981,7 +8410,8 @@ "has_stack_spilling": false, "performance": { "longest_path_bound_pipelines": [ - "varying" + "varying", + "texture" ], "longest_path_cycles": [ 0.03125, @@ -8989,7 +8419,7 @@ 0.015625, 0.0, 0.0, - 0.375, + 0.25, 0.25 ], "pipelines": [ @@ -9002,7 +8432,8 @@ "texture" ], "shortest_path_bound_pipelines": [ - "varying" + "varying", + "texture" ], "shortest_path_cycles": [ 0.03125, @@ -9010,11 +8441,12 @@ 0.015625, 0.0, 0.0, - 0.375, + 0.25, 0.25 ], "total_bound_pipelines": [ - "varying" + "varying", + "texture" ], "total_cycles": [ 0.03125, @@ -9022,14 +8454,14 @@ 0.015625, 0.0, 0.0, - 0.375, + 0.25, 0.25 ] }, "stack_spill_bytes": 0, "thread_occupancy": 100, - "uniform_registers_used": 2, - "work_registers_used": 6 + "uniform_registers_used": 4, + "work_registers_used": 5 } } } @@ -9100,11 +8532,11 @@ "load_store" ], "longest_path_cycles": [ - 0.03125, 0.015625, - 0.03125, + 0.015625, + 0.015625, 0.0, - 4.0, + 3.0, 0.0 ], "pipelines": [ @@ -9119,99 +8551,29 @@ "load_store" ], "shortest_path_cycles": [ - 0.03125, 0.015625, - 0.03125, + 0.015625, + 0.015625, 0.0, - 4.0, + 3.0, 0.0 ], "total_bound_pipelines": [ "load_store" ], "total_cycles": [ - 0.03125, 0.015625, - 0.03125, + 0.015625, + 0.015625, 0.0, - 4.0, + 3.0, 0.0 ] }, "stack_spill_bytes": 0, "thread_occupancy": 100, "uniform_registers_used": 22, - "work_registers_used": 7 - } - } - } - }, - "flutter/impeller/entity/texture_fill_external.frag.vkspv": { - "Mali-G78": { - "core": "Mali-G78", - "filename": "flutter/impeller/entity/texture_fill_external.frag.vkspv", - "has_side_effects": false, - "has_uniform_computation": false, - "modifies_coverage": false, - "reads_color_buffer": false, - "type": "Fragment", - "uses_late_zs_test": false, - "uses_late_zs_update": false, - "variants": { - "Main": { - "fp16_arithmetic": 0, - "has_stack_spilling": false, - "performance": { - "longest_path_bound_pipelines": [ - "varying" - ], - "longest_path_cycles": [ - 0.0625, - 0.0625, - 0.0, - 0.0, - 0.0, - 0.375, - 0.25 - ], - "pipelines": [ - "arith_total", - "arith_fma", - "arith_cvt", - "arith_sfu", - "load_store", - "varying", - "texture" - ], - "shortest_path_bound_pipelines": [ - "varying" - ], - "shortest_path_cycles": [ - 0.0625, - 0.0625, - 0.0, - 0.0, - 0.0, - 0.375, - 0.25 - ], - "total_bound_pipelines": [ - "varying" - ], - "total_cycles": [ - 0.0625, - 0.0625, - 0.0, - 0.0, - 0.0, - 0.375, - 0.25 - ] - }, - "stack_spill_bytes": 0, - "thread_occupancy": 100, - "uniform_registers_used": 4, - "work_registers_used": 10 + "work_registers_used": 8 } } } @@ -9233,7 +8595,8 @@ "has_stack_spilling": false, "performance": { "longest_path_bound_pipelines": [ - "varying" + "varying", + "texture" ], "longest_path_cycles": [ 0.078125, @@ -9241,7 +8604,7 @@ 0.078125, 0.0, 0.0, - 0.375, + 0.25, 0.25 ], "pipelines": [ @@ -9254,7 +8617,8 @@ "texture" ], "shortest_path_bound_pipelines": [ - "varying" + "varying", + "texture" ], "shortest_path_cycles": [ 0.078125, @@ -9262,11 +8626,12 @@ 0.078125, 0.0, 0.0, - 0.375, + 0.25, 0.25 ], "total_bound_pipelines": [ - "varying" + "varying", + "texture" ], "total_cycles": [ 0.078125, @@ -9274,14 +8639,14 @@ 0.078125, 0.0, 0.0, - 0.375, + 0.25, 0.25 ] }, "stack_spill_bytes": 0, "thread_occupancy": 100, - "uniform_registers_used": 6, - "work_registers_used": 6 + "uniform_registers_used": 8, + "work_registers_used": 5 } } } @@ -9303,7 +8668,10 @@ "has_stack_spilling": false, "performance": { "longest_path_bound_pipelines": [ - "varying" + "arith_total", + "arith_cvt", + "varying", + "texture" ], "longest_path_cycles": [ 0.25, @@ -9311,7 +8679,7 @@ 0.25, 0.0625, 0.0, - 0.375, + 0.25, 0.25 ], "pipelines": [ @@ -9332,11 +8700,14 @@ 0.140625, 0.0625, 0.0, - 0.375, + 0.25, 0.0 ], "total_bound_pipelines": [ - "varying" + "arith_total", + "arith_cvt", + "varying", + "texture" ], "total_cycles": [ 0.25, @@ -9344,14 +8715,14 @@ 0.25, 0.0625, 0.0, - 0.375, + 0.25, 0.25 ] }, "stack_spill_bytes": 0, "thread_occupancy": 100, "uniform_registers_used": 4, - "work_registers_used": 8 + "work_registers_used": 7 } } } @@ -9382,7 +8753,7 @@ 0.328125, 0.0, 0.0, - 0.25, + 0.125, 0.25 ], "pipelines": [ @@ -9403,7 +8774,7 @@ 0.109375, 0.0, 0.0, - 0.25, + 0.125, 0.0 ], "total_bound_pipelines": [ @@ -9416,14 +8787,14 @@ 0.390625, 0.0, 0.0, - 0.25, + 0.125, 0.25 ] }, "stack_spill_bytes": 0, "thread_occupancy": 100, "uniform_registers_used": 6, - "work_registers_used": 7 + "work_registers_used": 6 } } }