| Index: content/browser/renderer_host/render_widget_host_view_mac.mm
|
| diff --git a/content/browser/renderer_host/render_widget_host_view_mac.mm b/content/browser/renderer_host/render_widget_host_view_mac.mm
|
| index 6eb9cf4a30950c4ed61febde60ad747fa15ebceb..54bb53ff343c4e10bc39a390b14084d0fff04597 100644
|
| --- a/content/browser/renderer_host/render_widget_host_view_mac.mm
|
| +++ b/content/browser/renderer_host/render_widget_host_view_mac.mm
|
| @@ -909,8 +909,16 @@ void RenderWidgetHostViewMac::WasOccluded() {
|
| if (render_widget_host_->is_hidden())
|
| return;
|
|
|
| - render_widget_host_->WasHidden();
|
| + // SuspendBrowserCompositorView() instructs the GPU process to free up
|
| + // resources such as textures. WasHidden() places the renderer process in the
|
| + // background and throttles its I/O. We're cafeful to call WasHidden() only
|
| + // after calling SuspendBrowserCompositorView(), otherwise the backgrounded
|
| + // and throttled renderer's communication with GPU process will take extra
|
| + // time to complete. The delay will block the foreground renderer's
|
| + // communication with the GPU process, resulting in longer tab switching
|
| + // time. http://crbug.com/502502 .
|
| SuspendBrowserCompositorView();
|
| + render_widget_host_->WasHidden();
|
| }
|
|
|
| void RenderWidgetHostViewMac::SetSize(const gfx::Size& size) {
|
|
|