From: | Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com> |
---|---|
To: | Simon Riggs <simon(at)2ndQuadrant(dot)com> |
Cc: | Merlin Moncure <mmoncure(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: How much do the hint bits help? |
Date: | 2010-12-22 14:22:10 |
Message-ID: | 4D120992.60308@enterprisedb.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 22.12.2010 15:59, Simon Riggs wrote:
> On Wed, 2010-12-22 at 15:30 +0200, Heikki Linnakangas wrote:
>> My gut feeling is that a reasonable compromise is to set hint bits like
>> we do today, but don't mark the page as dirty when only hint bits are
>> set. That way you get the benefit of hint bits for tuples that are
>> frequently accessed and stay in buffer cache. But you don't spend any
>> extra I/O to set them. I'd really like to see a worst-case scenario
>> benchmark of a patch that does that.
>
> That sounds great, but still prevents block checksums and that is a very
> valuable feature for robustness.
It does? The problem with block checksums is that if you modify a page
and don't have a corresponding WAL record for it, like a hint bit
update, you can have a torn page so that the checksum doesn't match.
Refraining from dirtying the page when a hint bit is updated avoids the
problem. With that change, we only ever write pages to disk that have a
WAL record associated with it, with full-page images as necessary to
avoid torn pages.
--
Heikki Linnakangas
EnterpriseDB http://www.enterprisedb.com
From | Date | Subject | |
---|---|---|---|
Next Message | Simon Riggs | 2010-12-22 14:52:52 | Re: How much do the hint bits help? |
Previous Message | Andrew Dunstan | 2010-12-22 14:03:47 | Re: SQL/MED - core functionality |