Explanation of Performance monitor graphs

Discussions related to using VirtualBox on Windows hosts.
Post Reply
descott12
Posts: 20
Joined: 14. May 2022, 22:41

Explanation of Performance monitor graphs

Post by descott12 »

Hello,
I am running VB 6.1.34 on a Windows 10 Pro host. Everything is working amazingly well with my XP and Win7 guests. Guest Additions installed, acceleration is enabled and seems to be working well. My question is regarding the performance donut graph.
Usually, my guest load is 50% and my VMM load is around 3 to 4%. What do those actually mean? It appears that I am not using all the CPU/resources available so I am hoping I can decrease some long compile times by tweaking something.
Thanks in advance for any pointers. The user guide is very well written but seems to have skipped this topic.
fth0
Volunteer
Posts: 5668
Joined: 14. Feb 2019, 03:06
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...
Location: Germany

Re: Explanation ofPerformance monitor graphs

Post by fth0 »

Please provide a (zipped) VBox.log file from a complete VM run: Start a VM, run a compilation task for at least 15 minutes and shut down the VM from inside the guest OS. Afterwards, I'll try and explain some of the CPU statistics which relate to your question.
descott12
Posts: 20
Joined: 14. May 2022, 22:41

Re: Explanation ofPerformance monitor graphs

Post by descott12 »

Here you go. The compile seemed to go a bit faster so not sure if it ran for a full 15 minutes.
Thanks alot for looking at this.
Attachments
WinXP-2022-05-28-17-37-20.zip
(29.22 KiB) Downloaded 5 times
fth0
Volunteer
Posts: 5668
Joined: 14. Feb 2019, 03:06
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...
Location: Germany

Re: Explanation ofPerformance monitor graphs

Post by fth0 »

descott12 wrote:The compile seemed to go a bit faster so not sure if it ran for a full 15 minutes.
It wasn't that important. ;) The main idea behind my request was that the majority of VM runtime was used for the compilation, so that the VM statistics roughly correspond to that period of time. Let's have a look at some larger numbers (disk I/O and CPU load):
WinXP-2022-05-28-17-37-20.log wrote:
00:13:08.043486 /Public/Storage/PIIX3IDE0/Port0/BytesRead      508,717,056 bytes
00:13:08.043488 /Public/Storage/PIIX3IDE0/Port0/BytesWritten 1,635,636,224 bytes
00:13:08.043495 /Public/Storage/PIIX3IDE0/Port0/ReqsRead            22,234 count
00:13:08.043502 /Public/Storage/PIIX3IDE0/Port0/ReqsWrite           79,881 count
~22k read requests and ~80k write requests give an impression of the amount of disk I/O involved.
WinXP-2022-05-28-17-37-20.log wrote:
00:13:08.043524 /TM/CPU/00/cNsExecuting          402,709,901,262 ns
00:13:08.043526 /TM/CPU/00/cNsHalted             349,699,481,180 ns
00:13:08.043529 /TM/CPU/00/cNsOther               32,556,659,002 ns
00:13:08.043531 /TM/CPU/00/cNsTotal              784,966,041,444 ns
00:13:08.043534 /TM/CPU/00/cPeriodsExecuting          11,561,453 count
00:13:08.043536 /TM/CPU/00/cPeriodsHalted                524,111 count

00:13:08.043545 /TM/CPU/01/cNsExecuting          251,822,488,811 ns
00:13:08.043547 /TM/CPU/01/cNsHalted             502,072,024,318 ns
00:13:08.043550 /TM/CPU/01/cNsOther               30,591,093,093 ns
00:13:08.043552 /TM/CPU/01/cNsTotal              784,485,606,222 ns
00:13:08.043554 /TM/CPU/01/cPeriodsExecuting          12,827,028 count
00:13:08.043556 /TM/CPU/01/cPeriodsHalted                716,417 count
In the VM statistics for the 2 vCPUs that you've provided to the VM, cNsTotal accumulated the total runtime of ~785 seconds. cNsExecuting accumulated the time when the vCPUs were executing guest code and using host CPU cycles, which was ~1/2 of the time for vCPU0 and ~1/3 of the time for vCPU1. cNsHalted accumulated the time when the vCPUs were halted and not taking host CPU cycles, which was ~1/2 of the time for vCPU0 and ~2/3 of the time for vCPU1. cNsOther accumulated the time when the VirtualBox VMM (Virtual Machine Monitor) executed some code on behalf of the guest, which was less than 5% of the time for both vCPUs (*).

I didn't notice anything unusual in the log file. In general, compilation with many small files can be I/O bound. I'd suggest to use your favorite task manager inside the guest OS to investigate further. Additionally, you could clone the VM and convert the virtual hard disk to the VDI format, which is perhaps implemented more efficiently. Let us know what you discover ... :)

(*) Regarding the VirtualBox Performance Monitor, Guest Load corresponds to cNsExecuting/cNsTotal and VMM Load corresponds to cNsOther/cNsTotal.
descott12
Posts: 20
Joined: 14. May 2022, 22:41

Re: Explanation ofPerformance monitor graphs

Post by descott12 »

Thank you and you explained what the VMM was. That was unclear. Oddly, the compiles seem quite speedy now. For some reason when I first got the VM running, they were about 2x slower. So really I think my problem is solved.
Cheers.
mpack
Site Moderator
Posts: 39156
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Explanation ofPerformance monitor graphs

Post by mpack »

If the VMs were brand new (AFAICS you did not say), then it's a common symptom of brand new Windows installs that they spend a lot of time doing self checks, update checks, etc. We often recommend just leaving the VM running all night to allow everything to settle down.
descott12
Posts: 20
Joined: 14. May 2022, 22:41

Re: Explanation ofPerformance monitor graphs

Post by descott12 »

The VMs were very old and I had transferred them from Parallels on a mac laptop. All seems to be very snappy now so not sure what that was all about.
Thanks
Post Reply