[Spice-devel] UPDATE: spice-gtk on MAC OSX

Mario ml at kernelobjects.org
Tue Oct 22 17:33:03 CEST 2013


Hi,

bad news related to the OSX Client.

I just finished implementing a SDL "alpha-" backend for the gtk widget. 
as I did not figure out how to draw into an existing window I was 
opening a new windows using SDL and implemented a draw-function for my 
spice-widget-sdl.c that simply takes the pixman data and draws it into 
the SDL window. SDL uses opengl to for accelerated 2d drawing on my OSX 
machine.

Measuring the performance I figuread out that the SDL was in fact faster 
than the quartz backend of cairo. However the look and feel did not 
change at all :(

Even with accelerated rendering there is almost no difference between 
cairo/quartz and sdl/opengl drawing. I was woundering if you had any 
idea how I can proceed. I don´t know the spice client that good to know 
exactly where to look next.


Here you find the opengl variant of my SDL drawing graph:
http://wwwlehre.dhbw-stuttgart.de/~lombardo/spicex_draw_event_opengl.png

Here was the call tree with execution time for the quartz backend:
http://wwwlehre.dhbw-stuttgart.de/~lombardo/exp_call_tree_spicy.png

So I came from 65,9% of processing time to 42,1% for the 
spicex_draw_event() function. But there is absolutely no effect visible 
for the user.

Any hint would be great!

Thanks in advance,
Mario


Am 16.10.2013 10:37, schrieb Mario:
> Hi,
> 
> I just took a look into those functions that are not seem to be
> involved in performance issues. Until today I stopped at the
> gdk_window_update_idle() as this call is suggestive of being innocent.
> I thought it may sleep.
> 
> However this calling thread seem to create the performance issue on 
> OSX.
> 
> Attached you´ll find the time analysis of the spicy client (as png as
> text exports of this software are not really clear).
> 
> Deep inside the gdk_window_update_idle() the drawing function
> spicex_draw_event() is called that actually consumes 65% of the whole
> execution time.
> 
> Inside cairo_fill() the CGContextDrawImage() is called for the quartz
> backend and this seem to be the root of all evil. ;-)
> 
> Is there any other approach to display the spice-widget content to the 
> screen?
> 
> 
> Thanks in advance,
> Mario
> 
> Am 07.10.2013 11:55, schrieb Mario Lombardo:
> Hi,
> I just compiled the spice-gtk client (spicy) on OSX
> (http://www.spice-space.org/page/OSX_Client/Build).
> I am able to connect to the spice server using this client but it is
> more slow than any VNC client I know.
> I looked into the code and found two different places where this
> client seems to be different than the x11 or GDI versions:
> 1.) It uses sw_canvas.c
> 2.) It uses spice-widget-cairo.c
> Is it possible that the slow rendering results in the execution time
> one of those two files? Which investigation would make more sense:
> Would it be better to provide a SDL cairo version or should it
> accelerate the client when there is a canvas option optimized for OSX
> (quarz I guess)? Is it possible to test the gl canvas on OSX? I didn´t
> found anything about the gl implementation in the configure script.
> Thank you.
> Mario
> _______________________________________________
> Spice-devel mailing list
> Spice-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/spice-devel
> 
> _______________________________________________
> 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