Re: resowner "cold start" overhead

From: Andres Freund <andres(at)anarazel(dot)de>
To: Heikki Linnakangas <hlinnaka(at)iki(dot)fi>
Cc: Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: resowner "cold start" overhead
Date: 2022-11-01 00:16:25
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers


On 2022-10-31 11:05:32 +0100, Heikki Linnakangas wrote:
> What do you think of my ResourceOwner refactoring patches [1]? Reminded by
> this, I rebased and added it to the upcoming commitfest again.

> With that patch, all resources are stored in the same array and hash. The
> array is part of ResourceOwnerData, so it saves the allocation overhead,
> like the "initialarr" that you suggested. And it always uses the array for
> recently remembered resources, and spills over to the hash for more
> long-lived resources.
> Andres, could you repeat your benchmark with [1], to see if it helps?
> [1]

Just for future readers of this thread: Replied on the other thread.

It does seem to address the performance issue, but I have some architectural


Andres Freund

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Zhihong Yu 2022-11-01 00:17:03 Re: heavily contended lwlocks with long wait queues scale badly
Previous Message Andres Freund 2022-11-01 00:15:23 Re: ResourceOwner refactoring