New issue
Advanced search Search tips

Issue 866914 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Aug 28
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 2
Type: Bug



Sign in to add a comment

resizing window hangs entire desktop with vulkan & x11

Project Member Reported by spang@chromium.org, Jul 24

Issue description

Resizing an x11 window that has a vulkan surface locks up the entire desktop (cinnamon)

Repro steps:

(0) Build content_shell or chrome

(1) Run with flags --enable-features=VizDisplayCompositor,UseSkiaRenderer,UseSkiaDeferredDisplayList,UiGpuRasterization --enable-vulkan --enable-oop-rasterization --enable-gpu-rasterization

(2) Resize the created window
 
gpu-info
88.0 KB View Download
Cc: piman@chromium.org
Owner: penghuang@chromium.org
Status: Assigned (was: Untriaged)
penghaung@ do you think this ought to work?

spang@ could you capture a console trace of Chrome?
Also check what the UI threads of the browser and GPU processes are doing. The whole desktop hanging seems like an X11/wm/driver issues, unless Chrome for some reason grabbed a server lock and didn't release it.
Status: Started (was: Assigned)
I found several facts about this issue:
1. It happens with reducing the window size.
2. It only happens when reducing the window size continually. (Looks like the window is being resizing again, when GPU process is still handling the last resizing).
3. I tried resizing with the vulkan-smoketest (a vulkan test app), it doesn't have this issue.
4. GPU process is blocked at [1], Looks like the GPU is blocked on a pending command buffer which cannot be finished by driver anymore.?

Maybe we should block the resizing in browser process, until the resizing is handled by GPU process.


[1] https://cs.chromium.org/chromium/src/gpu/vulkan/vulkan_swap_chain.cc?type=cs&q=VulkanSwapChain::DestroySwapImages&sq=package:chromium&g=0&l=256

You can't block resize in the browser process, as it happens on the X server, the browser is only notified of the resize.
Project Member

Comment 7 by bugdroid1@chromium.org, Aug 25

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

commit 19159489afebb6e61d089173779ad17f2bcc58cd
Author: Peng Huang <penghuang@chromium.org>
Date: Sat Aug 25 02:17:26 2018

Add a vulkan demo for testing and debugging gpu vulkan code with skia

Bug:  866914 
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
Change-Id: Ib5c6351cbad98221447e5218e54e4feeefb8e692
Reviewed-on: https://chromium-review.googlesource.com/1184968
Reviewed-by: Victor Miura <vmiura@chromium.org>
Reviewed-by: Scott Violet <sky@chromium.org>
Commit-Queue: Peng Huang <penghuang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#586109}
[modify] https://crrev.com/19159489afebb6e61d089173779ad17f2bcc58cd/BUILD.gn
[add] https://crrev.com/19159489afebb6e61d089173779ad17f2bcc58cd/gpu/vulkan/demo/BUILD.gn
[add] https://crrev.com/19159489afebb6e61d089173779ad17f2bcc58cd/gpu/vulkan/demo/DEPS
[add] https://crrev.com/19159489afebb6e61d089173779ad17f2bcc58cd/gpu/vulkan/demo/main.cc
[add] https://crrev.com/19159489afebb6e61d089173779ad17f2bcc58cd/gpu/vulkan/demo/vulkan_demo.cc
[add] https://crrev.com/19159489afebb6e61d089173779ad17f2bcc58cd/gpu/vulkan/demo/vulkan_demo.h

Project Member

Comment 8 by bugdroid1@chromium.org, Aug 28

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

commit 8f6992ac7f1e39303e5fa3e2cf5b47cf58410aa5
Author: Peng Huang <penghuang@chromium.org>
Date: Tue Aug 28 17:46:34 2018

Add VulkanSurface::SetSize() to implement resize.

This method will recreate VulkanSwapChain in VulkanSurface with the new size.
This CL also adds a new param old_swap_chain for VulkanSwapChain::Initialize(),
so we can create a SwapChain correctly.

