[LLVMdev] Proposed implementation of N3333 hashing interfaces for LLVM (and possible libc++)
chandlerc at google.com
Tue Feb 28 10:21:04 PST 2012
Will post an updated (and cleaned up, thanks Nadav!) patch shortly, but
wanted to answer this question:
On Tue, Feb 28, 2012 at 7:20 AM, Howard Hinnant <hhinnant at apple.com> wrote:
> On Feb 28, 2012, at 6:34 AM, Chandler Carruth wrote:
> > Howard, high-level feedback from you would be particularly appreciated
> as I would love to contribute this to libc++ when the time is right.
> Does the enclosed implementation implement this part of N3333:
> That to me seems like potentially the most controversial part. I scanned
> Hashing.h but did not immediately see that support (I could've easily
> missed it).
This is definitely the most controversial part, and as such I've separated
it out for implementation purposes. The mechanism to implement this is in
place, but currently it uses a fixed large prime and has a comment about
the plan to potentially switch to a per-execution seed.
(see ::llvm::hashing::detail::get_execution_seed() if you're curious where)
My plan was first to get the interface and implementation worked out, and
then to try flipping on the per-execution seed, seeing what breaks,
tracking down the places we depend on the hash-table ordering, etc.
Hopefully there aren't many places, but that's something we'll learn with
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the llvm-dev