Re: pgsql: Fix planner's use of Result Cache with unique joins

2021-05-23 Thread Tom Lane
David Rowley writes: > Fix planner's use of Result Cache with unique joins Coverity is not happy with this: /srv/coverity/git/pgsql-git/postgresql/src/backend/optimizer/path/joinpath.c: 532 in get_resultcache_path() 526 * determining if the join is unique. 527 * 528 *

pgsql: Be more verbose when the postmaster unexpectedly quits.

2021-05-23 Thread Tom Lane
Be more verbose when the postmaster unexpectedly quits. Emit a LOG message when the postmaster stops because of a failure in the startup process. There already is a similar message if we exit for that reason during PM_STARTUP phase, so it seems inconsistent that there was none if the startup proc

pgsql: Re-order pg_attribute columns to eliminate some padding space.

2021-05-23 Thread Tom Lane
Re-order pg_attribute columns to eliminate some padding space. Now that attcompression is just a char, there's a lot of wasted padding space after it. Move it into the group of char-wide columns to save a net of 4 bytes per pg_attribute entry. While we're at it, swap the order of attstorage and

Re: pgsql: Fix planner's use of Result Cache with unique joins

2021-05-23 Thread David Rowley
On Mon, 24 May 2021 at 02:14, Tom Lane wrote: > Coverity is not happy with this: > This complaint is triggered because elsewhere in the same function, > you're careful to check for inner_path->param_info being null before > trying to dereference it: > > if ((inner_path->param_info == NULL ||

pgsql: Add missing NULL check when building Result Cache paths

2021-05-23 Thread David Rowley
Add missing NULL check when building Result Cache paths Code added in 9e215378d to disable building of Result Cache paths when not all join conditions are part of the parameterization of a unique join failed to first check if the inner path's param_info was set before checking the param_info's ppi