Re: [HACKERS] SendRowDescriptionMessage() is slow for queries with alot of columns - Mailing list pgsql-hackers

From Andres Freund
Subject Re: [HACKERS] SendRowDescriptionMessage() is slow for queries with alot of columns
Date
Msg-id 20171003075522.e7vmyuwj3gvdryot@alap3.anarazel.de
Whole thread Raw
In response to [HACKERS] SendRowDescriptionMessage() is slow for queries with a lot of columns  (Andres Freund <andres@anarazel.de>)
Responses Re: [HACKERS] SendRowDescriptionMessage() is slow for queries with alot of columns
List pgsql-hackers
Hi,

Attached is a revised version of this patchset. I'd like to get some
input on two points:

1) Does anybody have a better idea than the static buffer in
   SendRowDescriptionMessage()? That's not particularly pretty, but
   there's not really a convenient stringbuffer to use when called from
   exec_describe_portal_message(). We could instead create a local
   buffer for exec_describe_portal_message().

   An alternative idea would be to have one reeusable buffer created for
   each transaction command, but I'm not sure that's really better.

2) There's a lot of remaining pq_sendint() callers in other parts of the
   tree. If others are ok with that, I'd do a separate pass over them.
   I'd say that even after doing that, we should keep pq_sendint(),
   because a lot of extension code is using that.

3) The use of restrict, with a configure based fallback, is something
   we've not done before, but it's C99 and delivers significantly more
   efficient code. Any arguments against?

Regards,

Andres

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Attachment

pgsql-hackers by date:

Previous
From: Magnus Hagander
Date:
Subject: Re: [HACKERS] Possible SSL improvements for a newcomer to tackle
Next
From: Michael Paquier
Date:
Subject: Re: [HACKERS] 64-bit queryId?