Missing performance tip? Fonts/XFree

Kevin Puetz kde-optimize@mail.kde.org
Sat, 18 Jan 2003 12:56:06 -0600


Maks Orlovich wrote:

oh, something that I should have posted a while back here (not quite ready
to go into fontconfig yet, since fontconfig-opt-cache.patch makes it can
potentially eat a lot of memory when reading a large font cache).

Basically, fontconfig's cache load about twice as fast as before, about 3
times as fast if you're in a pthreads application (like all kde apps are)
because of reduced locking on C stdio (actually, verifying the hunch that
threading is why it helps kde more than standalone is another thing that I
need to do).

http://fontconfig.org/cgi-bin/bugzilla/show_bug.cgi?id=1

>> Are there performace implications with adding
>> more fonts to a system?
> 
> Yes. Adding more Xft fonts affects all apps, since Xft/FontCOnfig read
> font cashes on startup (unless they are really old, as you mentionned, in
> which case Xft will probably do quiet a bit of looking around, too).
> Adding more core fonts affects KHTML and possibly some other apps as well,
> since it needs info on all the fonts on the system for some CSS stuff -
> and XListFonts is
> pretty slow.  (This may disappear when using Xft2, though, in a possible
> future release of Qt, if a certain developer, who shall remain nameless,
> will remember to send a patch to that effect to TT, and if it's accepted
> ;-); also Qt 3.1.x is faster in the handling of the core font listing than
> Qt 3.0.x)
> 
>>  Under all versions of
>> XFree, or just some?
> 
> All, although it may be less with latter versions of X (and Qt).