25706 Commits

Author SHA1 Message Date
Zachary Anderson
c5eac677ca Revert "[Fuchsia] Execute most of the testing/fuchsia/test_suites.yaml on debug and release builds" (flutter/engine#50291)
Reverts flutter/engine#50058 for
https://github.com/flutter/flutter/issues/142811
2024-02-02 11:40:10 -08:00
Zachary Anderson
45c60db662 Move linux_fuchsia to staging (flutter/engine#50288)
For https://github.com/flutter/flutter/issues/142811
2024-02-02 18:23:05 +00:00
Juanjo Tugores
358d8b6229 Add the focus state related methods to the platform dispatcher (flutter/engine#50273)
These changes were originally landed on
https://github.com/flutter/engine/pull/49841 but reverted in
64fe7b86c3.
I fixed the offending dart snippets and (think) they now will work
without issues (I think I was able to verify them locally by manually
patching my bin/cache/... copy of these files with these changes).

Relevant Issues are:
* Design doc link:
https://github.com/flutter/website/actions/runs/7560898849/job/20588395967
* Design doc: https://github.com/flutter/flutter/issues/141711
* Focus in web multiview:
https://github.com/flutter/flutter/issues/137443

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide] and the [C++,
Objective-C, Java style guides].
- [x] I listed at least one issue that this PR fixes in the description
above.
- [x] I added new tests to check the change I am making or feature I am
adding, or the PR is [test-exempt]. See [testing the engine] for
instructions on writing and running engine tests.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [x] I signed the [CLA].
- [x] All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel
on [Discord].

<!-- Links -->
[Contributor Guide]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#overview
[Tree Hygiene]: https://github.com/flutter/flutter/wiki/Tree-hygiene
[test-exempt]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#tests
[Flutter Style Guide]:
https://github.com/flutter/flutter/wiki/Style-guide-for-Flutter-repo
[C++, Objective-C, Java style guides]:
https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
[testing the engine]:
https://github.com/flutter/flutter/wiki/Testing-the-engine
[CLA]: https://cla.developers.google.com/
[flutter/tests]: https://github.com/flutter/tests
[breaking change policy]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#handling-breaking-changes
[Discord]: https://github.com/flutter/flutter/wiki/Chat
2024-02-02 10:13:00 -08:00
Ricardo Amador
1b4b809bf3 Add a link the different possible Android virtual device configs (flutter/engine#50267)
*Replace this paragraph with a description of what this PR is changing or adding, and why. Consider including before/after screenshots.*

*List which issues are fixed by this PR. You must list at least one issue.*

*If you had to change anything in the [flutter/tests] repo, include a link to the migration guide as per the [breaking change policy].*

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-02-02 16:13:38 +00:00
Bart Cone
1b95fed6c0 [Android] Fix TextInputType.none for devices with physical keyboard (flutter/engine#49980)
## Description

This PR fixes an issue where keystrokes aren't received on Android
devices with physical keyboards (e.g. rugged Zebra devices) when
`keyboardType` is set to `TextInputType.none` on a `TextField`.

The logic in `setTextInputClient` and `canShowTextInput` created an
`inputTarget` with `InputTarget.Type.NO_TARGET` which caused the [input
connection to short
circuit](https://github.com/flutter/engine/blob/main/shell/platform/android/io/flutter/plugin/editing/TextInputPlugin.java#L296)
and not be established.

Bug introduction PR: https://github.com/flutter/engine/pull/26585

## Related Issue

https://github.com/flutter/flutter/issues/89983

## Unit Test Notes

- The existing `showTextInput_textInputTypeNone()` stays green after
update.
- `inputConnection_textInputTypeNone()` updated to `assertNotNull`. I
would make this more specific, but this is my first venture into the
Flutter engine and don't know enough about those connection attributes.

## Demo

Video below with Zebra MC9300 device. This issue can also be reproduced
in a standard android emulator. Simply add a `TextField`, configure
`keyboardType` to be `TextInputType.none` and attempt to enter text
after running and giving focus to textfield.

Before


https://github.com/flutter/engine/assets/1988098/348ca061-b8b9-4483-956e-0732c1238207

After


https://github.com/flutter/engine/assets/1988098/b65c7251-59b4-4c73-9b85-7ac03f47a7e4

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide] and the [C++,
Objective-C, Java style guides].
- [x] I listed at least one issue that this PR fixes in the description
above.
- [ ] I added new tests to check the change I am making or feature I am
adding, or the PR is [test-exempt]. See [testing the engine] for
instructions on writing and running engine tests.
- [ ] I updated/added relevant documentation (doc comments with `///`).
- [x] I signed the [CLA].
- [x] All existing and new tests are passing.
2024-02-01 23:24:39 -08:00
auto-submit[bot]
64fe7b86c3 Reverts "Add the focus state related methods to the platform dispatcher" (flutter/engine#50268)
Reverts flutter/engine#49841
Initiated by: zanderso
This change reverts the following previous change:
Original Description:
This change augments the platform dispatcher to allow the engine <===> framework to communicate flutter and platform focus changes.

Relevant Issues are:
* Design doc link: https://github.com/flutter/website/actions/runs/7560898849/job/20588395967
* Design doc: https://github.com/flutter/flutter/issues/141711
* Focus in web multiview: https://github.com/flutter/flutter/issues/137443

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-02-02 02:59:26 +00:00
skia-flutter-autoroll
0b311bcbdc Manual roll Dart SDK from 82936dcdaf4f to 5a5d4c262200 (2 revisions) (flutter/engine#50264)
Manual roll requested by kevinjchisholm@google.com

https://dart.googlesource.com/sdk.git/+log/82936dcdaf4f..5a5d4c262200

2024-02-01 dart-internal-merge@dart-ci-internal.iam.gserviceaccount.com Version 3.4.0-99.0.dev
2024-02-01 dart-internal-merge@dart-ci-internal.iam.gserviceaccount.com Version 3.4.0-98.0.dev

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/dart-sdk-flutter-engine
Please CC dart-vm-team@google.com,kevinjchisholm@google.com,matanl@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Flutter Engine: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
2024-02-02 01:56:09 +00:00
Tong Mu
be6209e136 Remove number of arguments from defining Dart FFI (flutter/engine#50153)
The number of arguments are not used. 

And also, even if we need it in the future, they can be derived at compile time:

```cpp
template <typename T>
struct function_traits;

template <typename Ret, typename... Args>
struct function_traits<Ret(Args...)>
{
    using params = std::tuple<Args...>;
};

template <typename T>
constexpr std::size_t get_parameter_count() {
    return std::tuple_size<typename function_traits<T>::params>::value;
}

template <typename T>
struct member_function_traits;

template <typename C, typename Ret, typename... Args>
struct member_function_traits<Ret(C::*)(Args...)>
{
    using params = std::tuple<Args...>;
};

template <typename T>
constexpr std::size_t get_member_function_parameter_count() {
    return std::tuple_size<typename member_function_traits<T>::params>::value;
}

```

(I got the code above with ChatGPT but I verified that they work)

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-02-01 23:58:31 +00:00
Ricardo Amador
0946672e54 Refactor the linux_android targets to make use of recent changes to android virtual device params (flutter/engine#50099)
Changes to use the proto.textpb config file as the version of the emulator device and show the cipd dependency version in the dependencies so devs know it can be updated.

This will not pass until recipe changes have landed.

*List which issues are fixed by this PR. You must list at least one issue.*
Fixes https://github.com/flutter/flutter/issues/142261

*If you had to change anything in the [flutter/tests] repo, include a link to the migration guide as per the [breaking change policy].*

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-02-01 23:52:29 +00:00
Michael Goderbauer
2134c852b4 Re-add tests deleted on accident (flutter/engine#50223)
This re-adds the tests from https://github.com/flutter/engine/pull/41998/files that were accidentally deleted in https://github.com/flutter/engine/pull/42418/files#diff-2cce780ae0f93b9230cbf44030048dbf9ef4c6e0fdb959a47cae440fac0350faL808, probably because of a bad merge.
2024-02-01 21:51:51 +00:00
gaaclarke
5d0859ada0 [Impeller] updated todos from opengles golden work (flutter/engine#50218)
followup from https://github.com/flutter/engine/pull/50146

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-02-01 21:36:52 +00:00
Jim Graham
50968b0324 Get bounds from RTree in DLBuilder::Build() (flutter/engine#50253)
This optimization was discovered when reviewing the bounds accumulation code in DisplayListBuilder. There is trivially wasted work in the `Build()` method that can be easily avoided.

When a Builder is preparing an RTree, it accumulates a list of bounds for every rendering op, but doesn't union them up front. If you ask the Builder for the bounds of the accumulated ops, it will have to union all of the rectangles to produce an answer. But, if you ask the Builder to produce an RTree, that process will implicitly combine all of the rectangles as a side effect of creating the tree structure - and that RTree object has a bounds method that can return the result directly.

This change leverages the construction of the RTree to avoid having to union all of the rects twice which can only save time when constructing the majority of DisplayList objects used in a scene.
2024-02-01 21:31:26 +00:00
Chinmay Garde
a018aebbe9 [Impeller] Remove unused define. (flutter/engine#50250)
This define isn't used in a C++ TU. Only the build scripts (in `//flutter/shell/platform/android/BUILD.gn`) use the flag to decide whether to package the validation layers.

Remove the define that no one uses.
2024-02-01 21:30:18 +00:00
Juanjo Tugores
9858aa35c2 Add the focus state related methods to the platform dispatcher (flutter/engine#49841)
This change augments the platform dispatcher to allow the engine <===>
framework to communicate flutter and platform focus changes.

Relevant Issues are:
* Design doc link:
https://github.com/flutter/website/actions/runs/7560898849/job/20588395967
* Design doc: https://github.com/flutter/flutter/issues/141711
* Focus in web multiview:
https://github.com/flutter/flutter/issues/137443

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide] and the [C++,
Objective-C, Java style guides].
- [x] I listed at least one issue that this PR fixes in the description
above.
- [x] I added new tests to check the change I am making or feature I am
adding, or the PR is [test-exempt]. See [testing the engine] for
instructions on writing and running engine tests.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [x] I signed the [CLA].
- [x] All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel
on [Discord].

<!-- Links -->
[Contributor Guide]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#overview
[Tree Hygiene]: https://github.com/flutter/flutter/wiki/Tree-hygiene
[test-exempt]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#tests
[Flutter Style Guide]:
https://github.com/flutter/flutter/wiki/Style-guide-for-Flutter-repo
[C++, Objective-C, Java style guides]:
https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
[testing the engine]:
https://github.com/flutter/flutter/wiki/Testing-the-engine
[CLA]: https://cla.developers.google.com/
[flutter/tests]: https://github.com/flutter/tests
[breaking change policy]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#handling-breaking-changes
[Discord]: https://github.com/flutter/flutter/wiki/Chat
2024-02-01 13:20:30 -08:00
Jason Simmons
a337919d34 Fix the output paths of the Web esbuild GN template (flutter/engine#50188) 2024-02-01 21:17:32 +00:00
Chinmay Garde
336c5ca450 [Impeller] Delete unnecessary special casing for Vulkan in framebuffer fetch. (flutter/engine#50251)
The code generated is functionally identical (http://tinyurl.com/yov6m8ac).
2024-02-01 21:12:34 +00:00
Brandon DeRosier
5d6ea1d82f [Impeller] Replace stencil pipeline ops with enum. (flutter/engine#50231)
Depends on https://github.com/flutter/engine/pull/49828.

No semantic change.

Also adds/documents stencil configurations that are needed for StC. Operations for the current stencil stack are labeled as "legacy".
2024-02-01 19:13:41 +00:00
gaaclarke
ec74b5fbef [Impeller] new blur: round downsample to power of two (flutter/engine#50245)
This makes the downsampling step of the new blur round to the nearest power of 2.  This makes the changes in downsampling less frequent and the output of downsampling hypothetically higher quality since downsampling by a power of 2 is easier.

issue: https://github.com/flutter/flutter/issues/141510

## before
https://github.com/flutter/engine/assets/30870216/73e78f02-1346-4dde-ad6e-8aaa7c910bac

## after
https://github.com/flutter/engine/assets/30870216/b4153ada-6a82-4d0a-a4c2-158134c7b74f

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-02-01 19:12:43 +00:00
John McCutchan
7c04b55f07 Provide a more helpful error message in the case of UnsatisfiedLinkError (flutter/engine#50247)
Related https://github.com/flutter/flutter/issues/83596
2024-02-01 11:04:45 -08:00
Jonah Williams
eff9aac24a Update expected golden number. (flutter/engine#50249)
My patching removing drawPicture might have landed before syncing to the
patch that added the golden # check.
2024-02-01 10:48:40 -08:00
Jonah Williams
abfdf7ed0b [Impeller] remove drawPicture from Aiks Canvas. (flutter/engine#50242)
These interfaces were added to allow experimentation with the AiksLayer in the framework. Since our current approach is focused on aligning display list and impeller, we don't need these anymore.
2024-02-01 18:07:46 +00:00
Loïc Sharma
5251e0048f Reland "[Windows] Introduce egl::Surface and egl::WindowSurface" (flutter/engine#50148)
# Original pull request description

This introduces the `egl::Surface` and `egl::WindowSurface` types to abstract a raw `EGLSurface`. This also removes some - but not all - EGL surface logic out from `EGLManager`.

Subsequent pull requests will be necessary to:

1. Move ownership of the `egl::WindowSurface` from `egl::Manager` to `FlutterWindowsView`
2. Refactor external texture's off-screen EGL surface to use `egl::Surface`

Part of https://github.com/flutter/flutter/issues/141996

# Reland

https://github.com/flutter/engine/pull/49983 was reverted as it introduced a crash if the render surface fails to be created even though EGL was initialized successfully.

This pull request is split into the following commits:

1. c0b11be79f is the original pull request unchanged
2. 1dc7813845 is the fix: it checks a surface is valid before using it. This also adds several tests to prevent this kind of regression.

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-02-01 17:08:15 +00:00
gaaclarke
110583e248 [Impeller] added an assert that goldens are generated (flutter/engine#50222)
fixes https://github.com/flutter/flutter/issues/142657

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide] and the [C++,
Objective-C, Java style guides].
- [x] I listed at least one issue that this PR fixes in the description
above.
- [x] I added new tests to check the change I am making or feature I am
adding, or the PR is [test-exempt]. See [testing the engine] for
instructions on writing and running engine tests.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [x] I signed the [CLA].
- [x] All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel
on [Discord].

<!-- Links -->
[Contributor Guide]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#overview
[Tree Hygiene]: https://github.com/flutter/flutter/wiki/Tree-hygiene
[test-exempt]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#tests
[Flutter Style Guide]:
https://github.com/flutter/flutter/wiki/Style-guide-for-Flutter-repo
[C++, Objective-C, Java style guides]:
https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
[testing the engine]:
https://github.com/flutter/flutter/wiki/Testing-the-engine
[CLA]: https://cla.developers.google.com/
[flutter/tests]: https://github.com/flutter/tests
[breaking change policy]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#handling-breaking-changes
[Discord]: https://github.com/flutter/flutter/wiki/Chat
2024-02-01 08:45:41 -08:00
Zachary Anderson
55d79af527 Moves impeller/golden_tests_harvester to tools/golden_tests_harvester (flutter/engine#50211)
The tool is not Impeller specific, so moving it to the `tools/`
directory.
2024-02-01 08:38:52 -08:00
skia-flutter-autoroll
a3d0f22332 Roll Fuchsia Linux SDK from nymRxHV9Shod7cyLe... to kvEXgoydRYnW3UvX2... (flutter/engine#50235)
If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/fuchsia-linux-sdk-flutter-engine
Please CC matanl@google.com,rmistry@google.com,zra@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
2024-02-01 12:00:20 +00:00
Brandon DeRosier
2bf0ce66c5 [Impeller] Assign incremental clip depth to all entities. (flutter/engine#49828)
- Add depth settings to pipeline variant hash.
- Assign new clip depth to all entities.
- Punt the final depth to all the vertex shaders.
- Add validations to assert all clip depths are resolved.
2024-02-01 02:56:16 -08:00
skia-flutter-autoroll
cdec42a288 Roll Skia from 505d22d0ecdc to 756276a133b1 (3 revisions) (flutter/engine#50232)
https://skia.googlesource.com/skia.git/+log/505d22d0ecdc..756276a133b1

2024-02-01 skia-autoroll@skia-public.iam.gserviceaccount.com Roll SK Tool from 6e97526ab534 to 3f8e049193be
2024-02-01 skia-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from 2cc2b392c9ef to 78d1799ee43e (1 revision)
2024-02-01 skia-autoroll@skia-public.iam.gserviceaccount.com Roll Skia Infra from 3c9b934fc33b to 6e97526ab534 (9 revisions)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/skia-flutter-autoroll
Please CC brianosman@google.com,jmbetancourt@google.com,matanl@google.com,rmistry@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Skia: https://bugs.chromium.org/p/skia/issues/entry
To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
2024-02-01 07:36:16 +00:00
Jason Simmons
cc9b60836e [Impeller] Clear the GPUTracerVK in_frame flag when ending a frame even if the tracer is disabled (flutter/engine#50228)
Without this an assertion in GPUTracerVK::MarkFrameStart will fail on the next frame.
2024-02-01 04:22:34 +00:00
auto-submit[bot]
90b6db8915 Reverts "Remove migration flag and unused header files" (flutter/engine#50229)
Reverts flutter/engine#50216
Initiated by: zanderso
This change reverts the following previous change:
Original Description:
The `applyRoundingHack` flag is no longer used by the framework. This also removes the [lib/ui/text/line_metrics.h](https://github.com/flutter/engine/pull/50216/files#diff-9175619f2b114dffef67eba38511b34afe6abefd4f697f4758647133895b34f5) file which doesn't seem to be referenced anywhere.

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-02-01 03:47:16 +00:00
Jonah Williams
0682efb50f [Impeller] size vk swapchain to window size. (flutter/engine#50205)
The size the engine recieves from the `AndroidSurfaceVulkanImpeller::OnScreenSurfaceResize` appears to be correct in the case of window rotation. Use this instead of physical surface properties to set the swapchain image size.

Querying the physical surface properties seems to have some additional non-deterministic delay. This means that querying the properties during a window rotation will frequently return old values.

Fixes https://github.com/flutter/flutter/issues/138780
Fixes https://github.com/flutter/flutter/issues/132708
2024-02-01 03:45:07 +00:00
Robert Ancell
bd70ef1215 Remove string field from FlKeyEvent (flutter/engine#50189)
This field is deprecated in GTK3 [1] and not used in Flutter. It does
not exist in GTK4.

[1] https://docs.gtk.org/gdk3/struct.EventKey.html
2024-02-01 16:17:19 +13:00
skia-flutter-autoroll
975a17fdef Roll Skia from 19e5e8f089b2 to bcbc172f74da (2 revisions) (flutter/engine#50226)
https://skia.googlesource.com/skia.git/+log/19e5e8f089b2..bcbc172f74da

2024-02-01 lokokung@google.com Adds wgpu::Instance as a member for graphites Dawn backend.
2024-02-01 skia-autoroll@skia-public.iam.gserviceaccount.com Roll vulkan-deps from cfc202524ce6 to 6e233a9a5f48 (5 revisions)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/skia-flutter-autoroll
Please CC brianosman@google.com,jmbetancourt@google.com,matanl@google.com,rmistry@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Skia: https://bugs.chromium.org/p/skia/issues/entry
To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
2024-02-01 02:16:43 +00:00
Matan Lurey
bf073d4352 Ignore CRLF endings when determining the names of header guards. (flutter/engine#50227)
Reported by @loic-sharma.

The tl;dr is it should be OK to have `\r\n` (CRLF) endings if the header
guard is otherwise correct.

This minor refactor (and test) discounts the existence of `\r` when
determining the name of a header guard, i.e.:
```h
#ifndef FLUTTER_MATAN_WHY_H_
```

... is now (correctly) considered a value of `FLUTTER_MATAN_WHY_H_` not
`FLUTTER_MATAN_WHY_H_\r`.
2024-01-31 17:58:22 -08:00
Jonah Williams
c403a9f417 [Impeller] make GPU tracing off by default. (flutter/engine#50215)
Fixes https://github.com/flutter/flutter/issues/141788
Fixes https://github.com/flutter/flutter/issues/141798

Disable GPU tracing by default.
2024-02-01 00:55:33 +00:00
Tong Mu
f1b651bfd0 Multiview: Add view ID to _render and remove render rule skipping (flutter/engine#50220)
This PR adds a view ID parameter to the Dart FFI `_render` function, and
also remove the logic that skips illegal renders that violates the
render rule.

I decided to implement the change to add the view ID as a separate PR
because it's blocking us from performing benchmark testing internally,
which is required to verify before merging the full multiview pipeline.

We're also abolishing the render rule for now to allow presenting the
warmup frame, which affects the startup performance. It is planned to
implement the render rule once we can coordinate the warmup frame into
the pipeline.

### More on removing the render rule enforcement

The project needs to be divided into two phases:
* Phase 1: Dart:ui doesn't kip out-of-vsync frames. And the pipeline
presents these frames in a hacky way.
* Phase 2: Dart:ui skip out-of-vsync frames, but submit warmup frames
using a dedicated method. The pipeline contains no hacks.

The current logic only enforces the render rule in debug mode. It's not
desired to have the debug mode and the release mode behaving
differently. Moreover, I'd like to make only the necessary changes for
phase 1, so that there is as little "to be used in the future" code
between the two phases as possible.

## Pre-launch Checklist

- [ ] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [ ] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [ ] I read and followed the [Flutter Style Guide] and the [C++,
Objective-C, Java style guides].
- [ ] I listed at least one issue that this PR fixes in the description
above.
- [ ] I added new tests to check the change I am making or feature I am
adding, or the PR is [test-exempt]. See [testing the engine] for
instructions on writing and running engine tests.
- [ ] I updated/added relevant documentation (doc comments with `///`).
- [ ] I signed the [CLA].
- [ ] All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel
on [Discord].

<!-- Links -->
[Contributor Guide]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#overview
[Tree Hygiene]: https://github.com/flutter/flutter/wiki/Tree-hygiene
[test-exempt]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#tests
[Flutter Style Guide]:
https://github.com/flutter/flutter/wiki/Style-guide-for-Flutter-repo
[C++, Objective-C, Java style guides]:
https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
[testing the engine]:
https://github.com/flutter/flutter/wiki/Testing-the-engine
[CLA]: https://cla.developers.google.com/
[flutter/tests]: https://github.com/flutter/tests
[breaking change policy]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#handling-breaking-changes
[Discord]: https://github.com/flutter/flutter/wiki/Chat
2024-01-31 16:38:07 -08:00
LongCatIsLooong
737437f718 Remove migration flag and unused header files (flutter/engine#50216)
The `applyRoundingHack` flag is no longer used by the framework. This also removes the [lib/ui/text/line_metrics.h](https://github.com/flutter/engine/pull/50216/files#diff-9175619f2b114dffef67eba38511b34afe6abefd4f697f4758647133895b34f5) file which doesn't seem to be referenced anywhere.

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-02-01 00:36:16 +00:00
Chinmay Garde
e858c7847f [Impeller] Implement framebuffer-fetch via subpasses in Vulkan without extensions. (flutter/engine#50154)
* Subpasses are not exposed in the HAL and the need for subpasses in Vulkan can
  be determined based on the presence and use of input-attachments in the
  shaders. This information is already reflected by the compiler. Because of
  this, all references to subpasses have been removed from APIs above the HAL.
* `RenderPassBuilderVK` is a lightweight object used to generate render passes
  to use either with the pipelines (compat, base, or per-subpass) or during
  rendering along with the framebuffer. Using the builder also sets up the
  right subpass dependencies. As long as the builder contains compatible
  attachments and subpass counts, different subpasses stamped by the builder
  (via the `Build` method) are guaranteed to be compatible per the rules in the
  spec.
* Pass attachments are now in the `eGeneral` layout. There was no observable
  difference in performance when manually inserting the right transitions.
  Except, a lot of transitions needed to be inserted. If we need it, we can add
  it back in short order. I wouldn't be averse to adding it if reviewers
  insist.
* Additional pipeline state objects need not be created as the sub-pass
  self-dependencies are sufficient to setup the render-pass.
* Speaking of the `rasterization_order_attachment_access` extension, its use has
  been removed in this patch. I am prototyping adding it back to measure the
  overhead introduced by manual subpass management. If the overhead is
  measurable, we can use the extension on devices that have it as an added
  optimization.
* The complexity of command encoding remains linear (to the number of commands)
  per pass.
* This patch only works on a single color attachment being used as an input
  attachment. While this is sufficient for current use cases, the Metal
  implementation is significantly more capable since the multiple attachments
  and attachment types (depth) are already supported. Rounding out support for
  this is in progress.
2024-01-31 23:28:06 +00:00
Ashish Myles
1ee98ba880 Make screen reader announcement append a non-breaking space every other message. (flutter/engine#50151)
This fixes an issue when the same message was sent to the screen reader
again and was not subsequently announced by VoiceOver despite the prior
message having long been removed from the DOM.

Fixes https://github.com/flutter/flutter/issues/142250
2024-01-31 17:30:15 -05:00
skia-flutter-autoroll
2869030de1 Roll Skia from 0ad5b2a9cebd to 19e5e8f089b2 (3 revisions) (flutter/engine#50214)
https://skia.googlesource.com/skia.git/+log/0ad5b2a9cebd..19e5e8f089b2

2024-01-31 kjlubick@google.com Delete legacy MutableTextureState functions
2024-01-31 kjlubick@google.com Add Bazel buffet rules for Vulkan Ganesh backend
2024-01-31 brianosman@google.com Add GM to test dithering image draws

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/skia-flutter-autoroll
Please CC brianosman@google.com,jmbetancourt@google.com,matanl@google.com,rmistry@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Skia: https://bugs.chromium.org/p/skia/issues/entry
To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
2024-01-31 22:09:04 +00:00
Harry Terkelsen
2db9940615 [CanvasKit] Only render one frame at a time. (flutter/engine#50055)
Only have one additional queued frame. If more than one frame is
requested while the current frame is rendering, only the last frame is
queued.

Fixes https://github.com/flutter/flutter/issues/140981

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide] and the [C++,
Objective-C, Java style guides].
- [x] I listed at least one issue that this PR fixes in the description
above.
- [x] I added new tests to check the change I am making or feature I am
adding, or the PR is [test-exempt]. See [testing the engine] for
instructions on writing and running engine tests.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [x] I signed the [CLA].
- [x] All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel
on [Discord].

<!-- Links -->
[Contributor Guide]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#overview
[Tree Hygiene]: https://github.com/flutter/flutter/wiki/Tree-hygiene
[test-exempt]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#tests
[Flutter Style Guide]:
https://github.com/flutter/flutter/wiki/Style-guide-for-Flutter-repo
[C++, Objective-C, Java style guides]:
https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
[testing the engine]:
https://github.com/flutter/flutter/wiki/Testing-the-engine
[CLA]: https://cla.developers.google.com/
[flutter/tests]: https://github.com/flutter/tests
[breaking change policy]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#handling-breaking-changes
[Discord]: https://github.com/flutter/flutter/wiki/Chat
2024-01-31 14:00:08 -08:00
gaaclarke
c35dbe26fc [Impeller] implemented golden image tests for opengles (flutter/engine#50146)
fixes https://github.com/flutter/flutter/issues/142354

This sets up impeller_golden_tests to run with ANGLE.

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-01-31 20:49:40 +00:00
skia-flutter-autoroll
6ae0666bb7 Roll Skia from 647271c1b744 to 0ad5b2a9cebd (2 revisions) (flutter/engine#50208)
https://skia.googlesource.com/skia.git/+log/647271c1b744..0ad5b2a9cebd

2024-01-31 jvanverth@google.com MotionMarkSlide: make sure we enable AA for canvas tests.
2024-01-31 nicolettep@google.com [graphite] Create and store Vulkan pipelines for loading MSAA from resolve

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/skia-flutter-autoroll
Please CC brianosman@google.com,jmbetancourt@google.com,matanl@google.com,rmistry@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Skia: https://bugs.chromium.org/p/skia/issues/entry
To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
2024-01-31 19:48:36 +00:00
Jenn Magder
12dc7ef814 Log FlutterJSONMessageCodec decode errors before asserting (flutter/engine#50163)
Logging JSON decode errors on assertion will help track down bugs.
https://github.com/flutter/flutter/issues/100891#issuecomment-1915946340

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-01-31 17:31:00 +00:00
Mouad Debbar
266c32239f [web] Final nail in FlutterViewEmbedder's coffin (flutter/engine#49769)
- Extracted `ResourceManager` out of `FlutterViewEmbedder`.
- Extracted `GlobalHtmlAttributes` out of `FlutterViewEmbedder`.
- Removed usages of:
    - `FlutterViewEmbedder.reset()`.
    - `flutterViewEmbedder`.
    - `ensureFlutterViewEmbedderInitialized`.
- Deleted `FlutterViewEmbedder`.

Fixes https://github.com/flutter/flutter/issues/134443
2024-01-31 17:22:44 +00:00
skia-flutter-autoroll
d6a71d3e1a Roll Skia from 439a6aae5036 to 053848101c10 (2 revisions) (flutter/engine#50202)
https://skia.googlesource.com/skia.git/+log/439a6aae5036..053848101c10

2024-01-31 yorkiefixer@gmail.com Improve the error report
2024-01-31 drott@chromium.org Minor: Fix comment in Fontations FFI and reformat file

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/skia-flutter-autoroll
Please CC brianosman@google.com,jmbetancourt@google.com,matanl@google.com,rmistry@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Skia: https://bugs.chromium.org/p/skia/issues/entry
To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
2024-01-31 17:15:00 +00:00
skia-flutter-autoroll
373efe3b0f Roll Skia from f916aedaa69b to 439a6aae5036 (4 revisions) (flutter/engine#50201)
https://skia.googlesource.com/skia.git/+log/f916aedaa69b..439a6aae5036

2024-01-31 drott@chromium.org [Fontations-backend] Provide FFI for retrieving number of fonts in TTC
2024-01-31 mike@reedtribe.org refactor freetype common into utils
2024-01-31 skia-autoroll@skia-public.iam.gserviceaccount.com Manual roll Dawn from 748ca55a148e to deb32c4a0943 (5 revisions)
2024-01-31 skia-autoroll@skia-public.iam.gserviceaccount.com Roll vulkan-deps from e3e353f61590 to cfc202524ce6 (2 revisions)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/skia-flutter-autoroll
Please CC brianosman@google.com,jmbetancourt@google.com,matanl@google.com,rmistry@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Skia: https://bugs.chromium.org/p/skia/issues/entry
To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
2024-01-31 16:15:04 +00:00
skia-flutter-autoroll
5b4e1656dc Roll Dart SDK from cd834c2ade57 to fbf1d8ebceb4 (1 revision) (flutter/engine#50199)
https://dart.googlesource.com/sdk.git/+log/cd834c2ade57..fbf1d8ebceb4

2024-01-31 dart-internal-merge@dart-ci-internal.iam.gserviceaccount.com Version 3.4.0-95.0.dev

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/dart-sdk-flutter-engine
Please CC dart-vm-team@google.com,matanl@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Flutter Engine: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
2024-01-31 13:51:34 +00:00
skia-flutter-autoroll
501348944c Roll Fuchsia Linux SDK from Z-xFM2ILZJw22eU8q... to nymRxHV9Shod7cyLe... (flutter/engine#50197)
If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/fuchsia-linux-sdk-flutter-engine
Please CC matanl@google.com,rmistry@google.com,zra@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
2024-01-31 11:07:27 +00:00
skia-flutter-autoroll
92d040787c Roll Dart SDK from 488e33cd39de to cd834c2ade57 (2 revisions) (flutter/engine#50195)
https://dart.googlesource.com/sdk.git/+log/488e33cd39de..cd834c2ade57

2024-01-31 dart-internal-merge@dart-ci-internal.iam.gserviceaccount.com Version 3.4.0-94.0.dev
2024-01-31 dart-internal-merge@dart-ci-internal.iam.gserviceaccount.com Version 3.4.0-93.0.dev

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/dart-sdk-flutter-engine
Please CC dart-vm-team@google.com,matanl@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Flutter Engine: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
2024-01-31 08:28:06 +00:00
zijiehe@
b2d8969566 [Fuchsia] Execute most of the testing/fuchsia/test_suites.yaml on debug and release builds (flutter/engine#50058)
This change implements a BundledTestRunner to run most of the tests in testing/fuchsia/test_suites.yaml as ExecutableTestRunner.

- Tests with packages out of out/fuchsia_*_x64/ are ignored for now.
- Tests with extra test command line parameters are ignored for now.

The BundledTestRunner can share most of the logic in ExecutableTestRunner and avoid reinventing the wheel.

This change also fixes the build break of fuchsia_tests in fuchsia_release_x64 which allows tests to run on the build as well.

- Tests not built with AOT are filtered out with variant field in test_suites.yaml.

Bug: https://github.com/flutter/flutter/issues/140179

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-01-31 05:39:21 +00:00