From: David Steele <david@pgmasters.net>
To: Pavan Deolasee <pavan.deolasee@gmail.com>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Bruce Momjian <bruce@momjian.us>
Cc: Amit Kapila <amit.kapila16@gmail.com>
Cc: Alvaro Herrera <alvherre@2ndquadrant.com>
Cc: Jaime Casanova <jaime.casanova@2ndquadrant.com>
Cc: Haribabu Kommi <kommi.haribabu@gmail.com>
Cc: Tomas Vondra <tomas.vondra@2ndquadrant.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: Patch: Write Amplification Reduction Method (WARM)
Date: Tue, 28 Mar 2017 11:32:59 -0400
Message-ID: <9fcbd725-c522-c512-45ed-af6cd2ae4f71@pgmasters.net> (raw)
In-Reply-To: <CA+TgmobxC3D+sRBJGhxKzRk+SAhA7CwR7eeGCYznjeNXUB9hYw@mail.gmail.com>
References: <20170308193038.rl4oe27hb4u4zhx4@alvherre.pgsql>
<CA+Tgmoa7oVYTkDEAzZz2Zw2mwz49orRWV4vYPr6EZ2MP7cioRQ@mail.gmail.com>
<CAA4eK1JeAp3g0-X8X0U87UW3YjNKG3qxR-0-xCTUY=mxT4aOag@mail.gmail.com>
<CA+TgmoYNS3SNjk5DuFZw4E2POSpk+FjmtVqDu9-tOttS1FPgyw@mail.gmail.com>
<CABOikdOdvqJXPATNqmyJMMpYHesQuZm-Y4Q9O033pOwoAyrOjA@mail.gmail.com>
<CA+TgmobKTAN1m8qiZJ+w6L6Kw9CfHrSevhwnrfVPN3KxA6=4KQ@mail.gmail.com>
<20170321164949.GA16918@momjian.us>
<CA+TgmoaSBif2Zr2oQpGgUy5JiVTfhMnA+t50E81rPEyHtbPLog@mail.gmail.com>
<20170321171727.GB16918@momjian.us>
<CABOikdNRB4SuYXBzTvST1vmwDxQo0KwO+1Fukhb2xEiF3uFo4A@mail.gmail.com>
<20170321190000.GE16918@momjian.us>
<CABOikdPpm2AeUsS9=BEs=cUoRV7LS6cMQ+WHBjUzfvO+pctBtw@mail.gmail.com>
<CA+TgmoY3_oy39NmWpfQP9a1HX5cmqvwGC-2ycOtGQ=FAEVFY4w@mail.gmail.com>
<CABOikdPzjJaJ52fwe=0Vxn=syEK_Rs7S6f6K761vwOUNJ4OAUA@mail.gmail.com>
<CA+TgmobxC3D+sRBJGhxKzRk+SAhA7CwR7eeGCYznjeNXUB9hYw@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>
Hi Pavan,
On 3/28/17 11:04 AM, Robert Haas wrote:
> On Mon, Mar 27, 2017 at 10:25 PM, Pavan Deolasee
> <pavan.deolasee@gmail.com> wrote:
>> On Tue, Mar 28, 2017 at 1:59 AM, Robert Haas <robertmhaas@gmail.com> wrote:
>>> On Thu, Mar 23, 2017 at 2:47 PM, Pavan Deolasee
>>> <pavan.deolasee@gmail.com> wrote:
>>>> It's quite hard to say that until we see many more benchmarks. As author
>>>> of
>>>> the patch, I might have got repetitive with my benchmarks. But I've seen
>>>> over 50% improvement in TPS even without chain conversion (6 indexes on
>>>> a 12
>>>> column table test).
>>>
>>> This seems quite mystifying. What can account for such a large
>>> performance difference in such a pessimal scenario? It seems to me
>>> that without chain conversion, WARM can only apply to each row once
>>> and therefore no sustained performance improvement should be possible
>>> -- unless rows are regularly being moved to new blocks, in which case
>>> those updates would "reset" the ability to again perform an update.
>>> However, one would hope that most updates get done within a single
>>> block, so that the row-moves-to-new-block case wouldn't happen very
>>> often.
>>
>> I think you're confusing between update chains that stay within a block vs
>> HOT/WARM chains. Even when the entire update chain stays within a block, it
>> can be made up of multiple HOT/WARM chains and each of these chains offer
>> ability to do one WARM update. So even without chain conversion, every
>> alternate update will be a WARM update. So the gains are perpetual.
>
> You're right, I had overlooked that. But then I'm confused: how does
> the chain conversion stuff help as much as it does? You said that you
> got a 50% improvement from WARM, because we got to skip half the index
> updates. But then you said with chain conversion you got an
> improvement of more like 100%. However, I would think that on this
> workload, chain conversion shouldn't save much. If you're sweeping
> through the database constantly performing updates, the updates ought
> to be a lot more frequent than the vacuums.
>
> No?
It appears that a patch is required to address Amit's review. I have
marked this as "Waiting for Author".
Thanks,
--
-David
david@pgmasters.net
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: david@pgmasters.net, pavan.deolasee@gmail.com, robertmhaas@gmail.com, bruce@momjian.us, amit.kapila16@gmail.com, alvherre@2ndquadrant.com, jaime.casanova@2ndquadrant.com, kommi.haribabu@gmail.com, tomas.vondra@2ndquadrant.com
Subject: Re: Patch: Write Amplification Reduction Method (WARM)
In-Reply-To: <9fcbd725-c522-c512-45ed-af6cd2ae4f71@pgmasters.net>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox