RFC: ldconfig speedup

Andreas Jaeger aj@suse.de
Wed Jun 27 15:40:00 GMT 2007


Roland McGrath <roland@redhat.com> writes:

> Probably should use 64-bit fields for ino, dev, size.  

This gives a larger cache.  Using 32-bit might be faster - and I don't
see a collision probable.

> Should use ctime instead of mtime.

Why ctime and not mtime?  Do you think that any modification will not
touch cached information?

> Need to align the table in the file.

> The hack using the reserved header word is cute, nice for compatibility
> paranoia in case of old ld.so's.  OTOH, since only ldconfig uses this info
> it is attractive to use a separate file altogether that only ldconfig knows
> about.  It should be in a proper place like /var/cache, not /etc.  The
> ldconfig cache can store the ctime and size, or signature, or whole
> contents, of ld.so.cache so it can quickly and reliably punt a stale
> incremental cache.

Thanks Jakub and Roland for the suggestions.  

I'm using a separate file now (currently hardcoded to
/etc/ld.so.cache.aux).  What is the right configure variable to get
/var/cache ?

I'm currently hunting down a bug and will send a fixed patch tomorrow,

Andreas
-- 
 Andreas Jaeger, Director Platform / openSUSE, aj@suse.de
  SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg)
   Maxfeldstr. 5, 90409 Nürnberg, Germany
    GPG fingerprint = 93A3 365E CE47 B889 DF7F  FED1 389A 563C C272 A126
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 188 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/libc-alpha/attachments/20070627/194d2755/attachment.sig>


More information about the Libc-alpha mailing list