stephan
0117693f62
Split wasmfs-enabled build of sqlite3.js/wasm into sqlite3-wasmfs.js/wasm, as enabling wasmfs breaks all tests/demos which run from a Worker thread.
...
FossilOrigin-Name: 08476f3c218d45846e7496bdae0b06e2122466111fdf2aa2aabb1805b15ef982
2022-09-15 03:09:00 +00:00
stephan
409505c743
Clean up some JS documentation.
...
FossilOrigin-Name: 925fdbfc6c1f9f06951346bc0d4fb81ffb5797d5f1123728931973f6cb1a0efa
2022-09-15 02:27:48 +00:00
stephan
5b91500796
Add/apply various kvvfs-specific utility APIs to the JS layer to assist in testing and analysis. Correct a backwards default arg check for sqlite3ApiBootstrap(). Add exports for sqlite3_db_handle(), sqlite3_file_control(), and the SQLITE_FCNTL_xxx enum.
...
FossilOrigin-Name: 0d78961870ee9f22f1ba16d423377d28dcc36e04b1e31ffd57f3e2fd51f8f0f2
2022-09-13 19:27:03 +00:00
stephan
23d39ce54d
Get testing1.js working with a kvvfs build.
...
FossilOrigin-Name: 333a45725d1708e0fefa559c33ce1c7eeb425cdb04f594b1f2b48166c1478c79
2022-09-12 22:27:00 +00:00
stephan
5fd8f27bfb
Remove an extraneous key-copy op in the EM_JS impl of kvstorageDelete().
...
FossilOrigin-Name: 1c5aeee45564c14e7e2e7730f3f52106339ea3148fb5aa786fa767a35db46f51
2022-09-12 20:21:34 +00:00
stephan
0b769f5b4a
Merge kv-vfs branch into fiddle-opfs and add speedtest1-kvvfs.html test app (which currently fails early on).
...
FossilOrigin-Name: 8b1608a9a37131121cb3a0cb1e8dbad5e39dc1fc2a341d056f09537f179b2e7a
2022-09-12 20:18:28 +00:00
drh
b126ec18b6
Fix the <sys/time.h> include in os_kv.c.
...
FossilOrigin-Name: 878cc93e779c3857adc711f212520f007256274fcd3f6f3d72c754a937fcd198
2022-09-12 19:33:20 +00:00
drh
d8bb0b5ae6
Add a gettimeofday()-based implementation of xCurrentTimeInt64() to os_kv.c.
...
FossilOrigin-Name: e393ed650ef124143f84e9d787fb996e308dd7af6b8f50df72a6f085b67bf9c3
2022-09-12 19:29:34 +00:00
drh
bb19512438
Fix a debugging/testing edit in the previous check-in.
...
FossilOrigin-Name: 6fc8d34c0ae1f8277544be741f2f0835fad8e475d35bd24573224ccc1699b8bd
2022-09-12 18:10:41 +00:00
stephan
a002cc174f
Add sqlite3.oo1.DB.clearKvvfsStorage(). Add controls to kvvfs1.js demo to reset and query the db without requiring the dev console.
...
FossilOrigin-Name: d845c6c22bd5d3fffc66e0566df346d690dd8bd1fc1688e312161b1a1edcfd79
2022-09-12 17:59:04 +00:00
drh
6acd7b0a75
Faster text decoder for kv_os.c.
...
FossilOrigin-Name: 3354a2edb762d70ccc31d4d25f81b70e644d76e01cb1e81d2e97b5414d809d30
2022-09-12 17:44:35 +00:00
stephan
5360f5fcff
Merge kv-vfs branch into fiddle-opfs branch to add kvvfs-based wasm build and demo.
...
FossilOrigin-Name: a7d8b26acd3c1ae344369e4d70804c0cab45272c0983cfd32d616a0a7b28acb9
2022-09-12 16:09:50 +00:00
drh
3e4e697d1c
New run-time options to the speed-check.sh script.
...
FossilOrigin-Name: ff46bc9d2a844dde9dafa157114f4d9ee157205ca5c08ed9ee32f018de310e62
2022-09-12 16:07:24 +00:00
drh
1ad51ffe21
Fix uninitialized variable in rollback-journal processing in os_kv.c
...
FossilOrigin-Name: e49682c5eac91958f143e639c5656ca54560d14f5805d514bf4aa0c206e63844
2022-09-12 15:59:35 +00:00
stephan
2811759d5e
Resolve missing kvvfs JS test: sqlite3_initialize() must be called by the client in this build. Add basic sanity test of kvvfs using sessionStorage().
...
FossilOrigin-Name: 250a935aeb94d3fadec0d3fe22de85de4e658e2fdb3be3aa9a8bbc8f7b7d8414
2022-09-12 13:05:54 +00:00
drh
6b013afb88
Fix the amalgamation so that it builds with the standard unix backend again.
...
FossilOrigin-Name: 0adf158f4e5791339988185cc29347c75056b062e0db65b5999fdfa1f433c1ed
2022-09-12 12:41:07 +00:00
stephan
ad5125a624
Initial build of kvvfs in wasm. It loads but cannot find the VFS for as-yet-unknown reasons (sqlite3 shell works fine), and most APIs throw "null function or function signature mismatch" from deep within wasm, presumably as a side effect of the "missing" VFS.
...
FossilOrigin-Name: 1a2f24a0bdfc6eaae478916b8f4f9c6b63ead9964534fc2951fb4e995ffe61f1
2022-09-12 12:39:28 +00:00
stephan
73079dba00
Minor cleanups and documentation in the wasm pieces.
...
FossilOrigin-Name: 4e6ce329872eb733ba2f7f7879747c52761ae97790fd8ed169a25a79854cc3d9
2022-09-11 16:59:40 +00:00
stephan
2a91126d76
Correct the result code from kvstorageRead() for the OOM case to be a negative value.
...
FossilOrigin-Name: cdbf09fa1b0c93aeb3222a157de33a4688ae629c2b829ffff0f1f62364c5ae1c
2022-09-11 05:44:15 +00:00
stephan
ade4f4d645
Minor cleanups and docs for the EM_JS() impls of the kvvfs read/write/delete ops.
...
FossilOrigin-Name: 53b7572e441be4b4b29b4228d0f95b24457d7faaf6c0b568ed5c970a55e21ffb
2022-09-11 05:38:39 +00:00
stephan
e99f742a32
Add EM_JS() impl for kvstorageRead().
...
FossilOrigin-Name: 06610314fcf644f323c2f7ae11d7f4349b195e66d0ebbee590438dd99d97eb96
2022-09-11 04:49:29 +00:00
stephan
d15822965b
Initial prototype impls of write/delete-key ops for the pending kvvfs which use sessionStorage or localStorage for db page storage. read-key op is pending.
...
FossilOrigin-Name: a4bd96f5348e607d0fcb627b751f9d86a188173a4b3bfb2c95f92913a78bd31e
2022-09-11 02:43:08 +00:00
drh
c6c9c6aad0
Improved comments in os_kv.c. Better names for the key/value name spaces.
...
FossilOrigin-Name: 8e1652a3856765c9146cc2a7e3b598a2dc7dc84c556b35eab9a35184514384b9
2022-09-10 18:38:21 +00:00
drh
7585f49a0a
Move the vfskv.c extension to src/os_kv.c and make it part of the amalgamation,
...
activated if and only if SQLITE_OS_KV is true.
FossilOrigin-Name: f6632e69c2ec1a7ddc4e51f3567e3bc082ee94a6dd51fdafdc0c3bf386a32d4c
2022-09-10 18:20:59 +00:00
mistachkin
bdb6368d72
Fix harmless compiler warning seen with MSVC.
...
FossilOrigin-Name: 73c4c68d3b4c16caf8281dabddd7365d24691e5ee2da89b1783eca66bfbd9280
2022-09-09 17:50:29 +00:00
drh
25f62508f5
Database must be named either "local" or "session". Each has a distinct
...
namespace.
FossilOrigin-Name: c8e41279294ea7c2f041c7d4cbbd85fce47d55f2f56180ca837316f7dfd75237
2022-09-09 16:16:33 +00:00
drh
f7377d5763
Separate sqlite3_io_methods objects for database files and journals.
...
FossilOrigin-Name: 74fbf6c2a97729e481d5562344e960d0c237aeb1f07240262d32a24fb1f4b5a3
2022-09-09 14:22:41 +00:00
drh
126976c9f8
Simple reading and writing now works.
...
FossilOrigin-Name: 00845ac9ef2616e90f5f6a20da3dd040fa8bdcfe73f72fe9c06039561150a82d
2022-09-09 11:41:54 +00:00
stephan
f5bf66c875
Remove a reference to a completed TODO.
...
FossilOrigin-Name: 757ad69607201a26802a304839b8454b1634712458539d6aa8cf999ab2447e59
2022-09-09 05:39:36 +00:00
stephan
e66b26818b
speedtest1 wasm: add a link in the worker variant which launches the main-thread variant with the selected CLI flags. Append collected stdout/stderr to the main-thread page after execution is finished to avoid having to open the dev tools (which inexplicably slows down wasm execution).
...
FossilOrigin-Name: 02709ee2beab36d144b807fd9ffaee639e3c1bdd1908a34e05f3fd23dad2ef66
2022-09-09 04:50:18 +00:00
stephan
dd628ed58b
Make use of the --big-transactions flag in the speedtest1 JS apps.
...
FossilOrigin-Name: f2846dcbcaac7880394fb14597c3a60ed310419128c4c5b863cd771a7e5cdeb5
2022-09-08 21:33:50 +00:00
stephan
e07ce18be5
Add speedtest1 --big-transactions flag to cause its large tests which rely on implicit transactions to be wrapped in BEGIN/COMMIT, per /chat discussion. Added to support of the WASMFS build, which slows down significantly when thousands of implicit transactions are used.
...
FossilOrigin-Name: 51395c005da46b7fa5a5f28809dd8fea263a6bac2b1492759b3d5a5aa7d399ca
2022-09-08 21:09:42 +00:00
stephan
1174c23e0d
Minor build cleanups and tweaks in the speedtest1 wasm apps.
...
FossilOrigin-Name: 5240fb4d795dea826f23cf5d2152b519f5a46f49bb2499ea868fa7c7f4ce788b
2022-09-08 20:04:52 +00:00
stephan
fa7098d543
Experimentally add --nomutex flag to speedtest1 to have it open db with the SQLITE_OPEN_NOMUTEX flag.
...
FossilOrigin-Name: 45ef576b2ee6369ab1e3aa2ad284764bb334f92a69a33d88b7292bbc0a1b1fda
2022-09-08 19:53:59 +00:00
drh
7cd81af3a9
Compiles and loads as an extension. Starts to run but quickly hits issues.
...
FossilOrigin-Name: 2e38726f46918b28b5c638967f960a20afd3fe84ad245f3bea39a1d64980435b
2022-09-08 17:12:12 +00:00
drh
e3485ee996
Compiles without error, but untested.
...
FossilOrigin-Name: a329939c32e33d8d00066ba3d4327f07cca1b4e67de0b8d85f1e7f98afe40954
2022-09-08 16:27:50 +00:00
drh
cb94132d9f
Code snapshot. Completely untested. Probably does not compile.
...
FossilOrigin-Name: 51e267696d25f2f83b5bb847d5254ab15573ef1a16ea3d7dd8279c73c0bee539
2022-09-08 15:48:01 +00:00
stephan
44a87f08ef
Add speedtest1-worker.html, an interactive Worker-thread variant of speedtest1.html. Add ext/wasm/index.html to act as a gateway to the various test pages.
...
FossilOrigin-Name: f16c68ee6d5ebb8dec2ab656dbab2ddb5f1d5133153ad553f986b31020adaa38
2022-09-08 15:30:59 +00:00
drh
b53e0992b2
Enhance an assert() to impose for tighter constraints on the operation of pcache.
...
FossilOrigin-Name: 42105eb43a916a7cd839fa6c582eaffaef17f50b23c3e05142400c379feb73c7
2022-09-07 20:11:22 +00:00
drh
8c983ddb67
An improved technique for ensuring that the Rekey() operation does not
...
overwrite an existing page number. This approach does not change the
semantics of the underlying pluggable pcache and it is easier to prove
correct. This replaces the changes at
[aadd38f99a3e5abc] and [81cff9f1955874aa].
FossilOrigin-Name: 7dbddde79e3ca1b81e00288616fc27434698ce6dcb47714728fce8602ae91f45
2022-09-07 19:28:18 +00:00
drh
59ece7e106
Non-working code towards a VFS for text key/value storage.
...
FossilOrigin-Name: f9c89ee8d5ef46342bea78fa8d4da058d9ea628183ec985642bbda1cdfeacd5f
2022-09-07 17:29:22 +00:00
stephan
3a59dd12d2
Add a note about Emscripten's -sSINGLE_FILE flag, why it would be nice, and why we can't use it.
...
FossilOrigin-Name: 5ea0623630d769a8f3f07a40cd119be86b631192cdb5178131876b01b40ee5e0
2022-09-06 23:04:51 +00:00
stephan
8fc8b5b35f
Get speedtest1.js working with WASMFS/OPFS.
...
FossilOrigin-Name: 40e60f570d4f489d58d12e27c1c067b41d6c5a5e374c5fce0baa8881ef183216
2022-09-06 20:17:15 +00:00
stephan
100b496dd2
Initial build of speedtest1.wasm and speedtest1.html with which to run it.
...
FossilOrigin-Name: 4441535e3e54dc1881f700fa3878964eb8554a6790fd6aa32945f7cc104a8467
2022-09-06 16:47:43 +00:00
stephan
09aa80d109
Minor internal doc clarifications.
...
FossilOrigin-Name: 09796cc2bfce7bc4ce11db9673d20737259e9928f0484660cba3a9751f7d01c5
2022-09-06 16:35:54 +00:00
stephan
ae1ed83831
Merge trunk into fiddle-opfs branch.
...
FossilOrigin-Name: 7f76eaec793720db87415a476ddf539bc4dea3e74c8e5406d6739206aebdacc2
2022-09-06 09:59:06 +00:00
drh
2e440a0801
Add the tool/omittest-msvc.tcl script that will try to build using MSVC
...
using various compile-time options, to ensure that the compile-time options
all build without errors.
FossilOrigin-Name: 6b00ecb59fd303f7985902c35a46db9e729201d4beaedea46596b728d9e4b1c8
2022-09-05 22:54:36 +00:00
drh
0c4517a61a
Get the tool/omittest-msvc.tcl script working.
...
FossilOrigin-Name: 82b89f8a074858a81d841dfc26436e8d39ce4907b8f989eba4d848db16758303
2022-09-05 22:53:24 +00:00
drh
4c8404e555
Add a prototype for a script, similar to tool/omittest.tcl, that is designed
...
to test builds using MSVC to ensure they work with various OMIT options.
FossilOrigin-Name: b1e37a0bd31fa9f8e58c2859a80c23a682b4702eefab2c55b243f1e21d475d6c
2022-09-05 20:42:01 +00:00
drh
6e440ab3de
Fix the windows build so that it works with -DSQLITE_OMIT_AUTOINIT.
...
FossilOrigin-Name: f74a5ea8c986dc33d3afcda169c38abbe55728c56716cf9991a5e2ef7fc4917a
2022-09-05 18:17:03 +00:00