Re: [WIP PATCH] for Performance Improvement in Buffer Management

From: Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
To: Amit kapila <amit(dot)kapila(at)huawei(dot)com>
Cc: "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [WIP PATCH] for Performance Improvement in Buffer Management
Date: 2012-09-03 19:12:14
Message-ID: CAMkU=1z+Y27cqy0MBfM7eQgt1ev4Px2aBOB5dTOWdRETu=-Q1A@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Sep 3, 2012 at 7:15 AM, Amit kapila <amit(dot)kapila(at)huawei(dot)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

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2012-09-03 19:22:31 Re: pg_upgrade del/rmdir path fix
Previous Message Tom Lane 2012-09-03 19:10:22 Re: Proof of concept: standalone backend with full FE/BE protocol