Re: reducing the overhead of frequent table locks, v4

From: Jeff Davis <pgsql(at)j-davis(dot)com>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: reducing the overhead of frequent table locks, v4
Date: 2011-07-11 16:45:35
Message-ID: 1310402735.3012.266.camel@jdavis
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

* ... It's also possible that
* we're acquiring a second or third lock type on a relation we have
* already locked using the fast-path, but for now we don't worry about
* that case either.
*/

How common is that case? There are only 16 entries in the fast path lock
table, so it seems like it would frequently fill up. So, if there are
common code paths that acquire different weak locks on the same
relation, then we might commonly miss a fast-path opportunity.

One path that acquires multiple weak locks is an INSERT INTO foo
SELECT ... FROM foo ...

Is that common enough to worry about?

Regards,
Jeff Davis

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2011-07-11 16:46:41 Re: pg_xlog error
Previous Message Gurjeet Singh 2011-07-11 16:45:09 Launching debugger on self on SIGSEGV