1
0
mirror of https://github.com/postgres/postgres.git synced 2025-09-03 15:22:11 +03:00

Initial MVCC code.

New code for locking buffer' context.
This commit is contained in:
Vadim B. Mikheev
1998-12-15 12:47:01 +00:00
parent c5a27161a1
commit 3f7fbf85dc
65 changed files with 1391 additions and 1282 deletions

View File

@@ -6,7 +6,7 @@
*
* Copyright (c) 1994, Regents of the University of California
*
* $Id: bufmgr.h,v 1.23 1998/10/08 18:30:43 momjian Exp $
* $Id: bufmgr.h,v 1.24 1998/12/15 12:46:56 vadim Exp $
*
*-------------------------------------------------------------------------
*/
@@ -73,6 +73,14 @@ extern int ShowPinTrace;
#define BUFFER_FLUSH_WRITE 0 /* immediate write */
#define BUFFER_LATE_WRITE 1 /* delayed write: mark as DIRTY */
/*
* Buffer context lock modes
*/
#define BUFFER_LOCK_UNLOCK 0
#define BUFFER_LOCK_SHARE 1
#define BUFFER_LOCK_EXCLUSIVE 2
/*
* BufferIsValid --
* True iff the refcnt of the local buffer is > 0
@@ -155,4 +163,7 @@ extern void BufferRefCountRestore(int *refcountsave);
extern int SetBufferWriteMode(int mode);
extern void SetBufferCommitInfoNeedsSave(Buffer buffer);
extern void UnlockBuffers(void);
extern void LockBuffer(Buffer buffer, int mode);
#endif /* !defined(BufMgrIncluded) */