On Mar 25, 2014, at 2:33 PM, Chandler Carruth <[email protected]> wrote:

> 
> On Tue, Mar 25, 2014 at 2:30 PM, Chandler Carruth <[email protected]> 
> wrote:
> Pack the bits of the enum into a 64-bit integer. When we fill the integer, 
> spin up an MD5 context, and shove the integer through it, rinse, repeat. When 
> done, if you have an MD5, take the upper 64-bits. If not, just take the 
> integer.
> 
> As a co-worker who also works on hashing just reminded me, this relies on the 
> fact that none of the enum values are 0, otherwise you end up with 'x' and 
> 'yx' for two sequences which trivially collide.

Right.  I’ll be careful about that.
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to