[Spice-devel] Testing playback of flash videos at 1920x1080 part2

Yaniv Kaul ykaul at redhat.com
Wed Sep 8 02:31:52 PDT 2010


  On 2010-09-08 10:07, Hans de Goede wrote:
> Hi all,
>
> Given the feedback on my previous tests I've been re-running them. 
> Changes:

I forgot the provide some more important feedback - do try with other 
players. Specifically, VLC (VideoLan - http://www.videolan.org/).
Theory (mine):
- Since QEMU exposes Pentium 2 essentially but with SSE2/3/4/whatever, 
software may do either:
(1) look at the vCPU flags, see that there's support for 
SSE2/3/4/whatever, and happily use it
-or-
(2) look at vCPU type, realize that Pentium 2 could never have anything 
more than MMX, and sadly resort to using MMX only.

I've verified (by looking at VLC code) that it does the former, no idea 
what Flash does. In VLC you could also disable the extensions, so we can 
measure if it has drastic effects on the guest CPU usage.

> -now include bandwidth measurement
> -now include guest cpu usage measurements
> -qemu started with -host cpu to enable sse2 - 4, etc in the vm.
> -both uni processor and duo core virtual machine results
> -I've found a bug in the 2.6.35 kernel causing very poor performance
>  with my ati x1950 pro, downgraded to 2.6.34 to take this out of the
>  picture (much lower xorg cpu usage)
>
> The conclusion is unchanged though the biggest bottleneck is the guest
> cpu. It is different then I thought though, it seems that flash is
> using scaled bitmap blitting, so the stretching of video to
> 1920x1080 is not a problem. The software decoding is. Flash videos 
> encoded
> in in resolutions up to 480p work fine. Once you try to play 720p
> videos fullscreen things start falling apart. I have not tried 1080p
> videos.
>
> With uni processor vm's the 720p problem clearly is guest cpu related,
> with duo core processor vm's this is less obvious, but likely still
> the cause. Going beyond 2 cores does not work / help with XP. Still 
> waiting
> for my msdn subscription to be able to build a vm image with windows 7.

Why? You can activate it later when you get the subscription. The key is 
only asked for post installation (unless you don't have the media).
Y.

>
> Here are the results:
>
> -server: F-14 with kernel 2.6.34.6-54.fc13.x86_64, see bug rhbz#630955
>  spice + qemu 0.4, from:
>  git clone 
> git://git.engineering.redhat.com/users/ehabkost/qemu-kvm-rhel6.git 
> --branch rhel6/master
>  git clone git://git.engineering.redhat.com/users/ulublin/spice.git
>  AMD Phenom(tm) II X4 945 Processor
>  4G RAM
>  Guest: 1 "core" cpu, 2G RAM, windows XP + ie8 + flash 10.1 with spice 
> display driver
>         and agent.
>
>  -client: on same machine, Radeon X1950 Pro, fullscreen to 1920x1080
>   - 480 p 4:3 youtube video:
>    qemu cpu load: 110%
>    xorg cpu load:  20%
>    spicec cpu ld:  25%
>    lo bandwidth:    6mbit
>    guest cpu load: 80%
>    frame drop (*):  0
>
>   - 480 p 16:9 youtube video:
>    qemu cpu load: 120%
>    xorg cpu load:  20%
>    spicec cpu ld:  25%
>    lo bandwidth:    6mbit
>    guest cpu load: 80%
>    frame drop: looks smooth (no video info)
>
>   - 720 p 16:9 youtube video:
>    qemu cpu load:  130%
>    xorg cpu load:   20%
>    spicec cpu ld:   25%
>    lo bandwidth:    8-16mbit
>    guest cpu load: 100%
>    frame drop: seems to drop a few frames every sec. (no video info)
>
>  Guest: 2 "core" cpu, 2G RAM, windows XP + ie8 + flash 10.1 with spice 
> display driver
>         and agent.
>
>   - 360 p 16:9 youtube video:
>    qemu cpu load: 130%
>    xorg cpu load:  20%
>    spicec cpu ld:  25%
>    lo bandwidth:   10mbit
>    guest cpu load: 60 + 20%
>    frame drop (*): 0
>
>   - 480 p 4:3 youtube video:
>    qemu cpu load: 130%
>    xorg cpu load:  20%
>    spicec cpu ld:  25%
>    lo bandwidth:    6mbit
>    guest cpu load: 60 + 20%
>    frame drop (*): 0
>
>   - 480 p 16:9 youtube video:
>    qemu cpu load: 140%
>    xorg cpu load:  20%
>    spicec cpu ld:  25%
>    lo bandwidth:    6mbit
>    guest cpu load:
>    frame drop: looks smooth (no video info)
>
>   - 720 p 16:9 youtube video:
>    qemu cpu load:  165%
>    xorg cpu load:  10%
>    spicec cpu ld:  30%
>    lo bandwidth:   9 - 16mbit
>    guest cpu load: 90 + 50%
>    frame drop:     50% (every other frame or so) (no video info)
>
>
> -server: F-14 with kernel 2.6.34.6-54.fc13.x86_64, see bug rhbz#630955
>  spice + qemu-kvm-spice master
>  AMD Phenom(tm) II X4 945 Processor
>  4G RAM
>
>  Guest: 2 "core" cpu, 2G RAM, windows XP + ie8 + flash 10.1 with spice 
> display driver
>         and agent.
>
>   - 360 p 16:9 youtube video:
>    qemu cpu load: 130%
>    xorg cpu load:  20%
>    spicec cpu ld:  25%
>    lo bandwidth:   7mbit
>    guest cpu load: 60 + 20%
>    frame drop (*): 0
>
>   - 480 p 4:3 youtube video:
>    qemu cpu load: 120%
>    xorg cpu load:  15%
>    spicec cpu ld:  20%
>    lo bandwidth:    4mbit
>    guest cpu load: 60 + 20%
>    frame drop (*): 0
>
>   - 480 p 16:9 youtube video:
>    qemu cpu load: 130%
>    xorg cpu load:  15%
>    spicec cpu ld:  20%
>    lo bandwidth:    4mbit
>    guest cpu load: 60 + 35%
>    frame drop: looks smooth (no video info)
>
>   - 720 p 16:9 youtube video:
>    qemu cpu load:  145%
>    xorg cpu load:  10%
>    spicec cpu ld:  25%
>    lo bandwidth:   12mbit
>    guest cpu load: 90 + 50%
>    frame drop:     50% (every other frame or so) (no video info)
>
>
> *) When not moving mouse, etc.
>
>
> ###
>
> Giving the Guest 2 cpu's to try and solve the cpu starvation problem
> results in the flash player inside the guest sometimes hanging
> until it has completely downloaded the movie.
>
> Locking problem? I've seen this only once but we have reports of 5 second
> or longer delays when starting flash video.
>
> Once that is done flash player does use the second cpu,
> but the resulting playback is still dropping frames.
>
>
> Regards,
>
> Hans
> _______________________________________________
> Spice-devel mailing list
> Spice-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/spice-devel



More information about the Spice-devel mailing list