Small. Fast. Reliable.
Choose any three.
#define SQLITE_STATUS_MEMORY_USED 0 #define SQLITE_STATUS_PAGECACHE_USED 1 #define SQLITE_STATUS_PAGECACHE_OVERFLOW 2 #define SQLITE_STATUS_SCRATCH_USED 3 /* NOT USED */ #define SQLITE_STATUS_SCRATCH_OVERFLOW 4 /* NOT USED */ #define SQLITE_STATUS_MALLOC_SIZE 5 #define SQLITE_STATUS_PARSER_STACK 6 #define SQLITE_STATUS_PAGECACHE_SIZE 7 #define SQLITE_STATUS_SCRATCH_SIZE 8 /* NOT USED */ #define SQLITE_STATUS_MALLOC_COUNT 9
These integer constants designate various run-time status parameters that can be returned by
.
SQLITE_STATUS_MEMORY_USEDThis parameter is the current amount of memory checked out using
, either directly or indirectly. The figure includes calls made to
by the application and internal memory usage by the SQLite library. Auxiliary page-cache memory controlled by
is not included in this parameter. The amount returned is the sum of the allocation sizes as reported by the xSize method in
.SQLITE_STATUS_MALLOC_SIZEThis parameter records the largest memory allocation request handed to
or
(or their internal equivalents). Only the value returned in the *pHighwater parameter to
is of interest. The value written into the *pCurrent parameter is undefined.SQLITE_STATUS_MALLOC_COUNTThis parameter records the number of separate memory allocations currently checked out.SQLITE_STATUS_PAGECACHE_USEDThis parameter returns the number of pages used out of the
that was configured using
. The value returned is in pages, not in bytes.SQLITE_STATUS_PAGECACHE_OVERFLOWThis parameter returns the number of bytes of page cache allocation which could not be satisfied by the
buffer and where forced to overflow to
. The returned value includes allocations that overflowed because they were too large (they were larger than the "sz" parameter to
) and allocations that overflowed because no space was left in the page cache.SQLITE_STATUS_PAGECACHE_SIZEThis parameter records the largest memory allocation request handed to the
. Only the value returned in the *pHighwater parameter to
is of interest. The value written into the *pCurrent parameter is undefined.SQLITE_STATUS_SCRATCH_USEDNo longer used.SQLITE_STATUS_SCRATCH_OVERFLOWNo longer used.SQLITE_STATUS_SCRATCH_SIZENo longer used.SQLITE_STATUS_PARSER_STACKThe *pHighwater parameter records the deepest parser stack. The *pCurrent value is undefined. The *pHighwater value is only meaningful if SQLite is compiled with
.New status parameters may be added from time to time.
See also lists of
,
, and
.