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
drh
d3cd2a25b4
All legacy tests are passing. Want to add new test cases before merging.
...
FossilOrigin-Name: adb80761d2319e16b6db2b5e35fedc239fad0ed5d26d629a5ea659c90881f76a
2025-09-28 11:01:05 +00:00
drh
9ffb344ed9
The generate_series rewrite is working better now, but is still not
...
completely correct.
FossilOrigin-Name: 6c41d14707e6890ca6d0460c72178ccb710d7f41dead76f222f1382c5cbd5a9a
2025-09-28 10:36:23 +00:00
drh
5b047a8ec6
Refactor the generate_series extension. Compiles but does not yet work.
...
FossilOrigin-Name: 25e395a82f14513bf23c1e913fe24be77ad74fec1540f524e709f9cdfeb3dc56
2025-09-28 09:25:07 +00:00
drh
c2f7be11bb
Fix harmless typo in a comment.
...
FossilOrigin-Name: 1f6deabfff2fc2fed5fbff48d2637b48245e5a946a442c4bcc9b9ecb7c4848b9
2025-09-28 08:59:16 +00:00
stephan
1d592e0d62
Internal js/wasm tooling doc updates.
...
FossilOrigin-Name: 0d6ed44278a513b062539f32da49fa43952fcdf0bc1bba7b24ef3749bc4525a5
2025-09-28 02:30:25 +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
drh
54f296389c
Rework the bounds calculations on generate_series() in an attempt to
...
avoid signed integer overflow when the bounds are ridiculous values.
FossilOrigin-Name: 3d9148c7d7379a34a0c2a33a1eb2562234868bc0b14c3d16990b33e52fd4ebc5
2025-09-27 15:03:11 +00:00
stephan
41549103ac
ext/wasm/c-pp.c: add #savepoint support. Consolidate how the diverse sqlite3_stmt handles are managed.
...
FossilOrigin-Name: b44650f907e9cb4ec908bb7525488e309946fac9d84cdac4cdde730527a440a9
2025-09-27 13:34:02 +00:00
drh
c090488133
Use sqlite3_malloc64() and sqlite3_realloc64() everywhere in the CLI.
...
FossilOrigin-Name: b05c47009120840f74955114082f3a9c1206a81bd935a503fc359b5bde61c996
2025-09-27 13:00:37 +00:00
drh
943324c80d
Fix a bug in the ".dbtotxt" command of the CLI that causes a NULL pointer
...
dereference if run on an in-memory database.
FossilOrigin-Name: 865352499223c3bdc5cb01a2f984d6e3fe74a028ab6a0cf2d92fec49383633f6
2025-09-27 12:35:25 +00:00
drh
18af487597
Avoid integer overflow in memory allocation for the
...
".import --csv" command in the CLI.
FossilOrigin-Name: a8093d45e0f59fd55ea4cba515e9e2eb3683bb0a4f4c062747cfb4074ae3db73
2025-09-27 12:29:28 +00:00
drh
15e4074084
Additional cleanup and refinement of the regexp.c extension.
...
FossilOrigin-Name: 2b34b750b5528b6dda195bc1a3895dc3fe46e70cbf992a78111316e2726c1ade
2025-09-27 11:54:49 +00:00
stephan
4ac2118c5d
Teach c-pp how to replace configure-script-like @tokens@, giving us a much simpler way to get the proper WASM file name injected into each JS build.
...
FossilOrigin-Name: ffd5c8eaa89250a043b573c3eb66693dfec087a5b5eef184ae6d7bfbcf61235a
2025-09-27 11:38:35 +00:00
stephan
4bdfae9d40
Remove and edit some comments.
...
FossilOrigin-Name: 1fa7e32d264f8329a8c9b0b5b469f1fc7ccadee86696d65e05df7fa3868af158
2025-09-27 00:07:25 +00:00
stephan
5d0d30ae2d
Add wasm.ptr to the module-symbols.html output.
...
FossilOrigin-Name: dced5a7c434b83553ede533f71e3133450795c12fc67acd1a55fdedfa8fed76c
2025-09-27 00:05:13 +00:00
stephan
836e895f9e
Latest upstream c-pp.c for the ability to process multiple inputs and outputs in a single invocation.
...
FossilOrigin-Name: c7633373046ceb94f293b8fbd4f436a1eb281c2744d97334c6e7e3a803d8eac2
2025-09-27 00:04:28 +00:00
stephan
879066a0a2
Delay replacing the wasm file name strings until they're needed. Add target b-all to run all known wasm builds.
...
FossilOrigin-Name: a4edaecc9b0b649df53a99e05d9abfbc5bdb40d45c7c6940a50b24fa30dca158
2025-09-26 19:41:07 +00:00
stephan
e309de27f9
Consolidate some duplicate code in mkwasmbuilds.c.
...
FossilOrigin-Name: 1078aa4f1e5685d45e31eea622865ddd077f367f1cec90fc267e8ba50cbe2ee9
2025-09-26 19:30:34 +00:00
stephan
a34f87d25a
Clean up how the speedtest1 64-bit test/demo files are generated. Make log output very slightly less verbose.
...
FossilOrigin-Name: 64715e92708e4f8c5b82c1f4ed71b75f418bf741f7f05516eab309582fbfad2b
2025-09-26 19:19:35 +00:00
stephan
42f9273da2
Get 64-bit builds of speedtest1.wasm running in order to better compare 32-/64-bit performance (spoiler alert: the latter is consistently roughly 10% slower). Add WASM heap usage info to speedtest1.
...
FossilOrigin-Name: 70b944cc0189309c2265b184381f2f050bced7b83f204d57b912def6e203982a
2025-09-26 18:29:00 +00:00
stephan
96c753ec56
Reinstate the Module.instantiateWasm() override and simplify how the wasm filename gets injected into the JS files.
...
FossilOrigin-Name: e878ffd2eaa87e2978c44fcd03a1eb6114a9ae31e31101898d682f43cf81000f
2025-09-26 17:11:39 +00:00
drh
b62c26d999
Limit the complexity of a REGEXP pattern using SQLITE_LIMIT_LIKE_PATTERN_LENGTH
...
FossilOrigin-Name: 869c968569b09d05a5b7d587d8fddb3b4611daf7467dc157701e5dc6c9608606
2025-09-26 15:38:52 +00:00
drh
80d74f0934
In the regexp extension, limit the maximum value of integers in the
...
"{p,q}" syntax, as performance of the NFA used to do pattern matching
is linear in the maximum such integer. The limit is SQLITE_MAX_REGEXP_REPEAT
which defaults to 999. This helps to prevent DoS attacks in systems that
make use of the regexp extension.
FossilOrigin-Name: 911c745f88c0ee8569e67bbcbbab034264f8c981b505aadac3ce7289486a1a68
2025-09-26 13:14:20 +00:00
stephan
3a94a00768
Get wasmfs build working in the new setup. Disable the custom wasm loader because its generated makefile code is currently broken.
...
FossilOrigin-Name: 36bc2514f70af5608aa20903d9c38b316603e2f78f2cbf4a20c7c79b60c5b8d5
2025-09-26 12:49:41 +00:00
drh
8d2f3a1f82
Fix harmless integer overflows caused by over-sized integer constants in
...
the "{m,n}" syntax of the regexp extension.
FossilOrigin-Name: 8f17e1d869685b51f3368feed03dc06543ec16bc8fd81b8daad2ac2dbf99c5d6
2025-09-26 11:53:54 +00:00
stephan
c839ea5d94
Docs and dead code removal in mkwasmbuilds.c.
...
FossilOrigin-Name: d022ee167b90a7c32049a93d476e869270018017f60551185024409730d77640
2025-09-26 11:47:13 +00:00
dan
6553a5d6a6
Fix some integer overflow problems when handling corrupt hexdb dumps in the shell tool. [forum:/forumpost/82b513b116 | Forum post 82b513b116].
...
FossilOrigin-Name: 730323f95d126162fd2867dbee1e1f1fc1d6e05b8a905a6767c4ab1cb43dacff
2025-09-26 11:45:13 +00:00
drh
c9f1759c94
Add new table-valued functions jsonb_each() and jsonb_tree() that work just
...
like json_each() and json_tree() except that the "value" column is JSONB
instead of JSON text when the "type" is 'object' or 'array'.
FossilOrigin-Name: dfc41cb3aad7fedd834baaaba0d8e3aeb55a249af4f0934397652ea9c59dc9fc
2025-09-26 11:36:10 +00:00
drh
a7a8d7fa87
Fix a harmless compiler warning.
...
FossilOrigin-Name: c50a3c45a20e5b9d48e749818bea06dfa99b729535e0617347c6ece1d277a447
2025-09-26 11:28:01 +00:00
stephan
e040128ecd
In c-pp.c, use (void)x instead of an empty if(x){} to flag unused arguments.
...
FossilOrigin-Name: df9ab8a35517e3a2baf4b19d07d46ce3f8b48043ccdeadef22bffc12e80461c3
2025-09-26 11:14:15 +00:00
drh
92f93556e5
On-demand loading of JSON virtual tables.
...
FossilOrigin-Name: 118f97ddcd8f888715825a623c02d42b92a82737a316f7bee4cd66f570945346
2025-09-26 10:29:07 +00:00
stephan
5ace5e0a38
More build docs. Add a speedtest1 64-bit build but it's not hooked up to any test apps yet. Improve invalid-arg detection in c-pp.
...
FossilOrigin-Name: 69086be8a155d70d9dd7b655b66809250b24fe6d5bcdc6cb5e0275446a43f51d
2025-09-26 02:18:28 +00:00
stephan
c1254430d8
Build cleanups and dead code removal.
...
FossilOrigin-Name: b516109e5accc885b71900402c800ae855407552648861334c895f0e5dea4ee5
2025-09-26 01:38:07 +00:00
drh
3574ec40a6
Add JSON table-valued functions jsonb_each() and jsonb_tree().
...
FossilOrigin-Name: 2f8b461c636ce2c0e7970c00d1e6ea62cdef72273150fea6aabe4e9292724977
2025-09-25 23:32:23 +00:00
stephan
ae48a2463b
wasm dist: add --snapshot flag, add -64 flag to include 64-bit builds, and add module-symbols.html to the dist.
...
FossilOrigin-Name: e9a6391b377b6964620285192262a4dc9fe1712799f7aa8a8b37c5f718544ed2
2025-09-25 18:53:28 +00:00
stephan
3e7fe489e2
Replace ext/wasm/dist.make with mkdist.sh and get dist working with the new build. Fix the preprocessing flags for tester1-esm.html.
...
FossilOrigin-Name: ab6eb4d3b723107da488770b1849b9f1d1c491348f1eaa544e0e07356b8fac7d
2025-09-25 17:29:12 +00:00
stephan
a4476ea1fa
Overhaul the wasm build to (A) support more coexisting variants, e.g. 32/64-bit of both vanilla and esm, and (B) build each variant to its own subdir so that they can build in parallel. It can, with make -j4, now build all new variants in half the time it previously took for just the 32-bit builds. The new build logging output, though unconventional, serves two purposes: (A) improve my build-time situational awareness and (B) it help demystify some of the build steps and output files.
...
FossilOrigin-Name: 2f4be98614b49def2c2951887796c736269ef3bb7ba5b045cae5f748ae165a83
2025-09-25 15:17:58 +00:00
drh
5ad6e7b0e0
Fix the translation of "\v" in JSON5.
...
[forum:/forumpost/28e21085f9c6a4e7|Forum post 28e21085f9].
FossilOrigin-Name: 2914e8fc7b10e8b42c9a0fbd0e71f495714cee3cae67b8c238d37b1e7ec22359
2025-09-25 15:06:57 +00:00
stephan
5dbbbf4923
Remove some superfluous tabs and add the mkwasmbuilds ability to emit just its prologue.
...
FossilOrigin-Name: 75079401753778e3bc2f7fa307de9217e8d1ec395079fc1009060f707be32943
2025-09-25 14:44:03 +00:00
stephan
96d39ce7d2
Minor logging fix for the wasm-opt build step.
...
FossilOrigin-Name: 918eca02d162cfa98613f9d8d9b0901f9f94ae1bcb53d811b09baec6c3f06bbe
2025-09-25 14:39:41 +00:00
stephan
653e32e9a1
Move fiddle.make into the main makefile. Various adjacent cleanups and docs.
...
FossilOrigin-Name: fabd6160d0c128592ce512b1160dfa0b89b1fbb03e11cd185c6a4888a85cc7fb
2025-09-25 14:29:47 +00:00
dan
31efe5a0f2
Avoid an integer overflow in the shell tool when outputing hex dumps of blobs greater than 1GB in size.
...
FossilOrigin-Name: 4a1bb874f12adda26e91970b64e700cb904c126412989be4debac9a5647d6f69
2025-09-25 11:10:55 +00:00
drh
dc868ef879
Convert the ShellText object in the CLI to use sqlite3_malloc64() rather than
...
plain malloc(). Avoid unnecessary quoting of table names in .dump output
and similar. Improved detection of OOM in set_table_name().
FossilOrigin-Name: 6ce4f6dc15a575c318669051fe6590ad114b52ff3f3e260cdf7accccdd922d63
2025-09-25 10:55:54 +00:00
dan
4d488bd341
Avoid an integer overflow ([forum:/forumpost/b3abe06121 | forum post b3abe06121]) and a compiler warning ([forum:/forumpost/3db6aa9ed6 | forum post 3db6aa9ed6]) in the shell tool code.
...
FossilOrigin-Name: 39925489b347ec3126389c6dba1ee719373e50c6cea6944384a212c3a3e163d2
2025-09-25 10:50:11 +00:00
stephan
3ed76ca35b
Minor build cleanups.
...
FossilOrigin-Name: 05e7ea021388fcac975779cd2a70e341e25670e70d1d9f372f15b823b2466750
2025-09-25 02:30:55 +00:00
stephan
99cb0049ee
Consolidate the speedtest1 wasm build into the new mkwasmbuilds.c model. Remove the long-unused batch-runner JS tools.
...
FossilOrigin-Name: 980c033c05bf37c0e8f5e82486ee99ba1294cc9c9e2087aaf83b64e5d0118b5f
2025-09-25 02:02:48 +00:00
stephan
ef565295f5
Wasm build deps fixes.
...
FossilOrigin-Name: fd0c649047f4e444ea682138a3555a973839627150e1124bb9d9ced17880a9e5
2025-09-25 00:53:30 +00:00
stephan
9daf58ee8d
Move the static makefile code from mkwamsbuilds.c into the makefile. Move util.make back into the main makefile. Remove a bunch of dead makefile code and docs.
...
FossilOrigin-Name: 18beeb26bfa48f806866e0e330024535adabcf668071abc4b6251eb39de2701d
2025-09-24 23:07:45 +00:00
stephan
3675a69f1d
Cosmetic makefile tweaks.
...
FossilOrigin-Name: 4ec7e6800e090f7e17469a77bc37b57d3e1777171a5b354dfc68345416de504f
2025-09-24 20:53:19 +00:00