Optimising xserver (Xft text rendering improvements)

Soeren Sandmann sandmann at daimi.au.dk
Fri Mar 25 12:47:13 PST 2005


Adam Jackson <ajax at nwnk.net> writes:

> > Passing 12 arguments to a function really is a performance killer and I'd
> > like to think this could be kept in mind when further developing xserver
> > (or any software in general!).
> 
> Yes, definitely.  There are lots of places where we do things that are 
> stylistically fine but that don't generate good code at all.  The software 
> Render path is the egregious offender, but there are others.

Before getting rid of those 12 arguments, I'd really like to see
numbers. Usually almost all of the time in the fb layer is spent in
loops in the leaf functions; almost none actually calling the
functions.

One thing that would probably be both a stylisticly and a speed
improvement, would be to get rid of scary if/switch construction in
fbpict.c. Exactly what to do is not completely clear to me though.

> I've got a few ideas about ways to improve the fb layer, and the loadable 
> modules in general:
> 
> https://bugs.freedesktop.org/show_bug.cgi?id=2749
> 
> Like all good changes this has the possibility of breaking an ABI, so I'd 
> appreciate some more eyes on it.  Your changes are complementary to what I've 
> been thinking about so I'd like to merge them in eventually.

These changes make a lot of sense to me. I can't really comment on
whether they break ABI; in the absence of specific objections, the way
to find out is to just go ahead and do it, and see if anything breaks.


Søren



More information about the xorg mailing list