diff options
| author | Tom Lane <tgl@sss.pgh.pa.us> | 2001-06-27 23:31:40 +0000 |
|---|---|---|
| committer | Tom Lane <tgl@sss.pgh.pa.us> | 2001-06-27 23:31:40 +0000 |
| commit | e0c9301c87634f21c0a7c6305bdc6da15d6ba375 (patch) | |
| tree | aad976ca0197137c3461ff19a3d0e155487f7b44 /src/include/storage/lock.h | |
| parent | b559382134a52bbe1d79d465afd89c8385f88581 (diff) | |
| download | postgresql-e0c9301c87634f21c0a7c6305bdc6da15d6ba375.tar.gz | |
Install infrastructure for shared-memory free space map. Doesn't actually
do anything yet, but it has the necessary connections to initialization
and so forth. Make some gestures towards allowing number of blocks in
a relation to be BlockNumber, ie, unsigned int, rather than signed int.
(I doubt I got all the places that are sloppy about it, yet.) On the
way, replace the hardwired NLOCKS_PER_XACT fudge factor with a GUC
variable.
Diffstat (limited to 'src/include/storage/lock.h')
| -rw-r--r-- | src/include/storage/lock.h | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/src/include/storage/lock.h b/src/include/storage/lock.h index 2428a782a6..30a13649e4 100644 --- a/src/include/storage/lock.h +++ b/src/include/storage/lock.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $Id: lock.h,v 1.49 2001/06/22 00:04:59 tgl Exp $ + * $Id: lock.h,v 1.50 2001/06/27 23:31:39 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -32,6 +32,8 @@ typedef struct proc PROC; extern SPINLOCK LockMgrLock; +extern int max_locks_per_xact; + #ifdef LOCK_DEBUG extern int Trace_lock_oidmin; extern bool Trace_locks; @@ -41,19 +43,6 @@ extern bool Debug_deadlocks; #endif /* LOCK_DEBUG */ -/* ---------------------- - * The following defines are used to estimate how much shared - * memory the lock manager is going to require. - * See LockShmemSize() in lock.c. - * - * NLOCKS_PER_XACT - The number of unique objects locked in a transaction - * (this should be configurable!) - * NLOCKENTS - The maximum number of lock entries in the lock table. - * ---------------------- - */ -#define NLOCKS_PER_XACT 64 -#define NLOCKENTS(maxBackends) (NLOCKS_PER_XACT*(maxBackends)) - typedef int LOCKMASK; typedef int LOCKMODE; |
