lkml.org 
[lkml]   [2017]   [Sep]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] lib: Closed hash table with low overhead
On Mon, 28 Aug 2017 21:53:10 -0400 Felix Kuehling <Felix.Kuehling@amd.com> wrote:

> This adds a statically sized closed hash table implementation with
> low memory and CPU overhead. The API is inspired by kfifo.
>
> Storing, retrieving and deleting data does not involve any dynamic
> memory management, which makes it ideal for use in interrupt context.
> Static memory usage per entry comprises a 32 or 64 bit hash key, two
> bits for occupancy tracking and the value size stored in the table.
> No list heads or pointers are needed. Therefore this data structure
> should be quite cache-friendly, too.
>
> It uses linear probing and lazy deletion. During lookups free space
> is reclaimed and entries relocated to speed up future lookups.

I haven't looked at the implementation (yet), but I'm wondering if you
have identified hash table users (or implementations) elsewhere in the
kernel which might be migrated to use this? If so, such conversions
can be used to determine/demonstrate the desirability of the patch.

\
 
 \ /
  Last update: 2017-09-15 23:16    [W:0.035 / U:6.088 seconds]
©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site