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
Message-ID: 20221101001625.ardg5eman7oiogq2@awork3.anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

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] https://www.postgresql.org/message-id/2e10b71b-352e-b97b-1e47-658e2669cecb@iki.fi

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
concerns.

Greetings,

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