Re: Two question about performance tuning issue.

From: nconway(at)klamath(dot)dyndns(dot)org (Neil Conway)
To: "Kangmo, Kim" <ilvsusie(at)hahafos(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Two question about performance tuning issue.
Date: 2002-07-26 14:20:28
Message-ID: 20020726142027.GA28152@klamath.dyndns.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Jul 26, 2002 at 03:43:30AM +0900, Kangmo, Kim wrote:
> 2. appendStringInfoChar reallocates every bytes whenever needed,
> why don't reallocate chunk for better performace?

enlargeStringInfo() takes care of that -- from the comment in the
function:

/*
* We don't want to allocate just a little more space with each
* append; for efficiency, double the buffer size each time it
* overflows. Actually, we might need to more than double it if
* 'needed' is big...
*/

Cheers,

Neil

--
Neil Conway <neilconway(at)rogers(dot)com>
PGP Key ID: DB3C29FC

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Roderick A. Anderson 2002-07-26 14:33:43 Re: Password sub-process ...
Previous Message Jan Wieck 2002-07-26 14:11:47 Going on vacation