[Spice-devel] multiclient patchset (pre-rfc)
alevy at redhat.com
Mon Nov 29 04:03:31 PST 2010
On Mon, Nov 29, 2010 at 11:00:18AM +0100, Hans de Goede wrote:
> On 11/22/2010 09:11 PM, Alon Levy wrote:
> > This is an update on the multiclient status, as the patches are still not good enough for review and even for RFC, but since Hans asked me and since it would order my thoughts a little, here is the current multiclient status and patches.
> >First, git tree:
> > git://anongit.freedesktop.org/~alon/spice server_multi_client.wip
> > make everything except sound (playback/record) channels use RedChannel in red_channel.h
> > split up inputs_channel.c and main_channel.c from reds.c
> > add ring of RedChannelClient into RedChannel
> > create RedClient to hold ring of channels as well (so every RedChannelClient is doubly linked)
> > pipe logic: each PipeItem has two reference counts, when left_target is zeroed it is removed from the pipe (ring), when refs is zeroed it is released.
> > each RedChannelClient has a pipe pointer. This area still needs some work (that's where windows rendering artifacts are probably from)
> > most of the caches were moved to channel_client state (DisplayChannelClient) (red_worker.c - still left as one file with both cursor and display channel, and worker event loop - not sure we need a separate event loop, or thread for that matter. unless it's a multiple-core-usage issue? or priority issue?).
> > image cache is still left in worker - not sure actually why it works fine with it there (this is the other possible source of rendering artifacts)
> > channels message differs based on amount of clients already connected (just a current policy)
> > fedora and windows boot, go into graphics mode, can connect two clients, first has inputs channel, both have display channel (first has cursor channel as well)
> > agent breaks (crash of qemu)
> > sound not multi-channeled (nothing except main and display, although inputs and cursor should work, just didn't test it)
> > major rendering artifacts in windows (noted above maybe fixes)
> > code is not reviewable (at least everything after channel refactoring)
> > introduced a display test in server/tests, it runs using libtool if you want to debug
> > libtool --mode execute gdb server/tests/test_display_no_ssl
> > builds using automake
> > the tree removes SSL - apparently valgrind really doesn't like openssl, this was the only way I could get relevant information from it. we use SSL for ticketing, so it is always invoked even with no secure port.
> Thanks for the update, not much else to add :)
> Let me know when you've a set of patches which you would like to see merged
> and I'll review it for you.
Since then I found my approach was very problematic for any major changes to the pipe (read - blocker) so I'm rewriting the pipe code by allocating a separate pipe for each client of a channel (instead of a pipe per channel as we have now, which is implicitly also per client per channel). This will take a little more time then I first expected (shocker, I know)..
More information about the Spice-devel