Re: [PATCH] LockAcquireExtended improvement

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Jingxian Li <aqktjcm(at)qq(dot)com>
Cc: andres <andres(at)anarazel(dot)de>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: [PATCH] LockAcquireExtended improvement
Date: 2024-03-12 13:33:23
Message-ID: CA+TgmoaZNzNywg+jBXOYcsYbF5gdcY8+y5P5FofEEs6uyaN7_A@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Mar 11, 2024 at 11:11 PM Jingxian Li <aqktjcm(at)qq(dot)com> wrote:
> Your version changes less code than mine by pushing the nowait flag down
> into ProcSleep(). This looks fine in general, except for a little advice,
> which I don't think there is necessary to add 'waiting' suffix to the
> process name in function WaitOnLock with dontwait being true, as follows:

That could be done, but in my opinion it's not necessary. The waiting
suffix will appear only very briefly, and probably only in relatively
rare cases. It doesn't seem worth adding code to avoid it.

--
Robert Haas
EDB: http://www.enterprisedb.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Xing Guo 2024-03-12 13:38:23 Disable LLVM bitcode generation with pgxs.mk framework.
Previous Message Aleksander Alekseev 2024-03-12 13:33:20 Re: CF entries for 17 to be reviewed