Bug:  866914 
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
Change-Id: I2042f389c69a591a325f7b530fff1e554cca5e66
Reviewed-on: https://chromium-review.googlesource.com/1184977
Reviewed-by: Robert Kroeger <rjkroege@chromium.org>
Reviewed-by: ccameron <ccameron@chromium.org>
Reviewed-by: Victor Miura <vmiura@chromium.org>
Reviewed-by: Michael Spang <spang@chromium.org>
Commit-Queue: Peng Huang <penghuang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#586776}
[modify] https://crrev.com/8f6992ac7f1e39303e5fa3e2cf5b47cf58410aa5/components/viz/service/display_embedder/skia_output_surface_impl_on_gpu.cc
[modify] https://crrev.com/8f6992ac7f1e39303e5fa3e2cf5b47cf58410aa5/components/viz/service/display_embedder/skia_output_surface_impl_on_gpu.h
[modify] https://crrev.com/8f6992ac7f1e39303e5fa3e2cf5b47cf58410aa5/content/browser/compositor/vulkan_browser_compositor_output_surface.cc
[modify] https://crrev.com/8f6992ac7f1e39303e5fa3e2cf5b47cf58410aa5/gpu/vulkan/demo/vulkan_demo.cc
[modify] https://crrev.com/8f6992ac7f1e39303e5fa3e2cf5b47cf58410aa5/gpu/vulkan/demo/vulkan_demo.h
[modify] https://crrev.com/8f6992ac7f1e39303e5fa3e2cf5b47cf58410aa5/gpu/vulkan/vulkan_surface.cc
[modify] https://crrev.com/8f6992ac7f1e39303e5fa3e2cf5b47cf58410aa5/gpu/vulkan/vulkan_surface.h
[modify] https://crrev.com/8f6992ac7f1e39303e5fa3e2cf5b47cf58410aa5/gpu/vulkan/vulkan_swap_chain.cc
[modify] https://crrev.com/8f6992ac7f1e39303e5fa3e2cf5b47cf58410aa5/gpu/vulkan/vulkan_swap_chain.h

Status: Fixed (was: Started)
Project Member

Comment 10 by bugdroid1@chromium.org, Aug 28

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

commit 5d37f41ffeb10f19d48ffafcd47dc87b41967683
Author: Filip Gorski <fgorski@chromium.org>
Date: Tue Aug 28 17:58:29 2018

Revert "Add VulkanSurface::SetSize() to implement resize."

This reverts commit 8f6992ac7f1e39303e5fa3e2cf5b47cf58410aa5.

Reason for revert: Broke Build
https://ci.chromium.org/p/chromium/builders/luci.chromium.ci/Linux%20Builder%20%28dbg%29%2832%29/87180

Original change's description:
> Add VulkanSurface::SetSize() to implement resize.
> 
> This method will recreate VulkanSwapChain in VulkanSurface with the new size.
> This CL also adds a new param old_swap_chain for VulkanSwapChain::Initialize(),
> so we can create a SwapChain correctly.
> 
> Bug:  866914 
> Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
> Change-Id: I2042f389c69a591a325f7b530fff1e554cca5e66
> Reviewed-on: https://chromium-review.googlesource.com/1184977
> Reviewed-by: Robert Kroeger <rjkroege@chromium.org>
> Reviewed-by: ccameron <ccameron@chromium.org>
> Reviewed-by: Victor Miura <vmiura@chromium.org>
> Reviewed-by: Michael Spang <spang@chromium.org>
> Commit-Queue: Peng Huang <penghuang@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#586776}

TBR=penghuang@chromium.org,rjkroege@chromium.org,spang@chromium.org,ccameron@chromium.org,vmiura@chromium.org

