Re: plan cache overhead on plpgsql expression
Amit Langote <amitlangote09@gmail.com>
From: Amit Langote <amitlangote09@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Pavel Stehule <pavel.stehule@gmail.com>, PostgreSQL Hackers <pgsql-hackers@postgresql.org>
Date: 2020-03-26T10:56:32Z
Lists: pgsql-hackers
On Thu, Mar 26, 2020 at 4:44 AM Tom Lane <tgl@sss.pgh.pa.us> wrote: > > Pavel Stehule <pavel.stehule@gmail.com> writes: > > I'll mark this patch as ready for commiters. > > Thanks for reviewing! Amit, do you have any thoughts on this? Thanks for picking this up. Test cases added by your patch really shows why the plancache and the planner must not be skipped, something I totally failed to grasp. I can't really see any problem with your patch, but mainly due to my unfamiliarity with some of the more complicated things it touches, like resowner stuff. One thing -- I don't get the division between CachedPlanAllowsSimpleValidityCheck() and CachedPlanIsSimplyValid(). Maybe I am missing something, but could there not be just one function, possibly using whether expr_simple_expr is set or not to skip or do, resp., the checks that the former does? -- Thank you, Amit Langote EnterpriseDB: http://www.enterprisedb.com
Commits
-
Rearrange validity checks for plpgsql "simple" expressions.
- fbc7a716084e 13.0 landed
-
Improve performance of "simple expressions" in PL/pgSQL.
- 8f59f6b9c037 13.0 landed
-
Ensure that plpgsql cleans up cleanly during parallel-worker exit.
- 4bfacc5a4411 9.5.22 landed
- deeda011b316 11.8 landed
- dd51b5696aa5 9.6.18 landed
- a54a87320782 12.3 landed
- 86e5badd22d9 13.0 landed
- 42d3649b58f4 10.13 landed