[Adium-devl] Bonjour ToDos

Evan Schoenberg evan.s at dreskin.net
Fri Sep 14 12:15:11 UTC 2007


On Sep 14, 2007, at 1:32 AM, Colin Barrett wrote:

>> 2.)  Evan emailed me asking whether libezv still needs to run in it's
>> own thread.  After talking with him and doing a little research I
>> have moved libezv out of its own thread, however, this entails
>> altering the process for outgoing file transfers.  Unfortunately,
>> this requires a rewrite of nearly the entire outgoing transfer
>> process so this could take a week or two.  I have already begun
>> looking into this.
>
> What exactly does moving libezv onto the main thread buy us?

1) Reduces overhead.  Needless thread switching is expensive; if all  
calls are non-blocking and individually cheap, there's no reason to be  
moving outgoing method calls to a secondary thread and then move  
incoming method calls back to the main thread.
2) Prevents crashiness.  http://smartcrashreports.com/dev/?q=NDRunLoopMessenger&r=all 
  shows a bunch of crashes in the intrathread messaging class... all  
of which are connected to Bonjour.  I've spent a long time in the past  
trying to figure out what's going on with these sporadic crashes, to  
no avail.
3) Code simplification

-Evan




More information about the devel mailing list