second thoughts on using dl_iterate_phdr() for cache-validation
David Mosberger
davidm@napali.hpl.hp.com
Fri Nov 5 02:09:00 GMT 2004
>>>>> On Thu, 4 Nov 2004 17:36:25 -0800, Roland McGrath <roland@redhat.com> said:
>> So when should I check back?
Roland> You should take responsibility for the work you want done
Roland> and continue improving it until you've submitted a patch
Roland> that has nothing wrong with it. Please don't pretend there
Roland> is some mystery about how to contribute effectively.
I'm not sure I understand. You said the tree is currently closed for
new interfaces. All I'm asking is when you're expecting the tree to
reopen again.
>> Fine; I don't mind changing it back to "unsigned long int".
Roland> What is the documentation about the meaning of the values
Roland> and the effects of overflow?
As for the meaning of the values, see the documentation in link.h:
----
/* The value returned by this function increments by at least 1 when
objects are added to the list visited by dl_iterate_phdr(). This
function is not serialized with respect to dl_iterate_phdr(). If
serialization is needed, this function should be called from within
a dl_itereate_phdr() callback. */
extern unsigned long int dl_phdr_additions_counter (void);
/* The vaue returned by this function increments by at least 1 when
objects are removed from the list visited by dl_iterate_phdr().
This function is not serialized with respect to dl_iterate_phdr().
If serialization is needed, this function should be called from
within a dl_itereate_phdr() callback. */
extern unsigned long int dl_phdr_removals_counter (void);
----
I'll add a comment about the possibility of overflows.
--david
More information about the Libc-hacker
mailing list