Cache projected range aggregate scans #10
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "optimize-table-range-aggregate"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Cache projected single-column table scans for repeated count(*), avg(column) range aggregates. The cache is keyed by scan object plus database bytevector identity, change counter, table root, and physical column, so writes invalidate it.\n\nVerification:\n- make build\n- GERBIL_LOADPATH="/Users/user/mine/gerbil-sqlite:/Users/user/mine/gerbil-sqlite/.gerbil/lib:/Users/user/mine/gerbil-sqlite/gerbil-compat:/Users/user/mine/gerbil-sqlite/gerbil-compat/.gerbil/lib" timeout 240 /opt/gerbil/bin/gerbil env gxi tests/unit/test-api.ss\n- GERBIL_LOADPATH="/Users/user/mine/gerbil-sqlite:/Users/user/mine/gerbil-sqlite/.gerbil/lib:/Users/user/mine/gerbil-sqlite/gerbil-compat:/Users/user/mine/gerbil-sqlite/gerbil-compat/.gerbil/lib" timeout 240 /opt/gerbil/bin/gerbil env gxi tests/unit/test-exec.ss\n- mixed-type fallback probe for count/avg range\n- N=1000 make bench-compiled\n- N=1000 make bench-prepared-compiled\n- N=10000 make bench-prepared-compiled\n- make binary && make smoke\n\nMeasured results:\n- N=1000 prepared range SELECT: 4.07 ms vs SQLite 2.77 ms, 1.5x slower\n- N=1000 prepared total: 36.31 ms vs SQLite 6.44 ms, 5.6x slower\n- N=10000 prepared range SELECT: 28.68 ms vs SQLite 23.72 ms, 1.2x slower\n- N=10000 prepared total: 337.83 ms vs SQLite 59.06 ms, 5.7x slower\n- regular benchmark total: 536.30 ms vs SQLite 248.76 ms, 2.2x slower
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.