Home | History | Annotate | Download | only in dist

Lines Matching refs:Lookaside

1901 ** memory allocation for the lookaside memory allocator on each
1903 ** size of each lookaside buffer slot and the second is the number of
1905 ** <i>default</i> lookaside size. The [SQLITE_DBCONFIG_LOOKASIDE]
1906 ** verb to [sqlite3_db_config()] can be used to change the lookaside
1973 ** [lookaside memory allocator] configuration for the [database connection].
1975 ** pointer to an memory buffer to use for lookaside memory.
1978 ** lookaside buffer itself using [sqlite3_malloc()]. ^The second argument is the
1979 ** size of each lookaside buffer slot. ^The third argument is the number of
1984 ** rounded down to the next smaller multiple of 8. ^(The lookaside memory
1986 ** connection is not currently using lookaside memory, or in other words
1989 ** Any attempt to change the lookaside memory configuration when lookaside
6035 ** <dd>This parameter returns the number of lookaside memory slots currently
6054 ** and lookaside memory used by all prepared statements associated with
7378 typedef struct Lookaside Lookaside;
8855 ** Lookaside malloc is a set of fixed-size buffers that can be used
8858 ** lookaside malloc provides a significant performance enhancement
8862 ** The Lookaside structure holds configuration information about the
8863 ** lookaside malloc subsystem. Each available memory allocation in
8864 ** the lookaside subsystem is stored on a linked list of LookasideSlot
8867 ** Lookaside allocations are only allowed for objects that are associated
8869 ** be stored in lookaside because in shared cache mode the schema information
8871 ** schema information, the Lookaside.bEnabled flag is cleared so that
8872 ** lookaside allocations are not used to construct the schema objects.
8874 struct Lookaside {
8876 u8 bEnabled; /* False to disable new lookaside allocations */
8982 Lookaside lookaside; /* Lookaside malloc configuration */
10504 sqlite3 *db; /* Optional database for lookaside. Can be NULL */
10536 int szLookaside; /* Default lookaside buffer size */
10537 int nLookaside; /* Default lookaside buffer count */
11308 ** it might have been allocated by lookaside, except the allocation was
11309 ** too large or lookaside was already full. It is important to verify
11310 ** that allocations that might have been satisfied by lookaside are not
11311 ** passed back to non-lookaside free() routines. Asserts such as the
11312 ** example above are placed on the non-lookaside free() routines to verify
11328 #define MEMTYPE_LOOKASIDE 0x02 /* Might have been lookaside memory */
12504 *pCurrent = db->lookaside.nOut;
12505 *pHighwater = db->lookaside.mxOut;
12507 db->lookaside.mxOut = db->lookaside.nOut;
17885 ** TRUE if p is a lookaside memory allocation from db
17889 return p && p>=db->lookaside.pStart && p<db->lookaside.pEnd;
17907 return db->lookaside.sz;
17947 pBuf->pNext = db->lookaside.pFree;
17948 db->lookaside.pFree = pBuf;
17949 db->lookaside.nOut--;
18073 if( db->lookaside.bEnabled && n<=db->lookaside.sz
18074 && (pBuf = db->lookaside.pFree)!=0 ){
18075 db->lookaside.pFree = pBuf->pNext;
18076 db->lookaside.nOut++;
18077 if( db->lookaside.nOut>db->lookaside.mxOut ){
18078 db->lookaside.mxOut = db->lookaside.nOut;
18093 ((db && db->lookaside.bEnabled) ? MEMTYPE_LOOKASIDE : MEMTYPE_HEAP));
18110 if( n<=db->lookaside.sz ){
18115 memcpy(pNew, p, db->lookaside.sz);
18128 (db->lookaside.bEnabled ? MEMTYPE_LOOKASIDE : MEMTYPE_HEAP));
76611 u8 enableLookaside = db->lookaside.bEnabled;
76615 db->lookaside.bEnabled = 0;
76624 db->lookaside.bEnabled = enableLookaside;
81821 ** the lookaside buffer belonging to database handle dbMem.
82186 u8 enableLookaside; /* Copy of db->lookaside.bEnabled */
82294 /* Disable lookaside memory allocation */
82295 enableLookaside = db->lookaside.bEnabled;
82296 db->lookaside.bEnabled = 0;
82318 /* Re-enable the lookaside buffer, if it was disabled earlier. */
82319 db->lookaside.bEnabled = enableLookaside;
89200 /* The sqlite3ResultSetOfSelect() is only used n contexts where lookaside
89202 assert( db->lookaside.bEnabled==0 );
102333 pParse->db->lookaside.bEnabled = 0;
103313 pParse->db->lookaside.bEnabled = 0;
104299 u8 enableLookaside; /* Saved value of db->lookaside.bEnabled */
104323 enableLookaside = db->lookaside.bEnabled;
104324 if( db->lookaside.pStart ) db->lookaside.bEnabled = 1;
104378 db->lookaside.bEnabled = enableLookaside;
105239 ** Set up the lookaside buffers for a database connection.
105241 ** If lookaside is already active, return SQLITE_BUSY.
105243 ** The sz parameter is the number of bytes in each lookaside slot.
105245 ** space for the lookaside memory is obtained from sqlite3_malloc().
105247 ** the lookaside memory.
105251 if( db->lookaside.nOut ){
105254 /* Free any existing lookaside buffer for this handle before
105258 if( db->lookaside.bMalloced ){
105259 sqlite3_free(db->lookaside.pStart);
105261 /* The size of a lookaside slot needs to be larger than a pointer
105278 db->lookaside.pStart = pStart;
105279 db->lookaside.pFree = 0;
105280 db->lookaside.sz = (u16)sz;
105287 p->pNext = db->lookaside.pFree;
105288 lookaside.pFree = p;
105291 db->lookaside.pEnd = p;
105292 db->lookaside.bEnabled = 1;
105293 db->lookaside.bMalloced = pBuf==0 ?1:0;
105295 db->lookaside.pEnd = 0;
105296 db->lookaside.bEnabled = 0;
105297 db->lookaside.bMalloced = 0;
105566 assert( db->lookaside.nOut==0 ); /* Fails on a lookaside memory leak */
105567 if( db->lookaside.bMalloced ){
105568 sqlite3_free(db->lookaside.pStart);
106755 /* Enable the lookaside-malloc subsystem */