stephan
|
73caea1764
|
Reworking of JS internals to support binding of nested C structs (like sqlite3_index_constraint and friends) and allow some of the automated JS/C conversions to be plugged in at the struct-binding level, simplifying how struct members, in particular function pointers, can be used from JS.
FossilOrigin-Name: bb4fd5b789cebf2b224c29023fea3e620a86fb36730c36c0d85d9f35880bf643
|
2025-11-10 07:41:54 +00:00 |
|
stephan
|
53ba0b80f2
|
Minor wasm build simplifications and extend the JS bindings of sqlite3_column/value_text() such that they include embeded NUL bytes in their result strings rather than truncate them at NUL. Consolidate the shell.c build flags from the canonical and autoconf makefiles into the configure script.
FossilOrigin-Name: cee2e2576f5e91911a019bff025ee6071850c0d75941e8746f10d57b56bd830a
|
2025-11-04 22:01:55 +00:00 |
|
stephan
|
b799156a31
|
Consolidate the three VFS-specific SEE tests into a shared routine.
FossilOrigin-Name: 8ac0bf125ddb6cc86a6825dcfe8895559835eca85ef14b5ad489f7c8159462e4
|
2025-11-04 01:03:58 +00:00 |
|
stephan
|
e977440d79
|
Add tests demonstrating [d0e803b90344].
FossilOrigin-Name: 7d22ee947ddecb0dc6c640e79c9a09c0931f8b04f97d3ac89afdbf1736312bf7
|
2025-11-03 21:38:34 +00:00 |
|
stephan
|
6b9230d2a1
|
Merge the OPFS/SEE tests into trunk (where they should have been committed).
FossilOrigin-Name: f8a4d7abf0d1c9c92fa102165d08aed76fd766d49615e3d347b5547580355574
|
2025-10-26 21:58:41 +00:00 |
|
stephan
|
241004f8fc
|
Demonstrate the opfs-sahpool VFS with SEE.
FossilOrigin-Name: b4cffc00f3a18906867e8f070fbc49293ac5c038bad58e96ea74948591f31013
|
2025-10-26 21:45:02 +00:00 |
|
stephan
|
89a9efe840
|
Add a test which uses SEE via the "opfs" VFS. "opfs-sahpool" is pending.
FossilOrigin-Name: 1eb5a7ea394aa5b7e8594d73ce31f4b9bef55f2fa977dc26810c0bfba1cc39f7
|
2025-10-26 21:30:29 +00:00 |
|
stephan
|
ff5d4c348c
|
Resolve a valgrind-reported error in ext/wasm/c-pp-lite.c caused by successful exit colliding with the atexit() handler. Add -e SCRIPT support to c-pp-lite to facilitate testing.
FossilOrigin-Name: 7801c7225a18ccb2216b01663b30e3eb90a961e3d165af73f964c515b74fe745
|
2025-10-15 23:13:50 +00:00 |
|
stephan
|
436c8e5026
|
Remove the long-defunct wasmfs build of speedtest1 from index.html and re-enable the wasmfs scratchpad app (which still works). Fix the CFLAGS for the wasmfs build and the path to the wasm file for one of the JS.
FossilOrigin-Name: acaaf8cce9e780bf937436b4c987ed284aa0bba6f5ca9508d9dbad598af2991d
|
2025-09-28 18:03:29 +00:00 |
|
stephan
|
39bffbcd32
|
Use new c-pp features to simplify generation of the tester1 family of files.
FossilOrigin-Name: f7cab028c97b2c9ac9b561a4c33475aadd3f71cbd48ec4dd6e09c1bb19ec00cb
|
2025-09-28 12:47:09 +00:00 |
|
stephan
|
0b0c8734f3
|
Improve #if support in, and add #assert to, c-pp. Rename target=... preprocessor symbols to target:... because changes in the semantics for symbols which have an '=' makes some of those #if blocks mutually exclusive (which we won't want in rare cases involving the bundler-friendly builds).
FossilOrigin-Name: 54287487793d48f6dde919446ab7476aea0cc0aba3835c80f060a7b84221881a
|
2025-09-28 00:53:00 +00:00 |
|
stephan
|
6d3ae03f1e
|
Get the tester1 worker1/promiser demos building again. Show WASM heap usage in tester1 if.
FossilOrigin-Name: 6691a84872f823c95b0bdc3db8e12d21c9561aa1e1ce1d787a977f2c5ef8225a
|
2025-09-24 20:39:08 +00:00 |
|
stephan
|
892109542b
|
Generate 64-bit variants of tester1.js/html. Enhance c-pp to accept multiple input files.
FossilOrigin-Name: ef6c55e4499957fb46b213540786e5d3928ec096eae1fe759066ed011518e7a2
|
2025-09-24 17:46:08 +00:00 |
|
stephan
|
50815f8ba4
|
Fix a StructType.dispose()/ondispose() memleak in Jaccwabyt bindings in 64-bit builds and update its docs for 64-bit additions. Remove the parts of tester1.js related to skipping specific tests in 64-bit builds.
FossilOrigin-Name: 6baea1d719b0c345fee5f32a3917ce9c507a2d8cb029eaca675daca77f297eba
|
2025-09-21 20:26:47 +00:00 |
|
stephan
|
1e2156e926
|
Restructure the interface for the sqlite3.wasm pointer-size-dependent details.
FossilOrigin-Name: 8ac12e1f5144380d4ecc8b27a1f62dcda0e5a86409ae7149f62c33caeea19a23
|
2025-09-21 13:53:59 +00:00 |
|
stephan
|
51127416a4
|
Resolve the non-functional 64-bit JS vtabs and VFSes. All wasm tests now pass on a 64-bit build. Investigation of the fiddle failure on a second db import is still pending.
FossilOrigin-Name: 7c44b48b628d3d93b13031e9fd08ed39fec35c661aca9e813a89348d6c415663
|
2025-09-21 00:59:23 +00:00 |
|
stephan
|
d1b64404b3
|
Determine the WASM environment's pointer size at runtime instead of baking it in at build-time via the preprocessor.
FossilOrigin-Name: 21ac6aaa03517841b637924720354b9800d6e8b7bd5f6ee54a99f5f45b2ccdec
|
2025-09-20 23:21:24 +00:00 |
|
stephan
|
3e205eff8e
|
Add missing sqlite3_vtab::xIntegrity wasm mapping. Correct signatures for the (unused) xDlOpen and xDlError bindings. Disable OPFS-related tests in tester1.js in 64-bit builds.
FossilOrigin-Name: a106be90a2dba7476e54dbb4bdf47d0999031dae0ca82d73e51a48dadd6bcdc0
|
2025-09-20 22:10:59 +00:00 |
|
stephan
|
25e416dc3a
|
Reinstate the working-again commit/rollback/update hook tests. The bug breaking those was the one-letter change at the top of this diff.
FossilOrigin-Name: c582513a77cd1d1d9479e5a4518ddf15ef5a213bed1bfb6af9bd21bf3be41f8a
|
2025-09-20 21:03:28 +00:00 |
|
stephan
|
832dfd97d1
|
Get all but 3 of the tester1.js test groups running in 64-bit builds. The outliers are virtual tables and commit/rollback/update hooks.
FossilOrigin-Name: c135d9743698b3331e56f72160e2b78840aa2c8fa1a70daea9d4a0952dbda186
|
2025-09-20 18:51:10 +00:00 |
|
stephan
|
a8756afdbc
|
Get several hundred more lines of tester1.js running in 64-bit mode.
FossilOrigin-Name: f5105ee5defa042508a68a1f4e23b9fff46a1697b1a727e01c3edea3030fbcb5
|
2025-09-20 17:11:57 +00:00 |
|
stephan
|
a2daecfc8c
|
Further work on 64-bit WASM builds. It now gets through just shy of half of tester1.js.
FossilOrigin-Name: c8deed31365898e1379d577298fc80ef08a5531999d5b54a9f14337febed0260
|
2025-09-20 15:16:55 +00:00 |
|
stephan
|
bd5d297fec
|
Get the wasm tests running in a 64-bit build up through (but not including) the oo1 bits.
FossilOrigin-Name: a5af46174a05e1414370884d1a99827af9286a60eff1c8ae1551e7fad3903f7a
|
2025-09-20 11:09:20 +00:00 |
|
stephan
|
22f9ca64db
|
Get about 1/3rd of the tests running with MEMORY64=1, but the code noise level added by the BigInt/Number discrepancy is making this very unattractive. There are apparently irreconcilable differences between MEMORY64=1 and 2, in that they have different argument type expectations for methods such as WebAssembly.Table.get(), where MEMORY64=1 requires a BigInt a MEMORY64=2 requires a Number. We have no way to make that distinction from the JS code, and don't know what other APIs are affected by that quirk.
FossilOrigin-Name: 1e3b003ff99d2788d93e179504b711cb78846605774bf472589440d0136f20fa
|
2025-09-20 03:02:36 +00:00 |
|
stephan
|
6a03f2029b
|
Baby steps towards 64-bit pointers. Get it building and testing again in 32-bit builds.
FossilOrigin-Name: f35bb66e3eb939d321afb3545c184013633ce35fa4cbd67b6be17a64997ece9d
|
2025-09-20 00:43:47 +00:00 |
|
stephan
|
d6403a2d2e
|
Initial experimentation with a -sMEMORY64=1 wasm build (full 64-bit). This compiles but does not pass tests due to friction between BigInt and Number types (e.g. Number(null)===0 but BigInt(null) throws, many functions are fussy about which of those types they'll take, and we cannot simply mix and match the two types transparently (1n+1 is not legal (but 1n>=1 is), so we can no longer do pointer arithmatic without hoop-jumping)). The library bootstraps but it's failing early on in tests due to this friction.
FossilOrigin-Name: cfd5c746a6111f49c9c83a56c3ef65223456306f2de6e20b36b1ca0c98b593e9
|
2025-09-19 23:21:00 +00:00 |
|
stephan
|
d4cc844a2b
|
Diverse cleanups and docs in the JS and kvvfs pieces. Functional changes: (A) ensure that the 'i32' JS/WASM func arg/result conversion works properly with a 64-bit-memory WASM build (which we neither use nor test but [https://webassembly.org/news/2025-09-17-wasm-3.0/ | the newly-ratified WASM 3.0] brings within potential reach). (B) Fix sqlite3_js_posix_create_file() to not deallocate its input array if the client passes in raw memory (the library has never used it that way but the API permits it).
FossilOrigin-Name: 79af65a694fbbb3d501fb2ebd835c259ca644e0dafdd71eeb9f0a7c0e9128a1e
|
2025-09-19 17:24:47 +00:00 |
|
stephan
|
6b8d7ac599
|
Expose the new sqlite3_set_errmsg() to wasm. Refactor JS's sqlite3__wasm_db_error() to wrap that instead of the WASM-specific routine which previously did that job. This resolves the TODO added in [ead8a3a94e].
FossilOrigin-Name: e447a50f3a3791c264a68000948daa64edb1857d51d256fbd1ff0f2c2b330d5e
|
2025-09-14 12:14:42 +00:00 |
|
stephan
|
c493e4516a
|
Correct a one-too-many-exclamation-points bug which caused the opposite of intended semantics in oo1.Stmt.pointer ownership.
FossilOrigin-Name: 91e709f36d36174534b4cf4ff548a558e66cca5e23a6c8c106bc43375fc3ce72
|
2025-07-11 19:34:30 +00:00 |
|
stephan
|
2ba5a93e8f
|
wasm: DB.wrapHandle() no longer accepts a DB object as its first argument, as there's no apparent use case for proxying one DB object with another. Doc improvements for the new code.
FossilOrigin-Name: 0ee19db02a9b9320681d4393d9ba52889d149eac8ee114fc7b7f52a57271c139
|
2025-07-09 13:43:53 +00:00 |
|
stephan
|
6276637075
|
wasm: add a few tests demonstrating that oo1.Stmt.paramaterCount's new impl does not change visible behaviors. Add the c-pp-filtered files to 'make clean'.
FossilOrigin-Name: 3fe61545967f82190011edb90b1be6a448b590555c7ba5f8e96494aeea8f88ce
|
2025-07-09 13:13:01 +00:00 |
|
stephan
|
240319decd
|
Remove some dead JS code and some extraneous debug output from test code.
FossilOrigin-Name: 6e73770a7f3845055e0130012d844c32c4a1bfdb87e8379c161e1a266a808143
|
2025-07-06 15:36:28 +00:00 |
|
stephan
|
4d453cc2ed
|
Experimentally add sqlite3.oo1.DB/Stmt.wrapHandle(), which allow DB/Stmt instances to wrap a (sqlite3*)/(sqlite3_stmt*) optionally with or without taking ownership of it. The intent is to enable mix-and-match use of the C API, the oo1 API, and any other hypothetical API which exposes those pointers. oo1.Stmt.parameterCount is now a property access interceptor like Stmt.columnCount is, but that doesn't change how it's used.
FossilOrigin-Name: 1227543b87c3320d6b80e0f61b88ea53b68779966a0295c4d6a1db6369c48207
|
2025-07-06 15:01:44 +00:00 |
|
stephan
|
5806a922ba
|
Minor JS test cleanups prompted by a linter.
FossilOrigin-Name: 764235a3d15fda55af85ebe3b5885fa27336cc0e979f1be2f6770b66a84bbe87
|
2025-06-21 16:33:05 +00:00 |
|
stephan
|
427d2cd57d
|
Remove some duplicated JS tests.
FossilOrigin-Name: d1cb9ed79d806f667c22f5ba9861451d4d0765aa3072e085831045cf3a39f8b4
|
2025-06-21 16:18:23 +00:00 |
|
stephan
|
6fcb7f22a1
|
Give oo1.Stmt.get() similar treatment to [8c187140a60b]. This is an internal change only - the API is unaffected.
FossilOrigin-Name: f5a7abc0a447273de40dacc463d267d26d4b62be56ee15baf05825791c2a7a6e
|
2025-06-21 15:58:20 +00:00 |
|
stephan
|
2f7f948fa7
|
Extend the SEE-via-kvvfs tests to include all three key types.
FossilOrigin-Name: fc001aa5ee978795c2ff670bea64db0b69b6bde98653769d9cede8825a28e698
|
2025-06-21 15:38:59 +00:00 |
|
stephan
|
0cdde5b44f
|
Rework how JS's oo1.DB.exec() flags its Stmt objects to make certain Stmt APIs illegal (i.e. throwing) if called while that Stmt is being step()ped by DB.exec() (which can happen via client-provided per-result-row callbacks). This is an internal change only - the API is unaffected. Remove some unrelated dead code.
FossilOrigin-Name: 8c187140a60b62dc3b6066b8615766d52b7a29a5de992cbb6d312dbb225a980b
|
2025-06-21 14:38:53 +00:00 |
|
stephan
|
2be0a700ff
|
Export the column-metadata APIs to WASM. Doing so requires a non-default build of sqlite3.c, so this is a proof-of-concept branch saved just in case SQLITE_ENABLE_COLUMN_METADATA ever becomes the default for sqlite3.c.
FossilOrigin-Name: 59db3f639d1073678805dea26a4686eddfb238f055aa90bd429fc7fd33241502
|
2025-06-18 15:37:04 +00:00 |
|
stephan
|
69eaadbee3
|
Merge trunk into the sahpool-digest branch.
FossilOrigin-Name: fc1eeb7d1f2880907b0fe71a8c572dd7cd74a5d65ec0177332976ad2f8c2b216
|
2025-02-26 03:32:52 +00:00 |
|
stephan
|
a32ea731a0
|
Add the pause/unpause capability to the opfs-sahpool VFS, as discussed in [forum:fe8cdb8431c|forum thread fe8cdb8431c]. Summary: this gives clients a way to eke some degree of multi-page/tab/Worker concurrency out of this VFS but requires that coordination to be implemented client-side, e.g. via a SharedWorker or WebLocks.
FossilOrigin-Name: b5dbd521951e129b4dec69f191a872500dbf387b34a8479ad58b053ffcccbab9
|
2025-02-20 04:14:26 +00:00 |
|
stephan
|
6e5802fc74
|
Improve the JS-side sqlite3_set_auxdata() test to also trigger the case that the aux data actually gets reused. Test changes only, no library code.
FossilOrigin-Name: 9f27379d860518e6e097a2c999da04176812260a61bf11fe495c3efd76971806
|
2025-02-03 18:01:42 +00:00 |
|
stephan
|
3cd34ab981
|
Rework [76c8435a] to eliminate automatic JS-to-WASM function conversions of sqlite3_set_auxdata() destructors because it can leads to leaks on every call of a UDF. This feature never worked before [76c8435a] but fixing it was ill-conceived because of the memory leakage it introduces. WASM function pointers can still be used as destructors in this context.
FossilOrigin-Name: 3fb993af0caf041da934cea29c039b27c468be0b75bce1537a6425767cf9bf8d
|
2025-02-03 17:34:12 +00:00 |
|
stephan
|
40ce00b546
|
Initial work on a fix for the SAHPool VFS's effectively-no-op digest calculation, as reported in [https://github.com/sqlite/sqlite-wasm/issues/97|ticket #97 of the downstream npm subproject]. This requires more testing alongside databases created before this version to ensure that it's backwards-compatible.
FossilOrigin-Name: 9234c33f92d92bfddc6211c9c587f1072e70837c0ffe1416ef7d84d59bacd364
|
2025-02-03 16:26:30 +00:00 |
|
stephan
|
d98689f4d3
|
Add a more complete test for [76c8435a] and add some commentary about (A) the inability to automatically clean up automatically-generated WASM proxy functions for sqlite3_set_auxdata() destructors and (B) how to deal with (A) to avoid leaking WASM proxy functions.
FossilOrigin-Name: d693c2dddbd10a2e0b77893b04b11502e30b768f1b06814105f7f35172845fb9
|
2025-02-03 14:55:56 +00:00 |
|
stephan
|
82f3052e61
|
Expose the new SQLITE_DBCONFIG_ENABLE_ATTACH_CREATE/WRITE and SQLITE_DBCONFIG_ENABLE_COMMENTS (from [325e547a21955]) to JS/WASM.
FossilOrigin-Name: 8da1a9af66f905c683e9c3445d609b5c0e11ac912be192c468ddd79f237837f4
|
2025-01-31 18:45:03 +00:00 |
|
stephan
|
654c94d683
|
Cleanups in the opfs-sahpool VFS pause/unpause feature and its tests.
FossilOrigin-Name: 184ba37702f63196deca91d273e798ca895fbb301938e6264bc82815a4e33149
|
2025-01-31 14:25:38 +00:00 |
|
stephan
|
8883deb30e
|
Add experimental support to pause/unpause an SAHPool OPFS VFS, as discussed in [forum:fe8cdb8431c32455|forum post fe8cdb8431c32455], the intent being enable a page to relinquish, perhaps temporarily, the VFS such that the VFS's storage can be accessed by another page/tab.
FossilOrigin-Name: 1d2683fe9e4be01c3137e750900f54d287e7d96185e66924d24b50f4647e7ef1
|
2025-01-29 11:08:11 +00:00 |
|
stephan
|
7398e279a7
|
Remove a flaky JS test which has a result depending on unrepredictable context. That same feature is more reliably tested at a later point in the same script.
FossilOrigin-Name: 3d6ae13805bdba4c73b7443f20073264cdd157299cb911228600e1528a136bb1
|
2024-11-22 16:45:43 +00:00 |
|
stephan
|
2f70d5838a
|
Fix a JS test which was broken when OMIT_PROGRESS_CALLBACK was _not_ used.
FossilOrigin-Name: fba23150b5b57980f8ed2656a2325f95215ca1e13fc3449b5eec804831dd65c8
|
2024-11-21 15:53:31 +00:00 |
|