Re: Changes improve the performance of INSERT and UPDATE - Mailing list pgsql-hackers

From Hiroki Kataoka
Subject Re: Changes improve the performance of INSERT and UPDATE
Date
Msg-id 42D9F4BB.3050000@interwiz.koganei.tokyo.jp
Whole thread Raw
In response to Re: Changes improve the performance of INSERT and UPDATE  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Tom Lane wrote:
> Hiroki Kataoka <kataoka@interwiz.koganei.tokyo.jp> writes:
> 
>>This small patch improves the performance of INSERT and UPDATE.  By my
>>machine, these changes raised the performance about 5%~10% in pgbench.
> 
> Wouldn't it be a lot less invasive to search down from the end, instead
> of changing the page header format?

If the last of line pointer array always be free slot, your method is
effective.  But usual line pointer array is full, or worm-eaten after
vacuum, so there is no benefit.

My method is to have the current insertion position of line pointer
array.  This prevents that PageAddItem scan same range of line pointer
array vainly.  A free slot is rarely produced, so it is not necessary to
search from a head (or bottom in your method) each time.

-- 
Hiroki Kataoka <kataoka@interwiz.jp>


pgsql-hackers by date:

Previous
From: "Larry Rosenman"
Date:
Subject: Buildfarm
Next
From: "Pete St. Onge"
Date:
Subject: Re: Buildfarm issues on specific machines