ARC's buf_hash_table is too small
The ARC puts all (non-anonymous) arc_buf_hdr_t's in a hash table, which is
created at system boot time. The hash table is sized such that if all of
physical memory was filled with 64K blocks, the hash chain length would average
<1.0. However, on our system the typical block size is 8k, which can lead to
long hash chain lengths. I've observed average length ~6.5, theoretically it
could be up to 16 (because evicted "ghost" entries are also in the hashtable).
By increasing the hash table size to have enough entries for average length 1.0
when memory is filled with 8k blocks, we can obtain a 18% performance
improvement on cached reads. (680MB/s -> 805MB/s)
The hash table size should also be tunable, rather than hard coded.
Updated by Electric Monk over 5 years ago
- % Done changed from 0 to 100
- Status changed from New to Closed
commit 63e911b6fce0acc8e2a1d31ebdaf0c4c12580a14 Author: Matthew Ahrens <email@example.com> Date: 2014-07-28T05:25:02.000Z 5034 ARC's buf_hash_table is too small Reviewed by: Christopher Siden <firstname.lastname@example.org> Reviewed by: George Wilson <email@example.com> Reviewed by: Saso Kiselkov <firstname.lastname@example.org> Reviewed by: Richard Elling <email@example.com> Approved by: Gordon Ross <firstname.lastname@example.org>