From: | Dilip Kumar <dilipbalaut(at)gmail(dot)com> |
---|---|
To: | Masahiko Sawada <masahiko(dot)sawada(at)2ndquadrant(dot)com> |
Cc: | Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, Mahendra Singh Thalor <mahi6run(at)gmail(dot)com>, Andres Freund <andres(at)anarazel(dot)de>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>, Michael Paquier <michael(at)paquier(dot)xyz>, Mithun Cy <mithun(dot)cy(at)enterprisedb(dot)com>, Thomas Munro <thomas(dot)munro(at)enterprisedb(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: [HACKERS] Moving relation extension locks out of heavyweight lock manager |
Date: | 2020-03-16 04:12:58 |
Message-ID: | CAFiTN-vuVvcVU6w9VLEQ3P1jrgZkWKGJ2QxBAN4BYhdwCudKWw@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Mon, Mar 16, 2020 at 8:57 AM Masahiko Sawada
<masahiko(dot)sawada(at)2ndquadrant(dot)com> wrote:
>
> On Mon, 16 Mar 2020 at 00:54, Dilip Kumar <dilipbalaut(at)gmail(dot)com> wrote:
> >
> > On Sun, Mar 15, 2020 at 6:20 PM Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> wrote:
> > >
> > > On Sun, Mar 15, 2020 at 4:34 PM Dilip Kumar <dilipbalaut(at)gmail(dot)com> wrote:
> > > >
> > > > I have modified 0001 and 0002 slightly, Basically, instead of two
> > > > function CheckAndSetLockHeld and CheckAndReSetLockHeld, I have created
> > > > a one function.
> > > >
> > >
> > > +CheckAndSetLockHeld(LOCALLOCK *locallock, bool value)
> > >
> > > Can we rename the parameter as lock_held, acquired or something like
> > > that so that it indicates what it intends to do and probably add a
> > > comment for that variable atop of function?
> >
> > Done
> >
>
> I've looked at the patches and ISTM these work as expected.
Thanks for verifying.
> IsRelationExtensionLockHeld and IsPageLockHeld are used only when
> assertion is enabled. So how about making CheckAndSetLockHeld work
> only if USE_ASSERT_CHECKING to avoid overheads?
That makes sense to me so updated the patch.
--
Regards,
Dilip Kumar
EnterpriseDB: http://www.enterprisedb.com
Attachment | Content-Type | Size |
---|---|---|
v10-0001-Assert-that-we-don-t-acquire-a-heavyweight-lock-.patch | application/octet-stream | 4.5 KB |
v10-0003-Allow-relation-extension-lock-to-conflict-among-.patch | application/octet-stream | 3.9 KB |
v10-0004-Allow-page-lock-to-conflict-among-parallel-group.patch | application/octet-stream | 9.2 KB |
v10-0002-Add-assert-to-ensure-that-page-locks-don-t-parti.patch | application/octet-stream | 3.1 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Paquier | 2020-03-16 04:16:05 | Re: allow online change primary_conninfo |
Previous Message | Masahiko Sawada | 2020-03-16 03:53:43 | Re: Berserk Autovacuum (let's save next Mandrill) |