New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 819611 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: Jun 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Task



Sign in to add a comment

Use surface synchronization for OOPIF desktop zoom

Project Member Reported by fsam...@chromium.org, Mar 7 2018

Issue description

OOPIF introduces a somewhat annoying desktop zoom synchronization regression. iframes tend to respond to zoom faster than the top level renderer which results in a bunch of bouncing around of frames during zoom. This didn't happen prior to site isolation.

In the interest of product excellence, I would recommend wiring up desktop zoom to surface synchronization (especially now that surface sync is on in M65 stable).
 
Cc: piman@chromium.org
Description: Show this description

Comment 3 by piman@chromium.org, Mar 9 2018

Labels: -Type-Bug Type-Task
Status: Available (was: Untriaged)
Owner: akaba@google.com
Project Member

Comment 5 by bugdroid1@chromium.org, Jun 25 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/c6bd1218e88d15c43a495a638c8cd65105c146e4

commit c6bd1218e88d15c43a495a638c8cd65105c146e4
Author: akaba <akaba@google.com>
Date: Mon Jun 25 20:10:48 2018

Use Surface Synchronization for desktop zoom.

This CL rewires zoom to use surface synchronization instead of page messages which solves the problem of OOPIFs zooming faster than their embedding frame,
In other words this allows zoom to be executed atomically for a web page containing OOPIFs.

Design Doc (Draft): https://docs.google.com/document/d/1J7BTRsylGApm6KHaaTu-m6LLvSWJgf1B9CM-USKIp1k/edit?usp=sharing

Bug:  819611 , 672962 
Change-Id: Ifc61b47886fd8ebd99c98851442b9caf59905413
Reviewed-on: https://chromium-review.googlesource.com/1095557
Commit-Queue: Andre Kaba <akaba@google.com>
Commit-Queue: Fady Samuel <fsamuel@chromium.org>
Reviewed-by: Charlie Reis <creis@chromium.org>
Reviewed-by: Fady Samuel <fsamuel@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Cr-Commit-Position: refs/heads/master@{#570143}
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/browser_plugin/browser_plugin_guest.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/browser_plugin/browser_plugin_guest.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/frame_host/cross_process_frame_connector.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/frame_host/cross_process_frame_connector.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/host_zoom_map_impl.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/host_zoom_map_impl.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/renderer_host/render_view_host_delegate.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/renderer_host/render_view_host_delegate.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/renderer_host/render_view_host_impl.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/renderer_host/render_widget_host_delegate.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/renderer_host/render_widget_host_delegate.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/renderer_host/render_widget_host_impl.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/renderer_host/render_widget_host_unittest.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/web_contents/web_contents_impl.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/browser/web_contents/web_contents_impl.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/common/BUILD.gn
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/common/frame_messages.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/common/frame_visual_properties.h
[delete] https://crrev.com/216b806d4d01e50a729039219f693184b1896ef6/content/common/page_message_enums.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/common/page_messages.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/common/renderer.mojom
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/common/view_messages.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/common/visual_properties.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/public/renderer/render_frame.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/public/renderer/render_view.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/renderer/browser_plugin/browser_plugin.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/renderer/browser_plugin/browser_plugin.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/renderer/render_frame_impl.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/renderer/render_frame_impl.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/renderer/render_frame_proxy.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/renderer/render_frame_proxy.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/renderer/render_view_browsertest.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/renderer/render_view_impl.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/renderer/render_view_impl.h
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/renderer/render_widget.cc
[modify] https://crrev.com/c6bd1218e88d15c43a495a638c8cd65105c146e4/content/renderer/render_widget.h

Comment 6 by akaba@google.com, Jun 28 2018

Status: Fixed (was: Available)

Comment 7 by creis@chromium.org, Jun 28 2018

akaba@: Thanks for the fix!  However, I'm not actually seeing the improvement I expected in Windows Chrome Canary 69.0.3475.0, which includes your fix.  Maybe you can help clarify what I should be looking for?

Repro steps I'm trying:
1) Start Chrome with Site Isolation enabled.
2) Visit http://csreis.github.io/tests/cross-site-iframe.html.
3) Click "Go cross-site (complex page)".
4) Use Ctrl + and Ctrl - to change the zoom level of the page.

I expected the whole page to adjust the new zoom level at once with each change.  However, I'm still seeing clear separate stages where the main frame changes zoom, and later the iframe catches up.  This is most visible when increasing the zoom, since there's a gutter around the right side and bottom in the iframe until the iframe resizes itself.

Is that still expected, even with surface sync for zoom?
This is expected behavior actually. There is a deadline set here:

https://cs.chromium.org/chromium/src/content/renderer/browser_plugin/browser_plugin.cc?sq=package:chromium&g=0&l=298

Currently, we will use the default deadline: 4 frames. We can increase the deadline if zoom is involved. That'll address this case.

What we guarantee now is the child will never get ahead of the parent, and if the child takes more than 4 frames to zoom and the parent is already done, we will gutter the child.

Comment 9 by creis@chromium.org, Jun 28 2018

Interesting, thanks.  Also, sounds like you're using slashdot.org as a test case, and I can confirm that I see a big improvement when zooming that on Canary vs Stable.  Nicely done!
Maybe as a followup bug we can increase the deadline just for zoom synchronization events. 

Sign in to add a comment