Skip to content

[fuchsia] move VsyncWaiter out of the UI thread; delete VsyncRecorder #81984

@farchond

Description

@farchond

Currently, SessionConnection which talks with Scenic is running on the raster thread. This is therefore the thread where we receive presentation information, including OnVsync() events. It is possible today to move VsyncWaiter to the raster thread, by creating a weak factory there instead of on the UI thread where it currently exists. However, when testing this change out I noticed a significant decrease in performance because the raster thread is overutilized, especially by GPURasterizer::Draw events. This means that Flutter has a delay in starting frames, leading to noticeably less FPS.

There are two ways to unblock this problem:

  1. Fix the overutilization of the raster thread.
  2. Switch both SessionConnection and VsyncWaiter to the platform thread, which is necessary for Flatland integration anyway. @arbreng is working on this.

When this change happens and SessionConnection and VsyncWaiter are on the same thread, then we can also remove VsyncRecorder, as it'd have no purpose. Its logic could be encapsulated by SessionConnection.

Metadata

Metadata

Assignees

Labels

Bot is counting down the days until it unassigns the issueP2Important issues not at the top of the work listengineflutter/engine related. See also e: labels.platform-fuchsiaFuchsia code specificallyteam-engineOwned by Engine teamtriaged-engineTriaged by Engine team

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions