> On 3 Jun 2025, at 10:53 PM, Nathan Bossart <nathandboss...@gmail.com> wrote: > > On Tue, Jun 03, 2025 at 10:39:25PM +0300, Florents Tselai wrote: >> Thanks for the detailed review Nathan > > Thanks for the updated patch! > > + if (rsinfo == NULL || !IsA(rsinfo, ReturnSetInfo)) > + ereport(ERROR, (errmsg("pg_get_dsm_registry_allocations must be used > in a SRF context"))); > > InitMaterializedSRF() takes care of this for you. > > +typedef struct > +{ > + Tuplestorestate *tupstore; > + TupleDesc tupdesc; > +} DSMRegistrySRFContext; > > This appears to be unused. > > +#include "fmgr.h" > +#include "funcapi.h" > +#include "miscadmin.h" > +#include "utils/builtins.h" > > Do we need fmgr.h and miscadmin.h? Also, please alphabetize these into the > existing list of #includes. > > + values[1] = Int64GetDatum(entry->size); > > I think there's a sign mismatch problem here, but it seems implausible in > practice. pg_get_shmem_allocations() does the same thing. > > + <sect1 id="view-pg-dsm-registry-allocations"> > + <title><structname>pg_dsm_registry_allocations</structname></title> > > We need to add an entry into the System Views table in the Overview page, > too. > > -- > nathan
v4-0001-First-attempt-towards-a-pg_dsm_registry-view.-Ite.patch
Description: Binary data
v4-0002-Rename-view-to-pg_dsm_registry_allocations-and-fu.patch
Description: Binary data
v4-0003-Add-doc-entry-for-pg_shmem_allocations_numa.patch
Description: Binary data
v4-0004-Cleanup-includes-in-pg_get_dsm_registry_allocatio.patch
Description: Binary data