Add support for 32-bit hashers to F14Table
commitd7617c48bbdab25537958581621a20a8ddce0107
authorOrvid King <orvid@meta.com>
Wed, 9 Nov 2022 05:05:52 +0000 (8 21:05 -0800)
committerFacebook GitHub Bot <facebook-github-bot@users.noreply.github.com>
Wed, 9 Nov 2022 05:05:52 +0000 (8 21:05 -0800)
tree9b5d7ab9424dad20a34a1367f85a3a9b41e2385d
parent16eca146bf7529343c88bd213fbf8f982ea1e0b5
Add support for 32-bit hashers to F14Table

Summary: There are a few scenarios where it's faster or easier to get or store a 32-bit hash than a 64-bit one, so this adds a way to explicitly mark a hasher as 32-bit, which will cause F14 to grab the tag from the lower 32-bits rather than the top.

Reviewed By: Gownta

Differential Revision: D40737811

fbshipit-source-id: 1c337c2fa56bbb4e1697e2da43bc6915eee31191
third-party/folly/src/folly/container/F14Set.h
third-party/folly/src/folly/container/detail/F14Policy.h
third-party/folly/src/folly/container/detail/F14Table.h
third-party/folly/src/folly/container/test/F14PolicyTest.cpp [new file with mode: 0644]