Re: [PATCHES] pgstat cleanup: use palloc and AllocateFile
Neil Conway [EMAIL PROTECTED] writes: I changed more_tabstat_space() (which is invoked at various times indirectly throughout the backend) to allocate memory in its own private memory context, rather than use malloc() -- we can't just use CurrentMemoryContext because that may not be sufficiently long-lived. I'd suggest just allocating the tabstat space in TopMemoryContext. The extra sub-context is useless overhead, since you don't actually use it for management purposes. regards, tom lane ---(end of broadcast)--- TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]
Re: [PATCHES] pgstat cleanup: use palloc and AllocateFile
On Thu, 2004-10-28 at 02:20, Tom Lane wrote: I'd suggest just allocating the tabstat space in TopMemoryContext. The extra sub-context is useless overhead, since you don't actually use it for management purposes. I don't know why I didn't think of that :) Patch applied with your suggested change. -Neil ---(end of broadcast)--- TIP 3: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED] so that your message can get through to the mailing list cleanly