VirtualBox

Ticket #19042 (new defect)

Opened 18 months ago

Last modified 18 months ago

DispatchQueue thread taking up close to 100% CPU

Reported by: wullerdewust Owned by:
Component: GUI Version: VirtualBox 6.0.14
Keywords: Cc:
Guest type: Windows Host type: Mac OS X

Description

With Windows 10 guest in fullscreen mode, I was typing in a guest text field when the guest seemed to freeze. Checking on the Mac OSX host side, VirtualBox was using almost 200% on 2-cpu host (guest is only using 1 CPU). Using the Mac spindump command, I got a dump that showed the DispatchQueue taking up almost all the time, apparently doing Qt updates.

I tried to saved the state of the guest, but VirtualBox crashed. After rebooting the guest, I was able to reproduce the same freeze.

Attachments

VirtualBoxVM_77890.spindump.txt Download (140.3 KB) - added by wullerdewust 18 months ago.
vm-info.txt Download (5.4 KB) - added by wullerdewust 18 months ago.
guest-screenshot.png Download (42.6 KB) - added by wullerdewust 18 months ago.
Guest screenshot at the time of the freeze

Change History

Changed 18 months ago by wullerdewust

Changed 18 months ago by wullerdewust

Changed 18 months ago by wullerdewust

Guest screenshot at the time of the freeze

comment:1 Changed 18 months ago by wullerdewust

I was able to get a screenshot using VBoxManage controlvm VM screenshotpng from the command-line. Canceling the Windows Security windows returns the GUI to normal. It seems to be 100% reproducible.

comment:2 Changed 18 months ago by wullerdewust

According to "VBoxManage metrics collect" and EMT thread in spindump, the guest seems to be using 80% of guest CPU and half of host CPU for some reason.

comment:3 Changed 18 months ago by gombara

Just curious if this is reproducible while entering text at "any" text field on the Guest or just a particular one.

comment:4 Changed 18 months ago by wullerdewust

Just curious if this is reproducible while entering text at "any" text field on the Guest or just a particular one.

So far, just the PIN text field.

But after I paused the Windows search indexer, the guest CPU % went down and the freeze problem went away. So there seems to be a problem with the GUI freezing when the guest CPU is high on MacOS. Maybe it's a thread scheduling problem.

comment:5 Changed 18 months ago by gombara

indexer? well if you are using an indexer on a Window machine you are asking for hangs. good luck with that.

comment:6 Changed 18 months ago by wullerdewust

Yes, it's the built-in Windows search indexer. If I set the guest CPU execution cap to 50%, the freezing is much less. Tomorrow I'll try without the indexer but with high guest CPU from another source, to rule out file I/O.

comment:7 Changed 18 months ago by gombara

The DispatchQueue thingy you mentioned is a part of graphics driver. You can try disabling 3D. But just like you found out, it is not the source of the problem.

comment:8 Changed 18 months ago by wullerdewust

The problem is definitely worse with 3D enabled + Guest Additions experimental 3D support. Even with 3D disabled, there is still a problem, probably because 6.0.14 Guest Additions can't be installed without the 3D support (the checkbox is greyed out).

On the guest side, I can see that GPU usage goes way up when that Windows security window is open, even though there is very little happening on the screen. I suspect that Windows is using the GPU for computation and not graphics. I also suspect that the VirtualBox 3D support is partly asynchronous and that the guest GPU usage effects other host threads. If the host can't keep up with GPU requests, maybe there could be an execution % cap on the GPU like there is on the CPU, or even better, dynamic throttling.

Note: See TracTickets for help on using tickets.

www.oracle.com
ContactPrivacy policyTerms of Use