Re: Maybe don't process multi xmax in FreezeMultiXactId() if it is already marked as invalid? - Mailing list pgsql-hackers

From Peter Geoghegan
Subject Re: Maybe don't process multi xmax in FreezeMultiXactId() if it is already marked as invalid?
Date
Msg-id CAH2-WznwPKvmTv_Mo=yOfngcjX-1aus7VhjYWw9LTA5pF4o=yg@mail.gmail.com
Whole thread Raw
In response to Re: Maybe don't process multi xmax in FreezeMultiXactId() if it is already marked as invalid?  (Maxim Orlov <orlovmg@gmail.com>)
Responses Re: Maybe don't process multi xmax in FreezeMultiXactId() if it is already marked as invalid?
List pgsql-hackers
On Tue, Jun 18, 2024 at 10:29 AM Maxim Orlov <orlovmg@gmail.com> wrote:
> Maybe, I'm too bold, but looks like a kinda bug to me.  At least, I don't understand why we do not check the
HEAP_XMAX_INVALIDflag. 
> My guess is nobody noticed, that MultiXactIdIsValid call does not check the mentioned flag in the "first" condition,
butit's all my speculation. 

A related code path was changed in commit 02d647bbf0. That change made
the similar xmax handling that covers XIDs (not MXIDs) *stop* doing
what you're now proposing to do in the Multi path.

Why do you think this is a bug?

> Does anyone know if there are reasons to deliberately ignore the HEAP_XMAX INVALID flag? Or this is just an
unfortunateoversight. 

HEAP_XMAX_INVALID is just a hint.

--
Peter Geoghegan



pgsql-hackers by date:

Previous
From: Ashutosh Sharma
Date:
Subject: Re: Truncation of mapped catalogs (whether local or shared) leads to server crash
Next
From: Andres Freund
Date:
Subject: Re: Meson far from ready on Windows