On Fri, Jun 20, 2025 at 04:53:52PM +0530, Rahila Syed wrote: > Thank you for implementing these changes. > The improvements look good and enhance the feature's utility. I have > already started incorporating > GetNamedDSA into my code to display memory context statistics.
Great! Thanks for the reviews. > A potential future enhancement could be allowing GetNamedDSHASH to accept > an existing DSA name. > This would enable the DSHASH to reuse a DSA area instead of creating a new > one each time. > I plan to use this registry to store DSA pointers that all belong to the > same DSA area, and this enhancement > would be particularly beneficial. If you find this idea useful, I would be > interested in working on it. We briefly discussed returning the dshash's DSA upthread [0], and using an existing DSA seems like a variation on that same idea. I'm a little wary of allowing folks to mess with the named dshash internal DSAs. Not only does messing with the DSA introduce some risk of breakage, but it could make it more difficult to change implementation details for the named dshash code in the future. I suppose we could document the expected usage and try to do a few sanity checks, though... [0] https://postgr.es/m/aEmRcAH1Rmaocz3D%40nathan -- nathan