Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support parameter SQLITE_CONFIG_MEMSTATUS in runtime #954

Open
mhanna opened this issue Aug 28, 2023 · 1 comment
Open

Support parameter SQLITE_CONFIG_MEMSTATUS in runtime #954

mhanna opened this issue Aug 28, 2023 · 1 comment
Labels
enhancement:SQLite Enhancement about sqlite features impacts:JNI Has impact on JNI C code

Comments

@mhanna
Copy link

mhanna commented Aug 28, 2023

Is your feature request related to a problem? Please describe.
When enabling the parameter SQLITE_CONFIG_MEMSTATUS at compile time, the performance (read/write) is more than 2x slower

Describe the solution you'd like
I would like to have a way to disable this parameter at runtime as the native code already support it by sqlite3_config(SQLITE_CONFIG_MEMSTATUS,0)

Describe alternatives you've considered
Have different versions, two different jars. one compiled with this option enabled and one while it disabled

Additional context
Add any other context or screenshots about the feature request here.

@mhanna mhanna added the triage label Aug 28, 2023
@gotson gotson added enhancement:SQLite Enhancement about sqlite features impacts:JNI Has impact on JNI C code and removed triage labels Aug 28, 2023
@gotson
Copy link
Collaborator

gotson commented Aug 29, 2023

We currently compile with -DSQLITE_DEFAULT_MEMSTATUS=0.

SQLite website mentions for SQLITE_CONFIG_MEMSTATUS:

Memory allocation statistics are enabled by default unless SQLite is compiled with SQLITE_DEFAULT_MEMSTATUS=0 in which case memory allocation statistics are disabled by default.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement:SQLite Enhancement about sqlite features impacts:JNI Has impact on JNI C code
Projects
None yet
Development

No branches or pull requests

2 participants