Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jjH58-00083m-Bn for pgsql-hackers@arkaria.postgresql.org; Thu, 11 Jun 2020 06:52:58 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jjH57-0007lE-8r for pgsql-hackers@arkaria.postgresql.org; Thu, 11 Jun 2020 06:52:57 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jjH57-0007l7-2F for pgsql-hackers@lists.postgresql.org; Thu, 11 Jun 2020 06:52:57 +0000 Received: from lungold.riddles.org.uk ([82.68.208.19]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jjH54-0008EV-Vn for pgsql-hackers@lists.postgresql.org; Thu, 11 Jun 2020 06:52:56 +0000 Received: from [192.168.127.1] (port=44002 helo=caithnard.riddles.org.uk) by lungold.riddles.org.uk with esmtp (Exim 4.92.3 (FreeBSD)) (envelope-from ) id 1jjH51-000Gld-Hm; Thu, 11 Jun 2020 06:52:51 +0000 Received: from localhost ([127.0.0.1]:58989 helo=caithnard.riddles.org.uk) by caithnard.riddles.org.uk with esmtp (Exim 4.93.0.4 (FreeBSD)) (envelope-from ) id 1jjH51-0004NY-DF; Thu, 11 Jun 2020 06:52:51 +0000 From: Andrew Gierth To: David Rowley Cc: PostgreSQL Developers , Andres Freund Subject: Re: Speedup usages of pg_*toa() functions In-Reply-To: (David Rowley's message of "Thu, 11 Jun 2020 15:36:48 +1200") Message-ID: <87y2ou3xuh.fsf@news-spur.riddles.org.uk> References: <87lfkw7eao.fsf@news-spur.riddles.org.uk> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (berkeley-unix) Date: Thu, 11 Jun 2020 07:52:51 +0100 MIME-Version: 1.0 Content-Type: text/plain List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk >>>>> "David" == David Rowley writes: David> Pending any objections, I'd like to push both of these patches David> in the next few days to master. For the second patch, can we take the opportunity to remove the extraneous blank line at the top of pg_ltoa, and add the two missing "extern"s in builtins.h for pg_ultoa_n and pg_ulltoa_n ? David> Anyone object to changing the signature of these functions in David> 0002, or have concerns about allocating the maximum memory that David> we might require in int8out()? Changing the function signatures seems safe enough. The memory thing only seems likely to be an issue if you allocate a lot of text strings for bigint values without a context reset, and I'm not sure where that would happen (maybe passing large bigint arrays to pl/perl or pl/python would do it?) -- Andrew (irc:RhodiumToad)