Re: Early WIP/PoC for inlining CTEs
Andrew Gierth <andrew@tao11.riddles.org.uk>
From: Andrew Gierth <andrew@tao11.riddles.org.uk>
To: David Fetter <david@fetter.org>
Cc: pgsql-hackers@postgresql.org
Date: 2018-07-25T15:18:42Z
Lists: pgsql-hackers
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Prevent inlining of multiply-referenced CTEs with outer recursive refs.
- 9476131278c7 12.0 landed
-
Allow user control of CTE materialization, and change the default behavior.
- 608b167f9f9c 12.0 landed
-
Split QTW_EXAMINE_RTES flag into QTW_EXAMINE_RTES_BEFORE/_AFTER.
- 18c0da88a5d9 12.0 landed
-
document when PREPARE uses generic plans
- fab9d1da4a21 9.6.0 cited
>>>>> "David" == David Fetter <david@fetter.org> writes: David> Please find attached a version rebased atop 167075be3ab1547e18 David> with what I believe are appropriate changes to regression test David> output. The other changes to the regression tests output are David> somewhat puzzling, as they change the actual results of queries. Both of those changes are the result of volatile CTEs being inlined more than once (in one case, as part of an explicit test to ensure that CTEs are being materialized and not multiply evaluated). If you look for the XXX comment in the patch, it should be easy to add a check that skips inlining if cterefcount > 1 and contains_volatile_functions is true. -- Andrew (irc:RhodiumToad)