pgsql-server: Introduce local hash table for lock state, as per recent

From: tgl(at)svr1(dot)postgresql(dot)org (Tom Lane)
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql-server: Introduce local hash table for lock state, as per recent
Date: 2004-08-27 17:07:42
Message-ID: 20040827170742.70E445E46FD@svr1.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Log Message:
-----------
Introduce local hash table for lock state, as per recent proposal.
PROCLOCK structs in shared memory now have only a bitmask for held
locks, rather than counts (making them 40 bytes smaller, which is a
good thing). Multiple locks within a transaction are counted in the
local hash table instead, and we have provision for tracking which
ResourceOwner each count belongs to. Solves recently reported problem
with memory leakage within long transactions.

Modified Files:
--------------
pgsql-server/contrib/userlock:
user_locks.c (r1.13 -> r1.14)
(http://developer.postgresql.org/cvsweb.cgi/pgsql-server/contrib/userlock/user_locks.c.diff?r1=1.13&r2=1.14)
pgsql-server/src/backend/storage/lmgr:
README (r1.14 -> r1.15)
(http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/backend/storage/lmgr/README.diff?r1=1.14&r2=1.15)
deadlock.c (r1.29 -> r1.30)
(http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/backend/storage/lmgr/deadlock.c.diff?r1=1.29&r2=1.30)
lock.c (r1.136 -> r1.137)
(http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/backend/storage/lmgr/lock.c.diff?r1=1.136&r2=1.137)
proc.c (r1.150 -> r1.151)
(http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/backend/storage/lmgr/proc.c.diff?r1=1.150&r2=1.151)
pgsql-server/src/backend/utils/adt:
lockfuncs.c (r1.13 -> r1.14)
(http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/backend/utils/adt/lockfuncs.c.diff?r1=1.13&r2=1.14)
pgsql-server/src/backend/utils/resowner:
resowner.c (r1.3 -> r1.4)
(http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/backend/utils/resowner/resowner.c.diff?r1=1.3&r2=1.4)
pgsql-server/src/include/storage:
lock.h (r1.80 -> r1.81)
(http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/include/storage/lock.h.diff?r1=1.80&r2=1.81)
proc.h (r1.72 -> r1.73)
(http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/include/storage/proc.h.diff?r1=1.72&r2=1.73)
pgsql-server/src/include/utils:
resowner.h (r1.1 -> r1.2)
(http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/include/utils/resowner.h.diff?r1=1.1&r2=1.2)

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2004-08-27 17:47:57 pgsql-server: Make gistindex_keytest safe against NULL values.
Previous Message Bruce Momjian 2004-08-27 04:34:29 pgsql-server: Update wording: < This would require some background