diff options
| author | Jacob McDonnell <jacob@jacobmcdonnell.com> | 2026-04-25 19:55:15 -0400 |
|---|---|---|
| committer | Jacob McDonnell <jacob@jacobmcdonnell.com> | 2026-04-25 19:55:15 -0400 |
| commit | 253e67c8b3a72b3a4757fdbc5845297628db0a4a (patch) | |
| tree | adf53b66087aa30dfbf8bf391a1dadb044c3bf4d /static/netbsd/man3/SQLITE_DBSTATUS_LOOKASIDE_USED.3 | |
| parent | a9157ce950dfe2fc30795d43b9d79b9d1bffc48b (diff) | |
docs: Added All NetBSD Manuals
Diffstat (limited to 'static/netbsd/man3/SQLITE_DBSTATUS_LOOKASIDE_USED.3')
| -rw-r--r-- | static/netbsd/man3/SQLITE_DBSTATUS_LOOKASIDE_USED.3 | 158 |
1 files changed, 158 insertions, 0 deletions
diff --git a/static/netbsd/man3/SQLITE_DBSTATUS_LOOKASIDE_USED.3 b/static/netbsd/man3/SQLITE_DBSTATUS_LOOKASIDE_USED.3 new file mode 100644 index 00000000..b4752a00 --- /dev/null +++ b/static/netbsd/man3/SQLITE_DBSTATUS_LOOKASIDE_USED.3 @@ -0,0 +1,158 @@ +.Dd January 24, 2024 +.Dt SQLITE_DBSTATUS_LOOKASIDE_USED 3 +.Os +.Sh NAME +.Nm SQLITE_DBSTATUS_LOOKASIDE_USED , +.Nm SQLITE_DBSTATUS_CACHE_USED , +.Nm SQLITE_DBSTATUS_SCHEMA_USED , +.Nm SQLITE_DBSTATUS_STMT_USED , +.Nm SQLITE_DBSTATUS_LOOKASIDE_HIT , +.Nm SQLITE_DBSTATUS_LOOKASIDE_MISS_SIZE , +.Nm SQLITE_DBSTATUS_LOOKASIDE_MISS_FULL , +.Nm SQLITE_DBSTATUS_CACHE_HIT , +.Nm SQLITE_DBSTATUS_CACHE_MISS , +.Nm SQLITE_DBSTATUS_CACHE_WRITE , +.Nm SQLITE_DBSTATUS_DEFERRED_FKS , +.Nm SQLITE_DBSTATUS_CACHE_USED_SHARED , +.Nm SQLITE_DBSTATUS_CACHE_SPILL , +.Nm SQLITE_DBSTATUS_MAX +.Nd status parameters for database connections +.Sh SYNOPSIS +.In sqlite3.h +.Fd #define SQLITE_DBSTATUS_LOOKASIDE_USED +.Fd #define SQLITE_DBSTATUS_CACHE_USED +.Fd #define SQLITE_DBSTATUS_SCHEMA_USED +.Fd #define SQLITE_DBSTATUS_STMT_USED +.Fd #define SQLITE_DBSTATUS_LOOKASIDE_HIT +.Fd #define SQLITE_DBSTATUS_LOOKASIDE_MISS_SIZE +.Fd #define SQLITE_DBSTATUS_LOOKASIDE_MISS_FULL +.Fd #define SQLITE_DBSTATUS_CACHE_HIT +.Fd #define SQLITE_DBSTATUS_CACHE_MISS +.Fd #define SQLITE_DBSTATUS_CACHE_WRITE +.Fd #define SQLITE_DBSTATUS_DEFERRED_FKS +.Fd #define SQLITE_DBSTATUS_CACHE_USED_SHARED +.Fd #define SQLITE_DBSTATUS_CACHE_SPILL +.Fd #define SQLITE_DBSTATUS_MAX +.Sh DESCRIPTION +These constants are the available integer "verbs" that can be passed +as the second argument to the +.Fn sqlite3_db_status +interface. +.Pp +New verbs may be added in future releases of SQLite. +Existing verbs might be discontinued. +Applications should check the return code from +.Fn sqlite3_db_status +to make sure that the call worked. +The +.Fn sqlite3_db_status +interface will return a non-zero error code if a discontinued or unsupported +verb is invoked. +.Bl -tag -width Ds +.It SQLITE_DBSTATUS_LOOKASIDE_USED +This parameter returns the number of lookaside memory slots currently +checked out. +.It SQLITE_DBSTATUS_LOOKASIDE_HIT +This parameter returns the number of malloc attempts that were satisfied +using lookaside memory. +Only the high-water value is meaningful; the current value is always +zero. +.It SQLITE_DBSTATUS_LOOKASIDE_MISS_SIZE +This parameter returns the number malloc attempts that might have been +satisfied using lookaside memory but failed due to the amount of memory +requested being larger than the lookaside slot size. +Only the high-water value is meaningful; the current value is always +zero. +.It SQLITE_DBSTATUS_LOOKASIDE_MISS_FULL +This parameter returns the number malloc attempts that might have been +satisfied using lookaside memory but failed due to all lookaside memory +already being in use. +Only the high-water value is meaningful; the current value is always +zero. +.It SQLITE_DBSTATUS_CACHE_USED +This parameter returns the approximate number of bytes of heap memory +used by all pager caches associated with the database connection. +The highwater mark associated with SQLITE_DBSTATUS_CACHE_USED is always +0. +.It SQLITE_DBSTATUS_CACHE_USED_SHARED +This parameter is similar to DBSTATUS_CACHE_USED, except that if a +pager cache is shared between two or more connections the bytes of +heap memory used by that pager cache is divided evenly between the +attached connections. +In other words, if none of the pager caches associated with the database +connection are shared, this request returns the same value as DBSTATUS_CACHE_USED. +Or, if one or more or the pager caches are shared, the value returned +by this call will be smaller than that returned by DBSTATUS_CACHE_USED. +The highwater mark associated with SQLITE_DBSTATUS_CACHE_USED_SHARED +is always 0. +.It SQLITE_DBSTATUS_SCHEMA_USED +This parameter returns the approximate number of bytes of heap memory +used to store the schema for all databases associated with the connection +- main, temp, and any ATTACH-ed databases. +The full amount of memory used by the schemas is reported, even if +the schema memory is shared with other database connections due to +shared cache mode being enabled. +The highwater mark associated with SQLITE_DBSTATUS_SCHEMA_USED is always +0. +.It SQLITE_DBSTATUS_STMT_USED +This parameter returns the approximate number of bytes of heap and +lookaside memory used by all prepared statements associated with the +database connection. +The highwater mark associated with SQLITE_DBSTATUS_STMT_USED is always +0. +.It SQLITE_DBSTATUS_CACHE_HIT +This parameter returns the number of pager cache hits that have occurred. +The highwater mark associated with SQLITE_DBSTATUS_CACHE_HIT is always +0. +.It SQLITE_DBSTATUS_CACHE_MISS +This parameter returns the number of pager cache misses that have occurred. +The highwater mark associated with SQLITE_DBSTATUS_CACHE_MISS is always +0. +.It SQLITE_DBSTATUS_CACHE_WRITE +This parameter returns the number of dirty cache entries that have +been written to disk. +Specifically, the number of pages written to the wal file in wal mode +databases, or the number of pages written to the database file in rollback +mode databases. +Any pages written as part of transaction rollback or database recovery +operations are not included. +If an IO or other error occurs while writing a page to disk, the effect +on subsequent SQLITE_DBSTATUS_CACHE_WRITE requests is undefined. +The highwater mark associated with SQLITE_DBSTATUS_CACHE_WRITE is always +0. +.It SQLITE_DBSTATUS_CACHE_SPILL +This parameter returns the number of dirty cache entries that have +been written to disk in the middle of a transaction due to the page +cache overflowing. +Transactions are more efficient if they are written to disk all at +once. +When pages spill mid-transaction, that introduces additional overhead. +This parameter can be used help identify inefficiencies that can be +resolved by increasing the cache size. +.It SQLITE_DBSTATUS_DEFERRED_FKS +This parameter returns zero for the current value if and only if all +foreign key constraints (deferred or immediate) have been resolved. +The highwater mark is always 0. +.El +.Pp +.Sh IMPLEMENTATION NOTES +These declarations were extracted from the +interface documentation at line 8652. +.Bd -literal +#define SQLITE_DBSTATUS_LOOKASIDE_USED 0 +#define SQLITE_DBSTATUS_CACHE_USED 1 +#define SQLITE_DBSTATUS_SCHEMA_USED 2 +#define SQLITE_DBSTATUS_STMT_USED 3 +#define SQLITE_DBSTATUS_LOOKASIDE_HIT 4 +#define SQLITE_DBSTATUS_LOOKASIDE_MISS_SIZE 5 +#define SQLITE_DBSTATUS_LOOKASIDE_MISS_FULL 6 +#define SQLITE_DBSTATUS_CACHE_HIT 7 +#define SQLITE_DBSTATUS_CACHE_MISS 8 +#define SQLITE_DBSTATUS_CACHE_WRITE 9 +#define SQLITE_DBSTATUS_DEFERRED_FKS 10 +#define SQLITE_DBSTATUS_CACHE_USED_SHARED 11 +#define SQLITE_DBSTATUS_CACHE_SPILL 12 +#define SQLITE_DBSTATUS_MAX 12 /* Largest defined DBSTATUS */ +.Ed +.Sh SEE ALSO +.Xr sqlite3_db_status 3 |
