[PATCH][BZ #15533] Avoid unnecessary slowdown from profiling with audit

Roland McGrath roland@hack.frob.com
Wed Sep 25 20:03:00 GMT 2013


I don't like the O(n) check on every _dl_relocate_object.  I think a better
approach, which would improve performance of all the hooked places and not
just PLT resolution, would be to maintain a set of flags in a bitmask
variable next to _dl_audit.  The setup code in dl_main would set the bit
for a given hook when any audit module defines that hook.  Then all the
places that loop over the _dl_audit list to check if each one has a
particular hook would guard that loop with a check of the bit corresponding
to that hook.


Thanks,
Roland



More information about the Libc-alpha mailing list