i change the pg code, can you give me some advice how to adjust the rum code?
miaojianxin opened this issue · 1 comments
for some application, our pg code changed like this:
the structuer ItemIdData changed,
like this,
the lp_off,lp_len changed from 16 to 31.
in one page, the item number of tuples and the length of the tuple changed.
typedef struct ItemIdData
{
uint64 lp_off:31, /* offset to tuple (from start of page) /
lp_flags:2, / state of item pointer, see below /
lp_len:31; / byte length of tuple */
} ItemIdData;
the OffsetNumber changed from 16 to 32.
typedef uint32 OffsetNumber;
and we did some change for pg source in the other places , it has worked well.
when I use the rum code to pg, it core dump.
i did some change in rum code, may be the modify i did is imcomplete, the rum with pg still core。
can you give me some advice how to modify the rum code for my change in pg ?
thank you
I have done some modify for rum, but it is imcomplete。
I modified like this:
//mjx modify start
//16-->32bit
#define ItemPointerSetMax(p)
ItemPointerSet((p), InvalidBlockNumber, (OffsetNumber)0xfffffffe)
#define ItemPointerIsMax(p)
(RumItemPointerGetOffsetNumber(p) == (OffsetNumber)0xfffffffe &&
RumItemPointerGetBlockNumber(p) == InvalidBlockNumber)
#define ItemPointerSetLossyPage(p, b)
ItemPointerSet((p), (b), (OffsetNumber)0xffffffff)
#define ItemPointerIsLossyPage(p)
(RumItemPointerGetOffsetNumber(p) == (OffsetNumber)0xffffffff &&
RumItemPointerGetBlockNumber(p) != InvalidBlockNumber)
//mjx modify end
/mjx modify start
//16-->32bit
#define RUM_TREE_POSTING ((OffsetNumber)0xffffffff)
//mjx modify end
//mjx modify 16-->32
//#define ALT_ADD_INFO_NULL_FLAG (0x8000)
#define ALT_ADD_INFO_NULL_FLAG (0x80000000)