mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-12 13:01:09 +03:00
Rearrange fields of the BtCursor object so that it is smaller and requires less
initialization, for a small performance improvement. FossilOrigin-Name: 0ddf5292cc0411ec6fcb7399ecf2904c899e0488404d3f65490fbe1db15efdf4
This commit is contained in:
@@ -503,20 +503,20 @@ struct BtCursor {
|
||||
u8 curFlags; /* zero or more BTCF_* flags defined below */
|
||||
u8 curPagerFlags; /* Flags to send to sqlite3PagerGet() */
|
||||
u8 hints; /* As configured by CursorSetHints() */
|
||||
int nOvflAlloc; /* Allocated size of aOverflow[] array */
|
||||
Btree *pBtree; /* The Btree to which this cursor belongs */
|
||||
BtShared *pBt; /* The BtShared this cursor points to */
|
||||
BtCursor *pNext; /* Forms a linked list of all cursors */
|
||||
Pgno *aOverflow; /* Cache of overflow page locations */
|
||||
CellInfo info; /* A parse of the cell we are pointing at */
|
||||
i64 nKey; /* Size of pKey, or last integer key */
|
||||
void *pKey; /* Saved key that was cursor last known position */
|
||||
Pgno pgnoRoot; /* The root page of this tree */
|
||||
int skipNext; /* Prev() is noop if negative. Next() is noop if positive.
|
||||
** Error code if eState==CURSOR_FAULT */
|
||||
Btree *pBtree; /* The Btree to which this cursor belongs */
|
||||
Pgno *aOverflow; /* Cache of overflow page locations */
|
||||
void *pKey; /* Saved key that was cursor last known position */
|
||||
/* All fields above are zeroed when the cursor is allocated. See
|
||||
** sqlite3BtreeCursorZero(). Fields that follow must be manually
|
||||
** initialized. */
|
||||
#define BTCURSOR_FIRST_UNINIT pBt /* Name of first uninitialized field */
|
||||
BtShared *pBt; /* The BtShared this cursor points to */
|
||||
BtCursor *pNext; /* Forms a linked list of all cursors */
|
||||
CellInfo info; /* A parse of the cell we are pointing at */
|
||||
i64 nKey; /* Size of pKey, or last integer key */
|
||||
Pgno pgnoRoot; /* The root page of this tree */
|
||||
i8 iPage; /* Index of current page in apPage */
|
||||
u8 curIntKey; /* Value of apPage[0]->intKey */
|
||||
u16 ix; /* Current index for apPage[iPage] */
|
||||
|
||||
Reference in New Issue
Block a user