Re: [HACKERS] Moving relation extension locks out of heavyweight lock manager
От | Dilip Kumar |
---|---|
Тема | Re: [HACKERS] Moving relation extension locks out of heavyweight lock manager |
Дата | |
Msg-id | CAFiTN-siwdzOkhQhGf0wnic7-QmTqSkqp9uv_YrzJs2_-sVSAw@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: [HACKERS] Moving relation extension locks out of heavyweight lock manager (Amit Kapila <amit.kapila16@gmail.com>) |
Ответы |
Re: [HACKERS] Moving relation extension locks out of heavyweight lock manager
|
Список | pgsql-hackers |
On Tue, Mar 17, 2020 at 5:14 PM Amit Kapila <amit.kapila16@gmail.com> wrote: > > On Mon, Mar 16, 2020 at 3:24 PM Dilip Kumar <dilipbalaut@gmail.com> wrote: > > > > + > + /* > + * Indicate that the lock is released for certain types of locks > + */ > +#ifdef USE_ASSERT_CHECKING > + CheckAndSetLockHeld(locallock, false); > +#endif > } > > /* > @@ -1618,6 +1666,11 @@ GrantLockLocal(LOCALLOCK *locallock, ResourceOwner owner) > locallock->numLockOwners++; > if (owner != NULL) > ResourceOwnerRememberLock(owner, locallock); > + > + /* Indicate that the lock is acquired for certain types of locks. */ > +#ifdef USE_ASSERT_CHECKING > + CheckAndSetLockHeld(locallock, true); > +#endif > } > > There is no need to sprinkle USE_ASSERT_CHECKING at so many places, > having inside the new function is sufficient. I have changed that, > added few more comments and > made minor changes. See, what you think about attached? Your changes look fine to me. I have also verified all the test and everything works fine. -- Regards, Dilip Kumar EnterpriseDB: http://www.enterprisedb.com
В списке pgsql-hackers по дате отправления: