Re: List of Bitmapset (was Re: ExecRTCheckPerms() and many prunable partitions)

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Amit Langote <amitlangote09@gmail.com>
Cc: Richard Guo <guofenglinux@gmail.com>, Alvaro Herrera <alvherre@alvh.no-ip.org>, David Rowley <dgrowleyml@gmail.com>, Greg Stark <stark@mit.edu>, Julien Rouhaud <rjuju123@gmail.com>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2022-11-15T18:25:16Z
Lists: pgsql-hackers
Amit Langote <amitlangote09@gmail.com> writes:
>  On Mon, Nov 14, 2022 at 11:57 PM Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> + * The new member is identified by the zero-based index of the List
>> + * element it should go into, and the bit number to be set therein.

> The comment sounds a bit ambiguous, especially the ", and the bit
> number to be set therein." part.  If you meant to describe the
> arguments, how about mentioning their names too, as in:

Done that way in the patch I just posted.

>> +   /* forboth will stop at the end of the shorter list, which is fine */

> Isn't this comment unnecessary given that the while loop makes both
> lists be the same length?

No, the while loop ensures that a is at least as long as b.
It could have started out longer, though.

			regards, tom lane



Commits

  1. Invent "multibitmapsets", and use them to speed up antijoin detection.