Re: Combining hash values - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Combining hash values
Date
Msg-id 6688.1470064924@sss.pgh.pa.us
Whole thread Raw
In response to Re: Combining hash values  (Greg Stark <stark@mit.edu>)
List pgsql-hackers
Greg Stark <stark@mit.edu> writes:
> I was originally going to suggest using a crc  to combine but iirc we
> changed hash_any() a while back and decided against using crc. I don't know
> if that was wise but wouldn't want to suggest relitigating that.

Nah, CRCs are designed to solve a different problem, ie detecting
single-bit and burst errors with high probability.  In particular, I don't
think they make any particular promises with respect to spreading changes
into all bits of the result.  That's important for our hash functions
because we usually take just the lowest N bits of the result as being
adequately randomized.
        regards, tom lane



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Broken order-of-operations in parallel query latch manipulation
Next
From: Peter Eisentraut
Date:
Subject: PostgreSQL 10 kick-off