1
0
mirror of https://github.com/postgres/postgres.git synced 2025-10-29 22:49:41 +03:00

No more #ifdef XLOG.

This commit is contained in:
Vadim B. Mikheev
2000-11-30 08:46:26 +00:00
parent b16516b887
commit 81c8c244b2
36 changed files with 322 additions and 3983 deletions

View File

@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: htup.h,v 1.40 2000/11/30 01:47:32 vadim Exp $
* $Id: htup.h,v 1.41 2000/11/30 08:46:25 vadim Exp $
*
*-------------------------------------------------------------------------
*/
@@ -63,11 +63,6 @@ typedef struct HeapTupleHeaderData
typedef HeapTupleHeaderData *HeapTupleHeader;
#ifdef XLOG
/* XLOG stuff */
/*
* XLOG allows to store some information in high 4 bits of log
* record xl_info field
@@ -127,11 +122,6 @@ typedef struct xl_heap_update
#define SizeOfHeapUpdate (offsetof(xl_heap_update, mask) + sizeof(uint8))
/* end of XLOG stuff */
#endif /* XLOG */
/*
* MaxTupleSize is the maximum allowed size of a tuple, including header and
* MAXALIGN alignment padding. Basically it's BLCKSZ minus the other stuff
@@ -147,7 +137,6 @@ typedef struct xl_heap_update
#define MaxTupleSize \
(BLCKSZ - MAXALIGN(sizeof(PageHeaderData) + MaxSpecialSpace))
/*
* MaxAttrSize is a somewhat arbitrary upper limit on the declared size of
* data fields of char(n) and similar types. It need not have anything

View File

@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: nbtree.h,v 1.47 2000/11/21 21:16:05 petere Exp $
* $Id: nbtree.h,v 1.48 2000/11/30 08:46:25 vadim Exp $
*
*-------------------------------------------------------------------------
*/
@@ -42,10 +42,7 @@ typedef struct BTPageOpaqueData
#define BTP_ROOT (1 << 1) /* It's the root page (has no parent) */
#define BTP_FREE (1 << 2) /* not currently used... */
#define BTP_META (1 << 3) /* Set in the meta-page only */
#ifdef XLOG
#define BTP_REORDER (1 << 4) /* items must be re-ordered */
#endif
} BTPageOpaqueData;
typedef BTPageOpaqueData *BTPageOpaque;
@@ -209,11 +206,6 @@ typedef BTStackData *BTStack;
#define P_FIRSTKEY ((OffsetNumber) 2)
#define P_FIRSTDATAKEY(opaque) (P_RIGHTMOST(opaque) ? P_HIKEY : P_FIRSTKEY)
#ifdef XLOG
/* XLOG stuff */
/*
* XLOG allows to store some information in high 4 bits of log
* record xl_info field
@@ -257,7 +249,6 @@ typedef struct xl_btree_insert
#define SizeOfBtreeInsert (offsetof(xl_btreetid, tid) + SizeOfIptrData)
/*
* This is what we need to know about insert with split -
* 22 + {4 + 8 | left hi-key} + [btitem] + right sibling btitems. Note that
@@ -292,10 +283,6 @@ typedef struct xl_btree_newroot
#define SizeOfBtreeNewroot (offsetof(xl_btree_newroot, rootblk) + sizeof(BlockIdData))
/* end of XLOG stuff */
#endif /* XLOG */
/*
* Operator strategy numbers -- ordering of these is <, <=, =, >=, >
*/

View File

@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: transam.h,v 1.27 2000/11/21 21:16:05 petere Exp $
* $Id: transam.h,v 1.28 2000/11/30 08:46:25 vadim Exp $
*
* NOTES
* Transaction System Version 101 now support proper oid
@@ -67,11 +67,7 @@ typedef unsigned char XidStatus;/* (2 bits) */
* transaction page definitions
* ----------------
*/
#ifdef XLOG
#define TP_DataSize (BLCKSZ - sizeof(XLogRecPtr))
#else
#define TP_DataSize BLCKSZ
#endif
#define TP_NumXidStatusPerBlock (TP_DataSize * 4)
/* ----------------
@@ -88,10 +84,8 @@ typedef unsigned char XidStatus;/* (2 bits) */
*/
typedef struct LogRelationContentsData
{
#ifdef XLOG
XLogRecPtr LSN; /* temp hack: LSN is member of any block */
/* so should be described in bufmgr */
#endif
int TransSystemVersion;
} LogRelationContentsData;
@@ -115,9 +109,7 @@ typedef LogRelationContentsData *LogRelationContents;
*/
typedef struct VariableRelationContentsData
{
#ifdef XLOG
XLogRecPtr LSN;
#endif
int TransSystemVersion;
TransactionId nextXidData;
TransactionId lastXidData; /* unused */
@@ -127,21 +119,14 @@ typedef struct VariableRelationContentsData
typedef VariableRelationContentsData *VariableRelationContents;
/*
* VariableCache is placed in shmem and used by backends to
* get next available XID & OID without access to
* variable relation. Actually, I would like to have two
* different on-disk storages for next XID and OID...
* But hoping that someday we will use per database OID
* generator I leaved this as is. - vadim 07/21/98
* VariableCache is placed in shmem and used by
* backends to get next available XID & OID.
*/
typedef struct VariableCacheData
{
#ifndef XLOG
uint32 xid_count;
#endif
TransactionId nextXid;
Oid nextOid;
uint32 oidCount;
TransactionId nextXid;
Oid nextOid;
uint32 oidCount;
} VariableCacheData;
typedef VariableCacheData *VariableCache;

View File

@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: xact.h,v 1.30 2000/11/21 21:16:05 petere Exp $
* $Id: xact.h,v 1.31 2000/11/30 08:46:25 vadim Exp $
*
*-------------------------------------------------------------------------
*/
@@ -78,9 +78,6 @@ typedef TransactionStateData *TransactionState;
#define StoreInvalidTransactionId(dest) \
(*((TransactionId*) (dest)) = NullTransactionId)
#ifdef XLOG
/*
* XLOG allows to store some information in high 4 bits of log
* record xl_info field
@@ -106,8 +103,6 @@ typedef struct xl_xact_abort
#define SizeOfXactAbort ((offsetof(xl_xact_abort, xtime) + sizeof(time_t)))
#endif
/* ----------------
* extern definitions
* ----------------

View File

@@ -1,5 +1,5 @@
#ifndef XLOG_UTILS_H
#define XLOG_UTILS_H
#include "access/rmgr.h"
#include "utils/rel.h"