Gil,

Apologies as I missed the point of your question. Any prime will generally give 
a good distribution. But a Mersenne Prime allows you to avoid a divide. 

Tom

Sent from my iPhone

> On Feb 23, 2022, at 4:37 PM, Paul Gilmartin 
> <[email protected]> wrote:
> 
>> On Feb 23, 2022, at 14:00:21, Tom Harper wrote:
>> 
>> Your best bet is a dynamic hash table of size of an appropriate Mersenne 
>> Prime. The fastest effective way to hash your key is using the CKSM 
>> instruction. Although fast, it does produce more synonyms than other hash 
>> techniques. 
>> 
> Why a Mersenne Prime?  The first thing I find is:
> <https://www.quora.com/How-are-Mersenne-primes-used>
>    The key is that you can compute x mod p really fast if p is a Mersenne 
> prime.
> 
> Is this a significant advantage on z hardware?
> 
> Are name/token services, IEANTCR/IEANTRT useful here?
> 
> -- 
> gil


--------------------------------------------------------------------------------
This e-mail message, including any attachments, appended messages and the
information contained therein, is for the sole use of the intended
recipient(s). If you are not an intended recipient or have otherwise
received this email message in error, any use, dissemination, distribution,
review, storage or copying of this e-mail message and the information
contained therein is strictly prohibited. If you are not an intended
recipient, please contact the sender by reply e-mail and destroy all copies
of this email message and do not otherwise utilize or retain this email
message or any or all of the information contained therein. Although this
email message and any attachments or appended messages are believed to be
free of any virus or other defect that might affect any computer system into
which it is received and opened, it is the responsibility of the recipient
to ensure that it is virus free and no responsibility is accepted by the
sender for any loss or damage arising in any way from its opening or use.

Reply via email to