Re: VACUUM (DISABLE_PAGE_SKIPPING on) - Mailing list pgsql-hackers

From Simon Riggs
Subject Re: VACUUM (DISABLE_PAGE_SKIPPING on)
Date
Msg-id CANP8+jLL-Ygr306tbbqD+MmsKXMrJcV8PmjeJvd7w216BX7mMg@mail.gmail.com
Whole thread Raw
In response to Re: VACUUM (DISABLE_PAGE_SKIPPING on)  (Alvaro Herrera <alvherre@alvh.no-ip.org>)
Responses Re: VACUUM (DISABLE_PAGE_SKIPPING on)  (Masahiko Sawada <sawada.mshk@gmail.com>)
List pgsql-hackers
On Fri, 20 Nov 2020 at 15:29, Alvaro Herrera <alvherre@alvh.no-ip.org> wrote:
>
> Note on heap_prepare_freeze_tuple()'s fifth parameter, it's not valid to
> pass OldestXmin; you need a multixact limit there, not an Xid limit.  I
> think the return value of GetOldestMultiXactId is a good choice.  AFAICS
> this means that you'll need to add a new output argument to
> vacuum_set_xid_limits (You *could* call GetOldestMultiXactId again, but
> it seems a waste).
>
> Maybe it's time for vacuum_set_xid_limits to have a caller's-stack-
> allocated struct for input and output values, rather than so many
> arguments and output pointers to fill.

The idea was to maximise freezing because we are already dirtying this
data block, so the reasoning doesn't extend directly to multixacts.
Being more active with multixacts could easily cause more churn there.

So I'm changing the patch to only work with Xids not both xids and
multixacts. If this gets committed we can think more about multixacts
and whether to optimize freezing them in the same situation or not.

-- 
Simon Riggs                http://www.EnterpriseDB.com/

Attachment

pgsql-hackers by date:

Previous
From: Simon Riggs
Date:
Subject: Re: VACUUM (DISABLE_PAGE_SKIPPING on)
Next
From: Alexander Korotkov
Date:
Subject: Re: Improving spin-lock implementation on ARM.