Re: Fix crash when non-creator being an iteration on shared radix tree

From: John Naylor <johncnaylorls(at)gmail(dot)com>
To: Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Fix crash when non-creator being an iteration on shared radix tree
Date: 2025-01-06 06:40:39
Message-ID: CANWCAZYM0ULb3JBz5WXMZW_0HTP9UHv0=Yk7jkm=mXDowWb+MA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Dec 26, 2024 at 11:59 PM Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com> wrote:
> The three patches look good to me.

Thanks for looking! I've pushed them all.

(The failure in drongo seems like an unrelated glitch.)

> > 4. For local memory, an allocated "control object" serves no real
> > purpose and wastes a few cycles on every access. I'm not sure it
> > matters that much as a future micro-optimization, but I mention it
> > here because if we did start allocating outer structs in the callers
> > context, embedding would also remove the need to pfree it.
>
> Using an allocated "control object" can simplify the codes for local
> and shared trees. We cannot embed the control object into
> RT_RADIX_TREE in shared cases. I agree to embed the control data if we
> can implement that cleanly.

I tried this and it was fairly trivial to get working, but it didn't
have the intended effect so I'll leave it alone.

--
John Naylor
Amazon Web Services

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Zhou, Zhiguo 2025-01-06 06:46:03 Re: [RFC] Lock-free XLog Reservation from WAL
Previous Message Ashutosh Bapat 2025-01-06 06:07:43 Re: apply_scanjoin_target_to_paths and partitionwise join