Skip to contentSkip to conversation

rpcauth_lookup_credcache hash size

DISCUSSION Simon Kirby 1 participant 1 message Nov 9, 2010

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

Hello!

Just decided to run "perf top" on a web server which seemed to be CPU-bound and saw this at the top:

             samples  pcnt function                 DSO
             _______ _____ ________________________ __________________

             5261.00 11.9% rpcauth_lookup_credcache [kernel.kallsyms]
             2429.00  5.5% lex_scan                 php4
             2184.00  5.0% thread_group_cputime     [kernel.kallsyms]
             1505.00  3.4% established_get_next     [kernel.kallsyms]
             1083.00  2.5% zendparse                php4
             1055.00  2.4% zend_hash_find           php4
              958.00  2.2% lex_scan                 php5
              905.00  2.1% execute                  php4
              890.00  2.0% memcpy                   /lib/libc-2.7.so

I see this just became configurable, but probably 4 bits (16 buckets?) is probably a bit small for the default, no? (hlist_head is just a pointer, 4 or 8 bytes per bucket, so the default is 128 bytes on x64 :))

I guess it really needs to auto-scale...

Simon-