On 9/1/24 18:49, David Rowley wrote:
adf97c156 added support to allow ExprStates to support hashing and
adjusted Hash Join to make use of that. That allowed a speedup in hash
value generation as it allowed JIT compilation of hash values. It also
allowed more efficient tuple deforming as all required attributes are
deformed in one go rather than on demand when hashing each join key.

The attached does the same for GROUP BY and hashed SubPlans. The win
for the tuple deformation does not exist here, but there does seem to
be some gains still to be had from JIT compilation.

Using a scale=1 TPC-H lineitem table, I ran the attached script.

The increase is far from impressive, but likely worth migrating these
over to use ExprState too.
Having remembered that SQL Server uses lightweight threads to execute massive hash and aggregate operations in parallel, I think this patch is promising. Unfortunately, it causes SEGFAULT on 'make check'.

--
regards, Andrei Lepikhov



Reply via email to