From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com> |
Cc: | Bruce Momjian <bruce(at)momjian(dot)us>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: crash-safe visibility map, take three |
Date: | 2010-12-01 17:23:50 |
Message-ID: | AANLkTi=d=8oJzvLbUmuoDdViSG9O+1uamC3Gj3OUs+r6@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Dec 1, 2010 at 11:40 AM, Heikki Linnakangas
<heikki(dot)linnakangas(at)enterprisedb(dot)com> wrote:
> On 01.12.2010 18:25, Robert Haas wrote:
>>
>> I think we can improve this a bit further by also introducing a
>> HEAP_XMIN_FROZEN bit that we set in lieu of overwriting XMIN with
>> FrozenXID. This allows us to freeze tuples aggressively - if we want
>> - without losing any forensic information. We can then modify the
>> above algorithm slightly, so that when we observe that a page is all
>> visible, we not only set PD_ALL_VISIBLE on the page but also
>> HEAP_XMIN_FROZEN on each tuple.
>
> Hmm, actually, if we're willing to believe PD_ALL_VISIBLE in the page header
> over the xmin/xmax on the tuples, we could simply not bother doing
> anti-wraparound vacuums for pages that have the flag set. I'm not sure what
> changes that would require outside heapam.c, as we'd have to be careful to
> not trust the xmin/xmax if the flag was set.
>
> The first update on the page that clears the flag would need to freeze all
> the tuples in that scheme.
That seems more complex for no particular gain. I guess it saves an
infomask bit, but I'm willing to burn one to reduce code complexity.
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Haas | 2010-12-01 17:31:36 | Re: crash-safe visibility map, take three |
Previous Message | aaliya zarrin | 2010-12-01 17:23:09 | Re: Hi- How frequently Postgres Poll for trigger file |