lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On Tue, May 26, 2020, 05:10 Philippe Verdy <verdyp@gmail.com> wrote:
Later when the hash value is used by truncating some high bits (according to the table size), they remain consecutive: the hashed "main" positions in the table is sequential when short keys of equal size are sequential. This makes it extremely easy to rapidly create long collision lists linking all non-null keys together, so the worse case is evident to reproduce (so all table lookups will use slow full table scans.

Why will we need a full table scan for keys that do not share main positions?