D-Bus optimizations

Alberto Mardegan mardy at users.sourceforge.net
Mon Feb 27 23:23:52 PST 2012


On 02/27/2012 02:04 PM, Rodrigo Moya wrote:
> Hi
> 
> Just published a blog entry[1] about some recent work we have been doing
> at Collabora to optimize D-Bus. So could you please have a look and
> comment on it?

Avoiding routing all the messages through one process (the D-Bus server)
seems like a huge (at least 2x, I should think) optimization. Not only
because of the data copies which are eliminated, but also for lower
latency and avoiding running into a possible bottleneck when the D-Bus
server is busy processing other messages.

I proposed something similar some time ago[0] (see my message to this ML
dated 28/1/2012), but in that proposal I was not considering multicast
sockets, and instead directly routing all messages in a p2p fashion.
Which approach is better probably depends a lot on the kernel; whether
the kernel is more efficient in routing messages to a single socket (out
of N open sockets), or performing the filtering for a multicast socket.

But in any case, I'm happy to see something moving in this front, so
please keep up the good work! :-)

A few questions:
- Do you have some numbers on the performance?
- What happens if a message is sent to 3 clients, and one of them is
hanging and doesn't read from the socket? Are also other clients
affected, or can they continue receiving more messages?
- Do you create only one multicast group for all clients in a D-Bus
session, or one group per D-Bus service?

Ciao,
  Alberto

[0]: http://www.freedesktop.org/wiki/Software/DBusP2P

-- 
http://blog.mardy.it <- geek in un lingua international!


More information about the dbus mailing list