Hi, I'm a bit puzzled by this code in SH_COMPUTE_PARAMETERS:
if (tb->size == SH_MAX_SIZE) tb->sizemask = 0; else tb->sizemask = tb->size - 1; Doesn't that mean that with SH_MAX_SIZE we end up with sizemask being 0 (i.e. no bits set)? At least that's what I get from printf("%#x\n", (unsigned int)0); That would mean SH_INITIAL_BUCKET/SH_NEXT/SH_PREV can only ever return bucket 0, no? I don't think we're building hash tables with 2^32 buckets, though. regards -- Tomas Vondra http://www.2ndQuadrant.com PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services