[CFT] x11-servers/xorg-server with initial (GCD) Grand Central Dispatch support

Neil Schroeder gigneil at gmail.com
Wed Apr 23 13:21:10 UTC 2014


Yes you can use callbacks and delegates.

Blocks are much more elegant - they will handle the context and alloc and
derefrencing and a lot of just ugly moving of data.

A block wrapped API  is amazing - you  need to define a block one time per
function - not  per call like a callback -  and you're done. So much less
code.

Callbacks will be faster - although blocks may be optimized enough now to
be materially the same. I would do a little testing.

Will libdispatch itself even build in those older compiler environments ?
 I haven't looked.

On Tuesday, April 22, 2014, Baptiste Daroussin <bapt at freebsd.org> wrote:

> On Sun, Apr 20, 2014 at 08:05:34PM +0300, Ivan Klymenko wrote:
> > Hi all.
> >
> > You are tired of frequent friezes xorg server?
> > Are you bored messages in /var/log/Xorg.0.log:
> > "
> > ...
> > [mi] EQ overflowing.  Additional events will be discarded until existing
> events are processed.
> > ...
> > "
> > ?
> >
> > :)
> >
> > Then you here! :)
> >
> > Patch attached :)
> >
> > If you like, we can continue to develop this area.
> >
> > Thanks
>
>
> Thank you for those patches, imho that is something we really do need. I
> would
> just have a couple of side notes:
> Wouldn't it be possible to use callbacks in the dispatch call rather than
> blocks? that will make the patch work on FreeBSD 8, 9, 10 and head with
> clang
> AND gcc, which will greatly improves the chances to see those patch well
> tested
> and used enough to finally be incorporated in the ports.
>
> regards,
> Bapt
>


More information about the freebsd-x11 mailing list