Skip to content

Update SQLite to 3.47.2#2237

Draft
azizcodesthings wants to merge 1139 commits into
tursodatabase:mainfrom
azizcodesthings:codex/update-sqlite-3.47.2
Draft

Update SQLite to 3.47.2#2237
azizcodesthings wants to merge 1139 commits into
tursodatabase:mainfrom
azizcodesthings:codex/update-sqlite-3.47.2

Conversation

@azizcodesthings
Copy link
Copy Markdown

Summary

  • update the vendored SQLite source tree to 3.47.2
  • preserve libSQL-specific parser, shell, pager, WAL, and planner integrations during the upstream merge
  • regenerate bundled sqlite3 amalgamations, headers, and Rust bindgen outputs

Test plan

  • cargo xtask build-bundled
  • LIBSQL_DEV=1 LIBSQLITE3_SYS_BUNDLING=1 cargo check -p libsql-ffi
  • LIBSQL_DEV=1 LIBSQLITE3_SYS_BUNDLING=1 cargo check -p libsql-ffi --features session
  • ./libsql-sqlite3/libsql -version

Notes

  • build/checks emit existing generated-C warnings for ALIGN macro redefinition and a non-void generated function return path
  • configure warns that Tcl regression tests cannot run locally because no tclConfig.sh was found

dan and others added 30 commits September 9, 2024 19:12
FossilOrigin-Name: d8103684f660ff9b3186d0f89afb113ca580bd16f0bf413ed8a9434236b54426
…iting

a NULL page.  Experimental.

FossilOrigin-Name: eb3c89ee2e4c5425be75deaf46a06a9cd8b210c695b918dd63a78f930c6e6b63
… to be stored in indexed columns of fts5 locale=1 tables.

FossilOrigin-Name: 55c5c119a0a77fac2c9f46d718ef78c0f33ed3520e10c240cf5bf1801e0586ee
… was not defined.

FossilOrigin-Name: 437849c80851da842b5c4fd37d5c147f821abc541e9b4d6f9000c12983548844
Does not work.

FossilOrigin-Name: 397b2d37b7a6619b0c1eee201065585d03496f94786b21540f613e4716d56612
FossilOrigin-Name: 7d87a27a01311153ddee122cedecedc3bcc331618dc2ab1da397a3b257dc21cf
… to be stored in indexed columns of fts5 locale=1 tables.

FossilOrigin-Name: 198305de92ebba7045d8ec7d2de98511f3b00924f808a3811f061dca47b01ec7
…working

on the actual sync protocol.  Still experimental.  Still a work in progress.

