From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> |
Cc: | Pg Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: foreign key locks |
Date: | 2012-08-25 01:51:13 |
Message-ID: | CA+TgmoaA962qucoiJKb+=NSmRyBppwDdbLnf6cF5=h1=7vQRtg@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Aug 22, 2012 at 5:31 PM, Alvaro Herrera
<alvherre(at)2ndquadrant(dot)com> wrote:
> Patch v19 contains some tweaks. Most notably,
>
> 1. if an Xid requests a lock A, and then a lock B which is stronger than
> A, then record only lock B and forget lock A. This is important for
> performance, because EvalPlanQual obtains ForUpdate locks on the tuples
> that it chases on an update chain. If EPQ was called by an update or
> delete, previously a MultiXact was being created.
>
> In a stock pgbench run this was causing lots of multis to be created,
> even when there are no FKs.
>
> This was most likely involved in the 9% performance decrease that was
> previously reported.
Ah-ha! Neat. I'll try to find some time to re-benchmark this during
the next CF, unless you did that already.
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Jeff Janes | 2012-08-25 03:42:40 | Re: Loose Index Scans by Planner? |
Previous Message | Robert Haas | 2012-08-25 01:49:03 | Re: NOT NULL constraints in foreign tables |