Small. Fast. Reliable.
Choose any three.

About Sitemap Documentation Download License News Developers Support

## SQLite C Interface

## Memory Allocator Statistics

>     sqlite3_int64 sqlite3_memory_used(void);
>     sqlite3_int64 sqlite3_memory_highwater(int resetFlag);

SQLite provides these two interfaces for reporting on the status of the sqlite3_malloc(), sqlite3_free(), and sqlite3_realloc() the memory allocation subsystem included within the SQLite.

### Invariants:

F17371 | The sqlite3_memory_used() routine returns the number of bytes of memory currently outstanding (malloced but not freed).
F17373 | The sqlite3_memory_highwater() routine returns the maximum value of sqlite3_memory_used() since the highwater mark was last reset.
F17374 | The values returned by sqlite3_memory_used() and sqlite3_memory_highwater() include any overhead added by SQLite in its implementation of sqlite3_malloc(), but not overhead added by the any underlying system library routines that sqlite3_malloc() may call.
F17375 | The memory highwater mark is reset to the current value of sqlite3_memory_used() if and only if the parameter to sqlite3_memory_highwater() is true. The value returned by sqlite3_memory_highwater(1) is the highwater mark prior to the reset.

See also lists of Objects, Constants, and Functions.

This page last modified 2008/01/31 20:37:13 UTC