FossilOrigin-Name: 9a1a95f523a96303aad57e2422c2b51ea7e125f5490f32f7a2929d49b6c69ef8
sqlite3_mutex_notheld() when compiling with TSAN in as much as those
routines cause TSAN to complain.  Response to
[https://issues.chromium.org/issues/41427446].

FossilOrigin-Name: db702dd78500a0839b0b2810a580d3634df49275470787b170973a86b73826d3
…n. It

does compile, but it does not work.

FossilOrigin-Name: fa06977b6db7fa745720561ec0b10570cf7e71598dc7a7c5ee650640e5bdf6f5
FossilOrigin-Name: 80461e0d724963aaf2646005298f1194c5f1c4c9ae41c1085d4d137ed485bd9f
…turns

a BLOB.

FossilOrigin-Name: fe65821a3b912f061026e6fd7174be26897010e6b474e2780350cac60faebaad
…sides

an opportunity to negotiate a suitable protocol number, for future
compatibility.  Send the page size as a power-of-two.

FossilOrigin-Name: df0623aae1154281157409f62d6d3fb3ce41829281d53bc55868ce44b3d36883
…mote

side, so that if the remote is the replica, it will have access to the
origin database name in case the replica name is really a directory.

FossilOrigin-Name: 435c30171d3c6073b7aaf5cc11cc4813f6a2d225ae6dce1b0e478f0cd5a0b532
debugging.

FossilOrigin-Name: b979d02ffd1370d8840328bce06c76c224f0fc1fb54b47d6c904547580a820a1
FossilOrigin-Name: e385525793c7d74ce8ee139c9d6cfc1248834754598f3fd45b22b9426ff106ee
… make the arg handling more robust.

FossilOrigin-Name: 53fb9b11807ff7accd8cd41f9cb6516d2503f161ea976940437a1d3aae868665
FossilOrigin-Name: b2a3497e5525dd33faf70961107a0529f476735fef756953c66e105747271c6d
PTRMAP entries that extend off the end of the database, as long as they
appear to be well-formatted.

FossilOrigin-Name: a9f95fe5ce90ab9864165e603f3a34013c3c98d03f1db689996f4a32086e2ed6
FossilOrigin-Name: 75d5a8eb3d4ece06900109ad4022ba2a3e82de2f0acb012e3a02bfb4326bfa6d
…invalid

entries that are within the range of the database file.  Continue to ignore
invalid entries beyond the end of the database file.

FossilOrigin-Name: 4cad385b90eaca2d90e3375e473472145af4134160b81097a8535d06638c2e4a
of 160.  This uses about 1/3rd fewer CPU cycles.

FossilOrigin-Name: 96c7f47a8f59e5078bd296979421c1b57fbcb7be261f8a7a0b1d22a4b5914db0
corrects that to just 6 rounds.

FossilOrigin-Name: 3c36f5814f25483586c4fd49ef2fe5c7c0ff8c59672b1622c92061ec0ba8547a
FossilOrigin-Name: e55e3e8ec2fe3a9190872d999cee55c85bde92667040cc166233faaa2fa34266
…1 feature, into this branch.

FossilOrigin-Name: d2f0d19936222911bc317efecc831007d3aba81f9b32877030ffb29d1728bbdc
…forum post, "sqlite3_analyzer not closing WAL-mode db cleanly" ].)

FossilOrigin-Name: 94ceac98845e31249b656dcdb8a58f456b9212dc83968ea333852a66d72a0dae
FossilOrigin-Name: 86e0219d977c493ac19d00c3ddcf560eb317d506c7cf6e4ef17e92daa91e1762
…toring the values of fts5 UNINDEXED column belonging to contentless tables.

FossilOrigin-Name: c51dc2a5e75baacbd905cf314e7b1a58a81993ff05ca656739e028d7db25d5b2
ATTACH-ed databases within the same transaction.

FossilOrigin-Name: 6aa9c8e79b440c6419e65990d9ceba8f00a6f975455138cf2aa82b113daec825
FossilOrigin-Name: dff76b7a3436031ea5a61b8a44ddfa1d40ea20c983f3d34a8501cd7074db68b8
stephan and others added 30 commits October 24, 2024 16:02
FossilOrigin-Name: 31e104cc40e335108b57afe8184782ad389b1e8ecc526e1e60417f00f94560ad
conversions on Windows.

FossilOrigin-Name: e3c27c6d8a8610ac4ad8ad95e0958ffad05fd58a086c67709f6ac132acff9b35
…s == is apparently not as portable across shells. Problem reported in [forum:14274389fb2|forum post 14274389fb2].

FossilOrigin-Name: 68199c40fedeb07a3f9c5024fac6376a0579a13b0e5690aef6238e3e22b9c1b7
…io.c, as reported in [forum:7dd7c70038 | forum post 7dd7c70038].

FossilOrigin-Name: 5238959d05bbf3c12f488a55e52f3e9733138993d0365255184dffeb2bf36c03
…e contraints on the "value" column with usable=0.

FossilOrigin-Name: 1333e54422649b886629e6fb6ebc8ff8c6ce104d5ba334cbfb95e6fb84fae8ac
…atabase records.

FossilOrigin-Name: 521b873be7863b6c009641db1f2636fdbe032d209ca39aa4da6671a72b5791f3
…led correctly.

