On 15.02.23 19:04, Alvaro Herrera wrote:
> That said, I think most of this code is invoked for DDL, where
> performance is not so critical; probably just fixing
> get_object_property_data to not be so naïve would suffice.
Ok, I'll look into that.
> Queries are another matter. I can't think of a way to determine which
> of these paths are used for queries, so that we can optimize more (IOW:
> just plain not rewrite those); manually going through the callers seems
> a bit laborious, but perhaps doable.
The "is visible" functions are only used for the likes of psql, pg_dump,
query tree reversing, object descriptions -- nothing that is in a normal
query unless you explicitly call it.
The get_*_oid() functions are used mostly for DDL to find conflicting
objects. The text-search related ones can be invoked via some user
functions, if you specify a TS object other than the default one. I
will check into what the impact of that is.