Re: Separate memory contexts for relcache and catcache

From: Melih Mutlu <m(dot)melihmutlu(at)gmail(dot)com>
To: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Cc: Jeff Davis <pgsql(at)j-davis(dot)com>, torikoshia <torikoshia(at)oss(dot)nttdata(dot)com>, andres(at)anarazel(dot)de, vignesh C <vignesh21(at)gmail(dot)com>, Rahila Syed <rahilasyed90(at)gmail(dot)com>, ashutosh(dot)bapat(dot)oss(at)gmail(dot)com
Subject: Re: Separate memory contexts for relcache and catcache
Date: 2025-02-10 12:41:14
Message-ID: CAGPVpCSZyhwZZ7CmLcK0ww4yiM=JjeWvmiGBxY6dnhTswGGwHA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

I rebased and updated the patch to address some concerns raised before and
see if anyone is still interested in this.

I believe that there is a general consensus around RelCacheContext and
CatCacheContext, considering that these two caches are fairly used. For the
rest, I followed Ashutosh's suggestion [1] and kept Get*CacheContext()
functions. But those functions do not create a separate context, simply use
CacheMemoryContext instead. It'd be easier to change those to actually
create new memory contexts, if it's decided to have more granularity in
CacheMemoryContext in the future.

What are your thoughts?

[1]
https://www.postgresql.org/message-id/CAExHW5sH4NZnHi4S5ai0uFQgfS_R=rts_+LK5JeEQ-dVzwKRfQ@mail.gmail.com

Thanks,
--
Melih Mutlu
Microsoft

Attachment Content-Type Size
v5-0001-Separate-memory-contexts-for-caches.patch application/octet-stream 55.5 KB
v5-0002-Adjusting-cache-memory-context-sizes.patch application/octet-stream 1.7 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message vignesh C 2025-02-10 12:42:12 Re: Introduce XID age and inactive timeout based replication slot invalidation
Previous Message Dilip Kumar 2025-02-10 12:19:49 Re: Conflict detection for update_deleted in logical replication