On Wed, May 17, 2023 at 11:10 AM Tom Lane <tgl@sss.pgh.pa.us> wrote:
* I'm not terribly happy with 0004 as it stands, specifically the business of making build_join_rel recalculate pushed_down_ojrelids from scratch. Again, that's adding cycles to the mainline case to support an unusual case. It'd be better to make add_outer_joins_to_relids have an extra output that is the pushed_down_ojrelids set, and pass that forward. I ran out of time to make that happen today, though.
A little difference is that that patch makes add_outer_joins_to_relids collect pushed down joins rather than pushed down ojrelids, so that in build_joinrel_tlist we can just loop over pushed down joins rather than the whole join_info_list.
I rebased that patch on the v6 patch series and that is 0006 in the attachment.
* While I've not done it here, I'm seriously considering reverting those Asserts in setrefs.c back to somewhat-informative elogs, at least till late in beta. It seems like we are still at a point where we need to make it easy to acquire info about failures in this logic, and using Asserts isn't all that conducive to that.
Agreed. While debugging in my local branch I usually replace the related Asserts with elogs, to avoid frequent server crashes and to make it easy for attaching to a live process with gdb.