Re: [WIP PATCH] for Performance Improvement in Buffer Management - Mailing list pgsql-hackers

From Jeff Janes
Subject Re: [WIP PATCH] for Performance Improvement in Buffer Management
Date
Msg-id CAMkU=1z+Y27cqy0MBfM7eQgt1ev4Px2aBOB5dTOWdRETu=-Q1A@mail.gmail.com
Whole thread Raw
In response to [WIP PATCH] for Performance Improvement in Buffer Management  (Amit kapila <amit.kapila@huawei.com>)
Responses Re: [WIP PATCH] for Performance Improvement in Buffer Management
List pgsql-hackers
On Mon, Sep 3, 2012 at 7:15 AM, Amit kapila <amit.kapila@huawei.com> wrote:
> This patch is based on below Todo Item:
>
> Consider adding buffers the background writer finds reusable to the free
> list
>
>
>
> I have tried implementing it and taken the readings for Select when all the
> data is in either OS buffers
>
> or Shared Buffers.
>
>
>
> The Patch has simple implementation for  "bgwriter or checkpoint process
> moving the unused buffers (unpinned with "ZERO" usage_count buffers) into
> "freelist".

I don't think InvalidateBuffer can be safely used in this way.  It
says "We assume
that no other backend could possibly be interested in using the page",
which is not true here.

Also, do we want to actually invalidate the buffers?  If someone does
happen to want one after it is put on the freelist, making it read it
in again into a different buffer doesn't seem like a nice thing to do,
rather than just letting it reclaim it.

Cheers,

Jeff



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Proof of concept: standalone backend with full FE/BE protocol
Next
From: Tom Lane
Date:
Subject: Re: pg_upgrade del/rmdir path fix