Re: General purpose hashing func in pgbench

From: Fabien COELHO <coelho(at)cri(dot)ensmp(dot)fr>
To: Ildar Musin <i(dot)musin(at)postgrespro(dot)ru>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: General purpose hashing func in pgbench
Date: 2017-12-21 15:26:04
Message-ID: alpine.DEB.2.20.1712211620040.32625@lancre
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

> I think it is not commitfest ready yet -- I need to add some
> documentation and tests first.

Yes, doc & test are missing.

From your figures, the murmur2 algorithm output looks way better. I'm
wondering whether it makes sense to provide a bad hash function if a
good/better one is available, unless the bad one actually appears in some
benchmark... So I would suggest to remove fnv1a.

One implementation put constants in defines, the other one uses "const
int". The practice in pgbench seems to use defines (eg
MIN_GAUSSIAN_PARAM...), so I would suggest to stick to this style.

I'm wondering whether "hash" should be a shorthand for one hash functions,
as a provided default chosen for its quality and efficiency.


In response to


Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2017-12-21 15:34:31 Re: force parallel mode vs CTAS
Previous Message Robert Haas 2017-12-21 15:18:05 Re: ddd