FossilOrigin-Name: 17bc57fa16096177684ee7246d2996219eeb7178c7687af808b5f56d8decd5fa
…013b] and [d1663cf05f7d].

FossilOrigin-Name: 38136b33f9536b63520d3810f397a3b4b5372028b31108806f84fe44bf338425
…the is-writable-dir check and to filter out //zipfs: dirs as (im)possible installation targets.

FossilOrigin-Name: 2f6e5946cf34e0948e177aa12a4a768fcd6dc413909a97566e0abff51230c87c
…of the auto_path search loop early if the DESTDIR is not writable, rather than re-checking that repeatedly.

FossilOrigin-Name: 322be94569d196a66b3671100e880f32f85777c248a662866b0579a6392a24dc
views or triggers, since the text of those elements is not part of the
original query.

FossilOrigin-Name: cb5ddebf79f824672045cbc660ffc896e82a769e1312ab5925d334ce1e7036dd
to give the copy a unique Select.selId value so that the original will
not be substituted in place of the modified copy.

FossilOrigin-Name: 16d46e116086948a704c03b7b6aecbb2c66cefca4418e8e5a9ffd05e0036c7d1
…nch.

FossilOrigin-Name: b50d20d7951311f1fbf37b228687990f515d2d5189d5c4892b771081298e0af5
FossilOrigin-Name: b6942a0b2f4a3dc7e09487f1ebf6129211be565283f95ff83823b057f628208f
test cases for when the test suite is run as administrator.

FossilOrigin-Name: 3f76388a47bd4cc181ce2e72c72d5e235edcae251785990dc568665016ec34a5
FossilOrigin-Name: 04d6124d341c637dfbeb280088173ba98fab22955d24a58027f519395f7fae88
…e context. That same feature is more reliably tested at a later point in the same script.

FossilOrigin-Name: 540a4a16241d35d2fcaa33ce8c0db74f8cd3f064f8a8a985e64032f58209888f
FossilOrigin-Name: dcef1992d55de1a8ff183baf355ec4cca23131343c6a6b30bb587aabf431d051
…ng multi-token strings.

FossilOrigin-Name: c8dcac33402daef74b6e55efaa9fcf38a7a5f3e3efcc34111e653ddb33ae944e
FossilOrigin-Name: b95d11e958643b969c47a8e5857f3793b9e69700b8f1469371386369a26e577e
…n. [forum:/forumpost/ab25469a350e0488|Forum post ab25469a350e0488]

FossilOrigin-Name: 86256f2cd4402268a1cc423940f49978e42c0fd00508799d1411690f7fe0a5bc
FossilOrigin-Name: a2061fe09faeedbcbbcc0928f7567cc9e15e1b5417126abf2ede0e58dbe7352f
…a WHERE clause term.

FossilOrigin-Name: e487d3b3c03ebcf06f8071f5c6a04faae15605200361e831df7bb2361e33efc3
…sions

fail for values greater than UINT64_MAX-2047.  This caused the SQLite
text-to-float converter routine to give incorrect results for values
between '1.8446744073709550592eNNN' and '1.8446744073709551609eNNN' for any
exponent NNN. Fixed by this check-in.

FossilOrigin-Name: 17537a98cb31ab41f0e02a8403b1480f8d86ddbfc263fd766e73b6b5a7dbba2f
FossilOrigin-Name: 42aa7157f8b549d4321a8811a8223a98f877b60f032f529fd3948dfc0aa54cd7
…roblem

originally fixed earlier today.

FossilOrigin-Name: 18b20494ce0d0f8eb87f1157245ebd728d2262f0d1d902a5934f240fc781b4e6
problem.  This one avoids complaints about oversize double values
from -fsanitize.

FossilOrigin-Name: 07bd06b13c42edb3a3efa8f26d48823c9ffa3d5ec8d06ee21a33b6c1d29b4726
FossilOrigin-Name: 2aabe05e2e8cae4847a802ee2daddc1d7413d8fc560254d93ee3e72c14685b6c
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant