Re: Row pattern recognition

From: Tatsuo Ishii <ishii(at)postgresql(dot)org>
To: assam258(at)gmail(dot)com
Cc: jian(dot)universality(at)gmail(dot)com, zsolt(dot)parragi(at)percona(dot)com, sjjang112233(at)gmail(dot)com, vik(at)postgresfriends(dot)org, er(at)xs4all(dot)nl, jacob(dot)champion(at)enterprisedb(dot)com, david(dot)g(dot)johnston(at)gmail(dot)com, peter(at)eisentraut(dot)org, li(dot)evan(dot)chao(at)gmail(dot)com, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Row pattern recognition
Date: 2026-05-31 00:11:19
Message-ID: 20260531.091119.2213733238436650503.ishii@postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi Henson, Jian,

>> In src/include/nodes/execnodes.h, we're adding quite a few fields to
>> WindowAggState that are only used for RPR queries.
>> Should we consolidate these fields behind a single pointer (named
>> RPRContext) to keep the WindowAggState size smaller for non-RPR
>> queries?
>
> The size win is real -- it's roughly 450-500 bytes per WindowAggState
> that every non-RPR window query carries today. But it takes a wide
> code change to get there: it reshapes every RPR access path, a
> sizable (if mostly mechanical) diff across nodeWindowAgg.c,
> execRPR.c, and the explain side.
>
> Tatsuo, as co-author -- do you want this in v48? If you do, I'll
> prepare the RPRContext consolidation as an incremental patch for you to
> fold into v48. It isn't blocking either way.

Basically I think Jian's idea is good. In addition to the size reason
above, we would have less code changes when we adapt existing R020
codes to R010.

However it will need a wide code change as Henson said. I would like
to focus on stabilizing our code for now. Therefore I would not want
the refactoring in v48.

Regards,
--
Tatsuo Ishii
SRA OSS K.K.
English: http://www.sraoss.co.jp/index_en/
Japanese:http://www.sraoss.co.jp

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tatsuo Ishii 2026-05-31 01:32:58 Re: Row pattern recognition
Previous Message Tomas Vondra 2026-05-30 21:16:21 Re: should we have a fast-path planning for OLTP starjoins?