Change-Id: I0d502444e96f68341f35f405d1cb027b21404ad5
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug:  866914 
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
Reviewed-on: https://chromium-review.googlesource.com/1194664
Reviewed-by: Filip Gorski <fgorski@chromium.org>
Commit-Queue: Filip Gorski <fgorski@chromium.org>
Cr-Commit-Position: refs/heads/master@{#586778}
[modify] https://crrev.com/5d37f41ffeb10f19d48ffafcd47dc87b41967683/components/viz/service/display_embedder/skia_output_surface_impl_on_gpu.cc
[modify] https://crrev.com/5d37f41ffeb10f19d48ffafcd47dc87b41967683/components/viz/service/display_embedder/skia_output_surface_impl_on_gpu.h
[modify] https://crrev.com/5d37f41ffeb10f19d48ffafcd47dc87b41967683/content/browser/compositor/vulkan_browser_compositor_output_surface.cc
[modify] https://crrev.com/5d37f41ffeb10f19d48ffafcd47dc87b41967683/gpu/vulkan/demo/vulkan_demo.cc
[modify] https://crrev.com/5d37f41ffeb10f19d48ffafcd47dc87b41967683/gpu/vulkan/demo/vulkan_demo.h
[modify] https://crrev.com/5d37f41ffeb10f19d48ffafcd47dc87b41967683/gpu/vulkan/vulkan_surface.cc
[modify] https://crrev.com/5d37f41ffeb10f19d48ffafcd47dc87b41967683/gpu/vulkan/vulkan_surface.h
[modify] https://crrev.com/5d37f41ffeb10f19d48ffafcd47dc87b41967683/gpu/vulkan/vulkan_swap_chain.cc
[modify] https://crrev.com/5d37f41ffeb10f19d48ffafcd47dc87b41967683/gpu/vulkan/vulkan_swap_chain.h

Project Member

Comment 11 by bugdroid1@chromium.org, Aug 28

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

commit 6a416d164f6890020e7b8248a2090b4c6071bff8
Author: Peng Huang <penghuang@chromium.org>
Date: Tue Aug 28 20:16:30 2018

Reland "Add VulkanSurface::SetSize() to implement resize."

This is a reland of 8f6992ac7f1e39303e5fa3e2cf5b47cf58410aa5

Original change's description:
> Add VulkanSurface::SetSize() to implement resize.
>
> This method will recreate VulkanSwapChain in VulkanSurface with the new size.
> This CL also adds a new param old_swap_chain for VulkanSwapChain::Initialize(),
> so we can create a SwapChain correctly.
>
> Bug:  866914 
> Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
> Change-Id: I2042f389c69a591a325f7b530fff1e554cca5e66
> Reviewed-on: https://chromium-review.googlesource.com/1184977
> Reviewed-by: Robert Kroeger <rjkroege@chromium.org>
> Reviewed-by: ccameron <ccameron@chromium.org>
> Reviewed-by: Victor Miura <vmiura@chromium.org>
> Reviewed-by: Michael Spang <spang@chromium.org>
> Commit-Queue: Peng Huang <penghuang@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#586776}

TBR=rjkroege@chromium.org,spang@chromium.org,ccameron@chromium.org,vmiura@chromium.org

Bug:  866914 
Change-Id: Iaf5a112e5dd169ec62360f0d67c048ae5908e0ee
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
Reviewed-on: https://chromium-review.googlesource.com/1194577
Reviewed-by: Peng Huang <penghuang@chromium.org>
Commit-Queue: Peng Huang <penghuang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#586829}
[modify] https://crrev.com/6a416d164f6890020e7b8248a2090b4c6071bff8/components/viz/service/display_embedder/skia_output_surface_impl_on_gpu.cc
[modify] https://crrev.com/6a416d164f6890020e7b8248a2090b4c6071bff8/components/viz/service/display_embedder/skia_output_surface_impl_on_gpu.h
[modify] https://crrev.com/6a416d164f6890020e7b8248a2090b4c6071bff8/content/browser/compositor/vulkan_browser_compositor_output_surface.cc
[modify] https://crrev.com/6a416d164f6890020e7b8248a2090b4c6071bff8/gpu/vulkan/demo/vulkan_demo.cc
[modify] https://crrev.com/6a416d164f6890020e7b8248a2090b4c6071bff8/gpu/vulkan/demo/vulkan_demo.h
[modify] https://crrev.com/6a416d164f6890020e7b8248a2090b4c6071bff8/gpu/vulkan/vulkan_surface.cc
[modify] https://crrev.com/6a416d164f6890020e7b8248a2090b4c6071bff8/gpu/vulkan/vulkan_surface.h
[modify] https://crrev.com/6a416d164f6890020e7b8248a2090b4c6071bff8/gpu/vulkan/vulkan_swap_chain.cc
[modify] https://crrev.com/6a416d164f6890020e7b8248a2090b4c6071bff8/gpu/vulkan/vulkan_swap_chain.h

Sign in to add a comment