[viz] Allow viz to ack upon activation when interactive [chromium/src : main]

115 views
Skip to first unread message

Ian Vollick (Gerrit)

unread,
Jul 18, 2024, 5:27:06 PM7/18/24
to Jonathan Ross, AyeAye, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, mfoltz...@chromium.org, jophba...@chromium.org, schedule...@chromium.org, asvitki...@chromium.org, asvitkine...@chromium.org, blundell+...@chromium.org, cc-...@chromium.org, jmedle...@chromium.org
Attention needed from Jonathan Ross

Ian Vollick added 4 comments

File chrome/browser/flag-metadata.json
Line 147, Patchset 7: "expiry_milestone": 135
Jonathan Ross . resolved

We should update `draw-immediately-when-interactive` to `135` in a follow up. Currently it targets m129

Ian Vollick

Done and added you as an owner.

File components/viz/service/frame_sinks/compositor_frame_sink_support_unittest.cc
Line 510, Patchset 4: if (ShouldAlwaysAckOnSurfaceActivation() && !BeginFrameAcksEnabled()) {
Jonathan Ross . resolved

For `ShouldAlwaysAckOnSurfaceActivation && BeginFrameAcksEnabled` are we enqueuing the Ack, and the resources. But not forwarding them? Or are we sending the Ack without the resources?

Ian Vollick
I'm not sure if I'm looking at the right thing, but what appears to happen is the following 
- First, we call SubmitCompositorFrame on line 502 above which does indeed cause DidRecieveCompositorFrameAck, but because ShouldMergeBeginFrameWithAcks is true, we don't attempt to return resources (which wouldn't have mattered anyhow, because surface_returned_resources_ is empty at this point -- i.e., we haven't returned the resources yet). The DidReceiveCompositorFrameAck call causes us to increment ack_queued_for_client_count_ which then causes us in UpdateNeedsBeginFrameInternal to set needs_begin_frame_ to true [here](https://source.chromium.org/chromium/chromium/src/+/main:components/viz/service/frame_sinks/compositor_frame_sink_support.cc;l=1279;drc=8d9115add84ccaae3505b2fcb86cc93a53a378ce)
- Next, we call UnrefResources, which indirectly results in CompositorFrameSinkSupport::ReturnResources. However, since we need a begin frame, we don't release the resource [here](https://source.chromium.org/chromium/chromium/src/+/main:components/viz/service/frame_sinks/compositor_frame_sink_support.cc;l=485;drc=8d9115add84ccaae3505b2fcb86cc93a53a378ce), but instead store it away in `surface_returned_resources_`.
- Then, on the next SubmitCompositorFrameWithResources call, we ActivateFrame (which causes us to return resources, but we return nothing).
- It's the MaybeTestOnBeginFrame that ultimately triggers CompositorFrameSinkSupport::OnBeginFrame that plumbs the resources back to FakeCompositorFrameSinkClient::OnBeginFrame
Jonathan Ross

Per offline discussion. The above flow is what we were expecting. The `CheckReturnedResourcesMatchExpected` will catch any errors with caching `surface_returned_resources_`.

Can we add a note here regarding that `UnrefResources` will enqueue the resources in `surface_returned_resources_` for `BeginFrameAcksEnabled`. Regardless of `ShouldAlwaysAckOnSurfaceActivation`

Ian Vollick

I tried. Plmk reopen if my comment is wrong.

File components/viz/service/frame_sinks/surface_synchronization_unittest.cc
Line 3472, Patchset 4: // There should also be an un-acked frame, which was just submitted.
if (ShouldAlwaysAckOnSurfaceActivation()) {
Jonathan Ross . resolved

Are we hitting `Surface::ActivateFrame` in the test due to a lack of surface dependencies? Aka we can activate it immediately upon submission?

Ian Vollick

Yeah, looks like we hit the `if (activation_dependencies_.empty()) {` case in `Surface::CommitFrame`.

Jonathan Ross

Mind adding a note about that?

Ian Vollick

Done

File testing/variations/fieldtrial_testing_config.json
Line 308, Patchset 7: "chromeos_lacros",
Jonathan Ross . resolved

We can remove this. 😞

Ian Vollick

Done

Open in Gerrit

Related details

Attention is currently required from:
  • Jonathan Ross
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement is not satisfiedCode-Review
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: I1875780d946c2bf3304b6f43e428dd1271abeb7c
Gerrit-Change-Number: 5683265
Gerrit-PatchSet: 16
Gerrit-Owner: Ian Vollick <vol...@chromium.org>
Gerrit-Reviewer: Ian Vollick <vol...@chromium.org>
Gerrit-Reviewer: Jonathan Ross <jon...@chromium.org>
Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
Gerrit-CC: gwsq
Gerrit-Attention: Jonathan Ross <jon...@chromium.org>
Gerrit-Comment-Date: Thu, 18 Jul 2024 21:26:57 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Ian Vollick <vol...@chromium.org>
Comment-In-Reply-To: Jonathan Ross <jon...@chromium.org>
satisfied_requirement
unsatisfied_requirement
open
diffy

Ian Vollick (Gerrit)

unread,
Jul 18, 2024, 5:30:02 PM7/18/24
to Jonathan Ross, AyeAye, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, mfoltz...@chromium.org, jophba...@chromium.org, schedule...@chromium.org, asvitki...@chromium.org, asvitkine...@chromium.org, blundell+...@chromium.org, cc-...@chromium.org, jmedle...@chromium.org
Attention needed from Jonathan Ross

Ian Vollick added 2 comments

Patchset-level comments
File-level comment, Patchset 16 (Latest):
Ian Vollick . resolved

Sorry for the churn. Noticed something else to sort out before putting out for real.

File cc/scheduler/scheduler.cc
Line 213, Patchset 16 (Latest): (state_machine_.pending_submit_frames() >= 0));
Ian Vollick . unresolved

Moving back to WIP while I look at this.

Open in Gerrit

Related details

Attention is currently required from:
  • Jonathan Ross
Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I1875780d946c2bf3304b6f43e428dd1271abeb7c
    Gerrit-Change-Number: 5683265
    Gerrit-PatchSet: 16
    Gerrit-Owner: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Jonathan Ross <jon...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: Jonathan Ross <jon...@chromium.org>
    Gerrit-Comment-Date: Thu, 18 Jul 2024 21:29:52 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Jonathan Ross (Gerrit)

    unread,
    Jul 19, 2024, 1:31:37 PM7/19/24
    to Ian Vollick, AyeAye, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, mfoltz...@chromium.org, jophba...@chromium.org, schedule...@chromium.org, asvitki...@chromium.org, asvitkine...@chromium.org, blundell+...@chromium.org, cc-...@chromium.org, jmedle...@chromium.org
    Attention needed from Ian Vollick

    Jonathan Ross added 5 comments

    Patchset-level comments
    File-level comment, Patchset 19 (Latest):
    Jonathan Ross . resolved

    Conceptually SGTM, a few thoughts

    File components/viz/service/surfaces/surface_manager.cc
    Line 39, Patchset 19 (Latest):// If this number of frames (or greater) have elapsed since an interaction, we
    // will stop our early ack on activation behavior. The number chosen here is an
    // arbitrary small number that appears to work.
    constexpr uint64_t kAckOnSurfaceActivationCooldown = 3;
    Line 554, Patchset 19 (Latest):bool SurfaceManager::ShouldAckInteractiveFrame(const BeginFrameAck& ack) const {
    if (!features::ShouldAckOnSurfaceActivationWhenInteractive() ||
    Jonathan Ross . unresolved

    This can be in a loop `CompositorFrameSinkSupport::CheckPendingSurfaces` & `Surface::RecomputeActiveReferencedSurfaces`.

    That's one of the cases where it can be worth caching this flag in a member variable.

    Line 559, Patchset 19 (Latest): if (ack.frame_id < last_interactive_frame_.value()) {
    Jonathan Ross . unresolved

    Could a client be running slower, and the Ack could help?

    Eg: Scrolling Renderer at 60 fps. Other Renderer running at 30 fps, and taking 2 VSync intervals to submit.

    File testing/variations/fieldtrial_testing_config.json
    Line 8727, Patchset 19 (Latest): {
    "name": "EnabledV3",
    "enable_features": [
    "DrawImmediatelyWhenInteractive"
    ]
    },
    {
    "name": "EnabledV2",
    "enable_features": [
    "DrawImmediatelyWhenInteractive"
    ]
    },
    {
    "name": "Enabled",
    "enable_features": [
    "DrawImmediatelyWhenInteractive"
    ]
    }
    Jonathan Ross . unresolved

    Since we turned the early experiments off, and only the topmost variant is ran anyways. We can remove the pre-V4

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Ian Vollick
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I1875780d946c2bf3304b6f43e428dd1271abeb7c
    Gerrit-Change-Number: 5683265
    Gerrit-PatchSet: 19
    Gerrit-Owner: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Jonathan Ross <jon...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: Ian Vollick <vol...@chromium.org>
    Gerrit-Comment-Date: Fri, 19 Jul 2024 17:31:27 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Ian Vollick (Gerrit)

    unread,
    Jul 24, 2024, 12:50:54 PM7/24/24
    to Tricium, Jonathan Ross, AyeAye, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, mfoltz...@chromium.org, jophba...@chromium.org, schedule...@chromium.org, asvitki...@chromium.org, asvitkine...@chromium.org, blundell+...@chromium.org, cc-...@chromium.org, jmedle...@chromium.org
    Attention needed from Jonathan Ross

    Ian Vollick added 5 comments

    File cc/scheduler/scheduler.cc
    Line 213, Patchset 16: (state_machine_.pending_submit_frames() >= 0));
    Ian Vollick . resolved

    Moving back to WIP while I look at this.

    Ian Vollick

    Done

    File components/viz/service/surfaces/surface_manager.cc
    Line 39, Patchset 19:// If this number of frames (or greater) have elapsed since an interaction, we

    // will stop our early ack on activation behavior. The number chosen here is an
    // arbitrary small number that appears to work.
    constexpr uint64_t kAckOnSurfaceActivationCooldown = 3;
    Jonathan Ross . resolved
    Ian Vollick

    Done. I've also added a test to surface_synchronization_unittest.cc that checks that we early-ack when frames either precede the interactive frame or are within the number of cooldown frames.

    Line 554, Patchset 19:bool SurfaceManager::ShouldAckInteractiveFrame(const BeginFrameAck& ack) const {
    if (!features::ShouldAckOnSurfaceActivationWhenInteractive() ||
    Jonathan Ross . unresolved

    This can be in a loop `CompositorFrameSinkSupport::CheckPendingSurfaces` & `Surface::RecomputeActiveReferencedSurfaces`.

    That's one of the cases where it can be worth caching this flag in a member variable.

    Ian Vollick

    Done, though I tried caching this on creation vs lazily-caching the feature value when we use it (to avoid storing things away in functions that seem semantically const). However, some of the tests create the surface manager before the feature-applying-subclass has a chance to update the feature flag. To fix this, I have the classes construct things in SetUp rather than in the test ctor. This results in a fair bit of churn since we now have pointers. Please check this out and let me know if there are issues with setup or teardown.

    Line 559, Patchset 19: if (ack.frame_id < last_interactive_frame_.value()) {
    Jonathan Ross . unresolved

    Could a client be running slower, and the Ack could help?

    Eg: Scrolling Renderer at 60 fps. Other Renderer running at 30 fps, and taking 2 VSync intervals to submit.

    Ian Vollick

    Ah, good point. It makes sense to me that this would be true, then. I've made that change and added a comment. I've also added a test (see above). Wdyt?

    File testing/variations/fieldtrial_testing_config.json

    "name": "EnabledV3",
    "enable_features": [
    "DrawImmediatelyWhenInteractive"
    ]
    },
    {
    "name": "EnabledV2",
    "enable_features": [
    "DrawImmediatelyWhenInteractive"
    ]
    },
    {
    "name": "Enabled",
    "enable_features": [
    "DrawImmediatelyWhenInteractive"
    ]
    }
    Jonathan Ross . resolved

    Since we turned the early experiments off, and only the topmost variant is ran anyways. We can remove the pre-V4

    Ian Vollick

    Done

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Jonathan Ross
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I1875780d946c2bf3304b6f43e428dd1271abeb7c
    Gerrit-Change-Number: 5683265
    Gerrit-PatchSet: 25
    Gerrit-Owner: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Jonathan Ross <jon...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: Jonathan Ross <jon...@chromium.org>
    Gerrit-Comment-Date: Wed, 24 Jul 2024 16:50:46 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Jonathan Ross (Gerrit)

    unread,
    Jul 24, 2024, 3:46:14 PM7/24/24
    to Ian Vollick, Tricium, AyeAye, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, mfoltz...@chromium.org, jophba...@chromium.org, schedule...@chromium.org, asvitki...@chromium.org, asvitkine...@chromium.org, blundell+...@chromium.org, cc-...@chromium.org, jmedle...@chromium.org
    Attention needed from Ian Vollick

    Jonathan Ross added 3 comments

    File components/viz/service/frame_sinks/surface_synchronization_unittest.cc
    Line 3562, Patchset 26 (Latest): // Start by creating a frame with an interaction at frame 10 (interactive is
    // the default).
    Jonathan Ross . unresolved

    I thought we were adding `MakeDefaultInteractiveCompositorFrame` because the default for `CompositorFrameMetadata::is_handling_interaction` was false?

    File components/viz/service/surfaces/surface_manager.cc
    Line 554, Patchset 19:bool SurfaceManager::ShouldAckInteractiveFrame(const BeginFrameAck& ack) const {
    if (!features::ShouldAckOnSurfaceActivationWhenInteractive() ||
    Jonathan Ross . resolved

    This can be in a loop `CompositorFrameSinkSupport::CheckPendingSurfaces` & `Surface::RecomputeActiveReferencedSurfaces`.

    That's one of the cases where it can be worth caching this flag in a member variable.

    Ian Vollick

    Done, though I tried caching this on creation vs lazily-caching the feature value when we use it (to avoid storing things away in functions that seem semantically const). However, some of the tests create the surface manager before the feature-applying-subclass has a chance to update the feature flag. To fix this, I have the classes construct things in SetUp rather than in the test ctor. This results in a fair bit of churn since we now have pointers. Please check this out and let me know if there are issues with setup or teardown.

    Jonathan Ross

    Yeah the test changes work. Init in SetUp is more preferred now due to feature flags.

    Line 559, Patchset 19: if (ack.frame_id < last_interactive_frame_.value()) {
    Jonathan Ross . resolved

    Could a client be running slower, and the Ack could help?

    Eg: Scrolling Renderer at 60 fps. Other Renderer running at 30 fps, and taking 2 VSync intervals to submit.

    Ian Vollick

    Ah, good point. It makes sense to me that this would be true, then. I've made that change and added a comment. I've also added a test (see above). Wdyt?

    Jonathan Ross

    That SGTM

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Ian Vollick
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I1875780d946c2bf3304b6f43e428dd1271abeb7c
    Gerrit-Change-Number: 5683265
    Gerrit-PatchSet: 26
    Gerrit-Owner: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Jonathan Ross <jon...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: Ian Vollick <vol...@chromium.org>
    Gerrit-Comment-Date: Wed, 24 Jul 2024 19:46:01 +0000
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Ian Vollick (Gerrit)

    unread,
    Jul 24, 2024, 5:15:16 PM7/24/24
    to Tricium, Jonathan Ross, AyeAye, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, mfoltz...@chromium.org, jophba...@chromium.org, schedule...@chromium.org, asvitki...@chromium.org, asvitkine...@chromium.org, blundell+...@chromium.org, cc-...@chromium.org, jmedle...@chromium.org
    Attention needed from Jonathan Ross

    Ian Vollick added 1 comment

    File components/viz/service/frame_sinks/surface_synchronization_unittest.cc
    Line 3562, Patchset 26: // Start by creating a frame with an interaction at frame 10 (interactive is
    // the default).
    Jonathan Ross . unresolved

    I thought we were adding `MakeDefaultInteractiveCompositorFrame` because the default for `CompositorFrameMetadata::is_handling_interaction` was false?

    Ian Vollick

    I've updated the comment -- the MakeCompositorFrame function that's being used here is defined at the top of the file and I've modified it to make is_handling_interaction true.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Jonathan Ross
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I1875780d946c2bf3304b6f43e428dd1271abeb7c
    Gerrit-Change-Number: 5683265
    Gerrit-PatchSet: 27
    Gerrit-Owner: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Jonathan Ross <jon...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: Jonathan Ross <jon...@chromium.org>
    Gerrit-Comment-Date: Wed, 24 Jul 2024 21:15:06 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Jonathan Ross <jon...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Jonathan Ross (Gerrit)

    unread,
    Jul 25, 2024, 11:58:56 AM7/25/24
    to Ian Vollick, Tricium, AyeAye, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, mfoltz...@chromium.org, jophba...@chromium.org, schedule...@chromium.org, asvitki...@chromium.org, asvitkine...@chromium.org, blundell+...@chromium.org, cc-...@chromium.org, jmedle...@chromium.org
    Attention needed from Ian Vollick

    Jonathan Ross voted Code-Review+1

    Code-Review+1
    Open in Gerrit

    Related details

    Attention is currently required from:
    • Ian Vollick
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I1875780d946c2bf3304b6f43e428dd1271abeb7c
    Gerrit-Change-Number: 5683265
    Gerrit-PatchSet: 28
    Gerrit-Owner: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Jonathan Ross <jon...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: Ian Vollick <vol...@chromium.org>
    Gerrit-Comment-Date: Thu, 25 Jul 2024 15:58:48 +0000
    Gerrit-HasComments: No
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Jonathan Ross (Gerrit)

    unread,
    Jul 26, 2024, 2:29:43 PM7/26/24
    to Ian Vollick, Tricium, AyeAye, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, mfoltz...@chromium.org, jophba...@chromium.org, schedule...@chromium.org, asvitki...@chromium.org, asvitkine...@chromium.org, blundell+...@chromium.org, cc-...@chromium.org, jmedle...@chromium.org
    Attention needed from Ian Vollick

    Jonathan Ross added 1 comment

    File components/viz/service/frame_sinks/surface_synchronization_unittest.cc
    Line 3562, Patchset 26: // Start by creating a frame with an interaction at frame 10 (interactive is
    // the default).
    Jonathan Ross . resolved

    I thought we were adding `MakeDefaultInteractiveCompositorFrame` because the default for `CompositorFrameMetadata::is_handling_interaction` was false?

    Ian Vollick

    I've updated the comment -- the MakeCompositorFrame function that's being used here is defined at the top of the file and I've modified it to make is_handling_interaction true.

    Jonathan Ross

    😮

    that scares me, but is outside the scope of this review

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Ian Vollick
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Review
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I1875780d946c2bf3304b6f43e428dd1271abeb7c
    Gerrit-Change-Number: 5683265
    Gerrit-PatchSet: 28
    Gerrit-Owner: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Jonathan Ross <jon...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: gwsq
    Gerrit-Attention: Ian Vollick <vol...@chromium.org>
    Gerrit-Comment-Date: Fri, 26 Jul 2024 18:29:33 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    open
    diffy

    Ian Vollick (Gerrit)

    unread,
    Jul 26, 2024, 2:41:31 PM7/26/24
    to Jonathan Ross, Tricium, AyeAye, Chromium LUCI CQ, Chromium Metrics Reviews, chromium...@chromium.org, mfoltz...@chromium.org, jophba...@chromium.org, schedule...@chromium.org, asvitki...@chromium.org, asvitkine...@chromium.org, blundell+...@chromium.org, cc-...@chromium.org, jmedle...@chromium.org

    Ian Vollick voted Commit-Queue+2

    Commit-Queue+2
    Open in Gerrit

    Related details

    Attention set is empty
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Review
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I1875780d946c2bf3304b6f43e428dd1271abeb7c
    Gerrit-Change-Number: 5683265
    Gerrit-PatchSet: 28
    Gerrit-Owner: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Jonathan Ross <jon...@chromium.org>
    Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
    Gerrit-CC: gwsq
    Gerrit-Comment-Date: Fri, 26 Jul 2024 18:41:22 +0000
    Gerrit-HasComments: No
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    open
    diffy

    Chromium LUCI CQ (Gerrit)

    unread,
    Jul 26, 2024, 3:43:39 PM7/26/24
    to Ian Vollick, Jonathan Ross, Tricium, AyeAye, Chromium Metrics Reviews, chromium...@chromium.org, mfoltz...@chromium.org, jophba...@chromium.org, schedule...@chromium.org, asvitki...@chromium.org, asvitkine...@chromium.org, blundell+...@chromium.org, cc-...@chromium.org, jmedle...@chromium.org

    Chromium LUCI CQ submitted the change

    Change information

    Commit message:
    [viz] Allow viz to ack upon activation when interactive

    With this change, we introduce a mode in which we send acks to clients
    when viz surfaces activate and we're "interactive" (that is, we're
    within some number of frames of a frame where we had damage due to
    scrolling or a touch interaction). We expect that this will cause some
    extra / wasted work, but should help regularize the timing of the
    client work since it effectively negates backpressure. That said, it
    is still possible for timing to be irregular (i.e., it's not clear
    how much this helps and this CL does not attempt to quantify this nor
    check via integration test).

    NOTE:
    Earlier patch sets have the tests enabled by default to see which
    tests would break and have attempted to address and parameterize
    affected tests (see patchset 4).

    credit: suggested by jonross@. Jon also noted the cause of the issue
    with a previous attempt (crrev.com/c/5675451) -- that if a dependency
    submitted early, it wouldn't early ack.
    Change-Id: I1875780d946c2bf3304b6f43e428dd1271abeb7c
    Commit-Queue: Ian Vollick <vol...@chromium.org>
    Reviewed-by: Jonathan Ross <jon...@chromium.org>
    Cr-Commit-Position: refs/heads/main@{#1333729}
    Files:
    • M chrome/browser/about_flags.cc
    • M chrome/browser/flag-metadata.json
    • M chrome/browser/flag_descriptions.cc
    • M chrome/browser/flag_descriptions.h
    • M components/viz/common/features.cc
    • M components/viz/common/features.h
    • M components/viz/service/frame_sinks/compositor_frame_sink_support.h
    • M components/viz/service/frame_sinks/compositor_frame_sink_support_unittest.cc
    • M components/viz/service/frame_sinks/frame_sink_manager_impl.h
    • M components/viz/service/frame_sinks/surface_synchronization_unittest.cc
    • M components/viz/service/surfaces/surface_manager.cc
    • M components/viz/service/surfaces/surface_manager.h
    • M components/viz/test/compositor_frame_helpers.cc
    • M components/viz/test/compositor_frame_helpers.h
    • M testing/variations/fieldtrial_testing_config.json
    • M tools/metrics/histograms/enums.xml
    Change size: XL
    Delta: 16 files changed, 819 insertions(+), 335 deletions(-)
    Branch: refs/heads/main
    Submit Requirements:
    • requirement satisfiedCode-Review: +1 by Jonathan Ross
    Open in Gerrit
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: merged
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I1875780d946c2bf3304b6f43e428dd1271abeb7c
    Gerrit-Change-Number: 5683265
    Gerrit-PatchSet: 29
    Gerrit-Owner: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Chromium LUCI CQ <chromiu...@luci-project-accounts.iam.gserviceaccount.com>
    Gerrit-Reviewer: Ian Vollick <vol...@chromium.org>
    Gerrit-Reviewer: Jonathan Ross <jon...@chromium.org>
    open
    diffy
    satisfied_requirement
    Reply all
    Reply to author
    Forward
    0 new messages