Commit Graph

1453 Commits

Author SHA1 Message Date
stephan
bb51af68f4 Move ext/wasm/version-info.c to tool/ for re-use in build other dist bundles.
FossilOrigin-Name: 4b0871fd367b6d9706e892aa13f64604967f5e3ba92381960f73aeabd3d23f84
2023-08-10 17:32:37 +00:00
drh
73cdbeb632 Fix an issue in the amalgamation generator in which it was not correctly
expanding the SQLite version in the header comment.

FossilOrigin-Name: 293f6191e9b328cb8a8d3fff0f7bd5a6f5390b5ff090497a170c791b6ea22917
2023-08-08 16:53:12 +00:00
drh
9b1334b7d3 Unix builds now assume the presence of nanosleep() in the standard library.
The -DHAVE_NANOSLEEP=0 compile-time option can be used to build on systems
(if any still exist) where this is not the case.

FossilOrigin-Name: 779d5dc8797ea246d0397f7e94b1be716b0baa735e8d9f5a6fc4cffd887a7420
2023-08-03 12:41:30 +00:00
drh
521f20e3d3 Add the --nolongdouble option to speedtest1.c.
FossilOrigin-Name: 6bf6018a00d61c5f0e53b37b00befaf5ad1d85323f41cf0cea25d8c6c1017096
2023-07-03 15:11:28 +00:00
drh
1e24dc987a Small performance improvement and size reduction by recognizing that no
SQL keywords have less than 2 characters.

FossilOrigin-Name: 6b3d25b7982623ab4b25161aff9ab44778e136069043ab425543597c42c98ae5
2023-06-19 20:54:49 +00:00
drh
2f764eb4f4 Improvements to the src-verify.c utility program so that it continues to
muddle through a corrupt manifest file, making the most sense of it that it
can and reporting "manifest" has having changed at the end.

FossilOrigin-Name: 157b5d25e0c99eabfa3c32cb867fe7e3c05031c12354f734d2cd8a4062b9439c
2023-06-08 16:19:21 +00:00
drh
8efe749ab3 Fix the amagamation generator so that it works one a clean source tree.
FossilOrigin-Name: f502610d03a1362eea936129abd03390835b7e47ba25e6799b2e7880de540640
2023-06-08 15:30:10 +00:00
drh
fd5d18045a Include source provenance in the header comment of the amalgamation.
FossilOrigin-Name: e3eb5af9050aae1db6887d17a560a24e4ca58f232ad7ac7c283c861ea4944f0b
2023-06-08 15:27:35 +00:00
drh
4fa5952090 Enhance Lemon so that it remembers which -D command-line options are actually
used in the grammar and includes a list of all such options in the header
of the generated output file.

FossilOrigin-Name: c47a4dbd24b8277c57b7a83a8c0aeac2bc8f6ab75d1b65ba5e1fa83d1868d95f
2023-06-08 12:52:28 +00:00
larrybr
55be21647e Fix straggler misspellings and tidy the custom dictionary. Also include pickups from [forum:/info/c61fb09afd|forum post c61fb09afd].
FossilOrigin-Name: 8c291d99946eb32b20b743921202f9c7cfb716268ff526817b27adbb7942e40b
2023-06-07 17:03:22 +00:00
larrybr
bc91738e66 Add a C-source spell-checking facility. make misspell (on Nix)
FossilOrigin-Name: 26c1bb4bd9e9f56613c3aa87407a7f562fd4ebde5bfd6dece02078001d9a45f8
2023-06-07 08:40:31 +00:00
drh
25e87ed1ba Fix compiler warning in src-verify.c.
FossilOrigin-Name: 2d58c77448cfaaf12887b60bcfea039d3410a750ac8955a817c45be85c00eb9e
2023-06-05 17:12:33 +00:00
drh
706047470e Generalize the src-verify.c utility program and provide additional documentation
in the header comment.

FossilOrigin-Name: 7ed84046ef0c2c64031cac3a3a6b43aac3ac40aeb36838d8d046493f2d5ed122
2023-06-05 01:05:46 +00:00
drh
979715bb45 Fix harmless compiler warnings in tool/src-verify.c
FossilOrigin-Name: 0e79ee97b18792dba9213bd9961f53e2bae765ac92df7963703d08857da74fd1
2023-06-04 22:59:20 +00:00
drh
10ca116b3e Enhancement to tool/src-verify.c to also check the manifest.uuid file.
FossilOrigin-Name: a39a569482a35610fdaa2fdfc88491d8b456dfedb4786c817e0502eb3e3a5563
2023-06-04 22:56:31 +00:00
drh
63329ce6c7 Add a prototype implementation for the "verify-source" Makefile target.
FossilOrigin-Name: ed876ff6a1a6a2d555f32b96eb78d95eaf8428ee189f968c43f0829a3065bfa7
2023-06-04 22:41:52 +00:00
drh
4308b88dcd Fix an issue with sqldiff reported by
[forum:/info/9bd2155bdfae25a7|forum post 9bd2155bdfae25a7].

FossilOrigin-Name: 736a79c1491065f4ee77ce644af0e529e555ca733c78dbd55487d55d4ddbe5bd
2023-05-27 20:08:23 +00:00
drh
89caab8147 Update the tool/mkmsvcmin.tcl script so that it prints a one-line message
to explain what it has done.

FossilOrigin-Name: 4254f086419892634c80b0b915e14edea365adc6a45bcc75eecba889da274ac3
2023-05-16 12:34:26 +00:00
drh
28f4e7b286 Enhance the split-sqlite3c.tcl script so that it uses single-character
extensions on subordinate source files, even when the number of subordinates
exceeds 9.  This is not yet needed, but might be soon.

FossilOrigin-Name: 4150e416263f24efcbfe68d5b1e15ec7e79df41dff0b6dfdc59f06ee9e205049
2023-05-10 16:04:04 +00:00
drh
e030619109 Updates to compile-time option usage and especially to the compile-time option
test script in tool/omittest.tcl.

FossilOrigin-Name: fece588b186c4f9f76d626313e35336fd5681e966e9bd0fa1053b147c4e3c315
2023-05-05 14:16:31 +00:00
drh
69e2422973 Enhancement to showwal such that it shows what the page hash should be
on a hash mismatch.

FossilOrigin-Name: 960dc97083ed9a7bfa912010b9ea19114f51dd10e73d5c5bf06cc642ebd1a2e7
2023-05-03 13:03:30 +00:00
drh
9e0181fcf7 Faster implementation of keywordCode() - the routine that determines if an
identifier is really a keyword and if so, which keyword.

FossilOrigin-Name: 0ff3d3d53709b7f18bf01ded1f988e41b7f8471072cf4f2702a3a8b79964be3f
2023-04-08 16:51:08 +00:00
drh
0bdee38969 Updates to speedtest1.c and the speed-check.sh test script so that they work
with the new SQLITE_DBCONFIG_STMT_SCANSTATUS control.

FossilOrigin-Name: bd02df052e1ef78b5335915a38f3c5e13c3c04ab82fd251aeb42a440d1d39257
2023-02-28 20:06:30 +00:00
drh
03b30b7abe Always use 64-bit integers for stats associated with STAT1 and STAT4.
FossilOrigin-Name: 6647d1cb8b53102c8114b1f3e34173d907504d78aa3140eab53f88027a36660b
2023-02-08 17:28:42 +00:00
drh
410a3bafed Improved detection of invalid command-line arguments to the showdb and
showwal debugging utility programs.

FossilOrigin-Name: 75cdaafc77b8a1efc84e71e90470994227f376e7d7de34c813e75dcadbb9f268
2023-02-03 12:03:56 +00:00
drh
e0237c00e1 Adjustements to the tool/warnings.sh script to account for compiler
differences.

FossilOrigin-Name: 863c03bee117e81bcea8c3ae78bf125afc7750aa5bcb89e42ee66d9c8b6ddc29
2023-01-04 18:32:14 +00:00
larrybr
0953c5354a Add base64() and base85() text/blob conversions to the CLI.
FossilOrigin-Name: 4bc98a2d9520efa9b80142163cbfab72a5f2fe9854cd6ba8291dcefdb872e657
2022-12-23 19:04:59 +00:00
dan
2adb309ead Have sqlite3_stmt_scanstatus_v2() return an NCYCLE value for all loops, not just virtual tables ones. The value returned is the sum of the NCYCLE counts for the various opcodes that move or read data from the table or index cursor associated with the loop.
FossilOrigin-Name: 9499b2f51e8174c6b8a67840c92ba23b7dd1dc8dc2b91fca0c5dc07b71662149
2022-12-06 18:48:06 +00:00
drh
878b44c128 Add TOTAL rows to the output generated by tool/vdbe_profile.tcl.
FossilOrigin-Name: 9800586393c9d3b82459ef657620d245a7985ef5fa389b8a9ea633d6a29c7299
2022-12-03 18:21:30 +00:00
dan
63b74e02a7 Add Makefile.in targets for sqlite3r.c and sqlite3r.h, versions of the amalgamation that include the recover extension.
FossilOrigin-Name: 59a837cfc7f9f96509491c8fc45355d2e8892af25246955e22adec1cbf37327b
2022-11-22 16:12:53 +00:00
drh
80fafc25ce Further improvements to the handling of the u32 and u16 typedefs in the
shell.c source file.

FossilOrigin-Name: 55a19677d723147aeb2b4a86bbd01756ddeb2072cba72c3145ad32d335e203b0
2022-11-07 19:40:20 +00:00
drh
d9324a5226 Improve the ability of mkshellc.tcl to remove redundant typedefs from the
generated shell.c code.  This is needed to get shell.c to build on older
C compilers.

FossilOrigin-Name: 3645585f37631d60cefab1d55cdb1ee060aae87317b9b158a01329ca8a4d3e1e
2022-11-07 18:36:02 +00:00
stephan
49507d2af6 Minor doc updates in speed-check.sh. No code changes.
FossilOrigin-Name: d2ed4116fbf1de3c840f84e05db6f29f7b489518ac07d56f61df153deab6bf6b
2022-11-07 17:21:53 +00:00
mistachkin
f5e7691e2b Minor updates to the Windows batch tools.
FossilOrigin-Name: b42f56205fa8e06431fb1a45c48257d93605fea0ed95bd766f71e27292d1af33
2022-10-30 07:01:31 +00:00
stephan
3725af73b9 Add SQLITE_DQS to the compileoptions_used list, per request in [forum post 8b1060122b|forum:8b1060122b]. Force DQS=0 in sqlite3-wasm.c.
FossilOrigin-Name: fcd9e0dbe3226f3f7ccc15b11fc3aa3b8058571bef274c25a33e9753e22f7551
2022-10-21 17:48:49 +00:00
stephan
b5e2e6fcd3 More work on the JS end-user deliverables. Add tool/stripccomments.c to support that.
FossilOrigin-Name: 2156f0744acfe425457430a0f6a7e02de907de85edba81a6d4eef40293e561c8
2022-10-18 20:36:50 +00:00
stephan
7be51f5897 Merge trunk into fiddle-opfs as a preliminary step for a clean merge in the other direction.
FossilOrigin-Name: 5e1848ce384a78fe5dfa1b5c1b2acb9c2fac34a8f0ba6c652e0541dcf24e9027
2022-10-12 16:35:22 +00:00
drh
a4b2f41938 Change the name of the autoconf-generated configuration file from "config.h"
to "sqlite_cfg.h" to work around a bug in a dependency checker, reported
in [https://twitter.com/josecastillo/status/1577136108097314816|a tweet from Jose Castillo].

FossilOrigin-Name: 897e187cad981126fc5f6ea8e382e937825af10b0c9589b0a23b9fbaa4ca58b8
2022-10-04 10:35:10 +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
3e4e697d1c New run-time options to the speed-check.sh script.
FossilOrigin-Name: ff46bc9d2a844dde9dafa157114f4d9ee157205ca5c08ed9ee32f018de310e62
2022-09-12 16:07:24 +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
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
5187c955f6 The new --script option to dbtotxt.c looks for an SQL script at the head of
the file and generates a CLI script that will construct the database then run
the SQL.

FossilOrigin-Name: 6170e638ebeb12cc40c3247324237978401f701afc270de88ad03e183e82cefc
2022-08-15 18:36:08 +00:00
drh
c8e9f6818b Omit the (undocumented) SQLITE_PCACHE_SEPARATE_HEADER compile-time option.
FossilOrigin-Name: 60947da687d525e72e62bcddcdf4c5c819818855074cc318c9ee656e83897aef
2022-08-09 14:28:54 +00:00
drh
064390b2b1 Performance improvement in resolveP2Values(). Save over 1 million CPU
cycles by omitting the loop termination condition and exiting when the
OP_Init (always the first opcode in any VDBE program) is encountered.

FossilOrigin-Name: bb179140c8abfd9d05d62380daba027bdeabbbafc720b7e36b99a36af806017e
2022-07-01 19:42:12 +00:00
drh
2b0ea0204f Enhance the TCL scrip that generates sqlite3-all.c so that it outputs all
text in its original order.

FossilOrigin-Name: 83ff1a28e3e7a99fa90d5079897d76529c4256eed859bf7cb98b860fbedfdc5b
2022-06-22 18:51:47 +00:00
larrybr
b885744709 Give dbtotxt an option to prepend .open --hexdb
FossilOrigin-Name: afeee6125d141ae281658a5f7b73e9b77bc252fa387678b2b5837488180bf108
2022-06-22 14:00:24 +00:00
drh
db08a6d13c Fix the parsing of C-style comments in Lemon, as reported by
[forum:/forumpost/b6edc69548|forum post b6edc69548].  This has no affect
on SQLite itself.

FossilOrigin-Name: 201569e09b000919ccb463bd581fb2ecd5320e7f584fdb1bc2aaba111061d5c3
2022-04-07 14:13:32 +00:00
drh
8f1eb6f5e4 Add the sqlite3Show() family of debugging interfaces under SQLITE_DEBUG.
No changes to deliverable builds.  Rename SQLITE_ENABLE_SELECTTRACE to
SQLITE_ENABLE_TREETRACE in ctime.c.

FossilOrigin-Name: bc33168cf1f48caf848c2dc5c3ae15e4efff8c0378f944eb5398a245139a2b35
2022-04-06 12:25:04 +00:00
drh
a7c9dd546b Change the OP_Next and OP_Prev opcodes so that they invoke
sqlite3BtreeNext() and sqlite3BtreePrevious() directly rather than through
a function pointer, for improved performance and a decrease in code size.

FossilOrigin-Name: 9d13cbbef3cf64f281d3e100f23f1b2ed6e8d65920c7517a84e1e4f964ceff2e
2022-02-24 14:44:23 +00:00
drh
f2a777fa5d For the "PRAGMA database_list" statement, do not check to see if the schema
is up-to-date and do not try to reload the schema.

FossilOrigin-Name: 710de6a2137c872812effa43ea888aa77d339362ca0b6c8990d4426c8fb20689
2022-02-22 20:29:31 +00:00
drh
a12500005f Remove stray tab characters from auxiliary source code files.
FossilOrigin-Name: e25e33582b69289a2c3a6bc403e3911de22a3b529db1a565efb9f1af01b9e382
2022-02-21 13:44:51 +00:00
drh
91260dcf83 Add SQLITE_OMIT_JSON to the compile-time option test sequence.
FossilOrigin-Name: f36325a6e21c4d3b6ab48ebfb2efabda089281344d1e61949d1c9290e88395b1
2022-02-21 13:02:23 +00:00
drh
dedd51aed4 Remove references to the now-defunct SQLITE_ENABLE_JSON1 compile-time option.
FossilOrigin-Name: db950192c93db7f5eb4ffcce41d0ea374c58450405945cfb8ebe0c93070b7c48
2022-02-17 14:33:13 +00:00
drh
697c50b947 Do not allow the vdbe-compress.tcl script to generate structures named
"do" or "if".

FossilOrigin-Name: e35ab16dd0fd40b07a71d26e1cdb19ef664a2a628a4abcb2e130f5e555de8ca9
2022-02-03 14:37:06 +00:00
drh
ddbb3cb5ec Remove code from lemon.c that was made superfluous by
[1b22b42e59793af1|check-in 1b22b42e59793af1] in late 2017.

FossilOrigin-Name: 6d2f95a474a0c196f36317d88557bfb449ce125c1d012fc1844378c450697a05
2022-01-14 23:28:11 +00:00
larrybr
04f97602e2 Make tool/mctimec.tcl effect more regular and obvious
FossilOrigin-Name: 02aaa10f34ab17e76feb7b6f79048309536c0794fcb534b934e06f3daedfeaba
2022-01-12 01:42:50 +00:00
drh
c5432c43e8 Fix mkctimec.tcl with the updated compile-time options for JSON.
FossilOrigin-Name: 8ded3f5b0025eb6cc11669c1208681e592862ce352dfff11173dff68daafad30
2022-01-12 00:52:34 +00:00
drh
9dbf96bd70 An attempt to integrate the JSON functions directly into the SQLite core,
rather than holding them as an extension.

FossilOrigin-Name: 583b47d865fb8d2c9ae4d3a4e70356a8a758978efb0a282f6b19775bf41fb748
2022-01-06 01:40:09 +00:00
mistachkin
2b5fbb2836 Fix harmless compiler warnings seen with MSVC.
FossilOrigin-Name: a9bfb621091b6d92d1caeb69134d3809d9e0b43fe764608c5995db277ac785be
2021-12-31 18:26:50 +00:00
drh
7e910f6422 Add SQLITE_TESTCTRL_LOGEST and enhance the LogEst utility program.
Improvements to testability of bloom filters.

FossilOrigin-Name: 88b43d798cc5aa59855e92d3e658aee9f0a5def6ffbc5db77af048d75ecdf8cc
2021-12-09 01:28:15 +00:00
drh
5e90794b67 Minor tweaks to the way auxiliary tools are built, to make it easier to
customize the builds without having to alter the code.

FossilOrigin-Name: 90b06b6f42918852cfb15258be462c6bed260c6a618b86fa9084bac72fa2f58f
2021-11-18 20:56:59 +00:00
drh
4e86aa86ea Fix lempar.c so that Lemon can compile with NDEBUG defined.
[forum:/forumpost/f331adca0b|Forum post f331adca0b]

FossilOrigin-Name: ba4fb51853fbcb8c142a350b4db0d59153f28ba0a63ad9a2d6fea7096d3dd544
2021-11-09 01:48:15 +00:00
drh
80b957b753 Add the --strict option to speedtest1.c
FossilOrigin-Name: a247b5d88c12b1952b656e4f069c9229e0886ba16d7018ddf600e74592224792
2021-11-03 12:50:28 +00:00
drh
1076130a5d Fix harmless static analyzer warnings in auxiliary build tools, mkkeywordhash.c
and lemon.c.  No changes to the SQLite core.

FossilOrigin-Name: f2f279b2cc1c8b3b162058c33956be4037cd519715ac0c4290f10c58d2528f0a
2021-10-04 16:14:51 +00:00
drh
253888c13b The pragma_table_list virtual table should have only one "schema" column.
FossilOrigin-Name: 886feffaad6baac37dfaab489c2aecc4abf51a3a5bce1e8a94be7cc1d2a3c30c
2021-10-04 13:30:22 +00:00
dan
37f3ac8faa Change things so that SQLITE_OMIT_VIRTUALTABLE implies SQLITE_OMIT_ALTER_TABLE.
FossilOrigin-Name: 2f7c946c5f25a858167f5193ca06e53310394c8cff15426ab8a1327a1ec835fd
2021-10-01 20:39:50 +00:00
drh
2e50f67073 Add the "PRAGMA table_list" command with its corresponding eponymous
table-valued function: "pragma_table_list".

FossilOrigin-Name: 2c0e7ae541e9ecb86aa58fa7e7057def8aac1b1af1af1aa80b8bf2d260f9a2f9
2021-09-21 17:26:23 +00:00
larrybr
31aa366293 Make replace.tcl useful with TCL 8.4
FossilOrigin-Name: 2dd61dd97b0326b59b0bc3c83b4d4b9acf811c5acae4d1003e7525ba7a26daf5
2021-09-10 22:00:43 +00:00
larrybr
2c09a8ad6f For sqldiff, sqlite_schema comparisons must use compound (synthesized) PK.
FossilOrigin-Name: 5bdd8466129b8e477c8349847f19f2a5adea3f650cca6dbafa3b835e5a538d09
2021-09-07 20:58:49 +00:00
larrybr
a933ec4c25 Make sqldiff able to compare sqlite_schema tables (for detailed schema differences.)
FossilOrigin-Name: 7ff92da9f183bc24a0d93996df771df7a712df1122ad897cb9143cde7d57ef7d
2021-09-07 19:04:42 +00:00
drh
6d77a2948e Patch lemon to fix "error" token handling, according ot
[forum:/forumpost/e680f42f53090061|forum post e680f42f53090061].

FossilOrigin-Name: 106b5e5355a3836a9756333e6dcbb13f0878a5352dab00973b8f0900879bd724
2021-08-27 11:26:37 +00:00
drh
8eaf6c620e Improvement to error handling in Lemon. No impact on SQLite.
[forum:/forumpost/2f468f43cbc48d7f|Forum post 2f468f43cbc48d7f]

FossilOrigin-Name: 18cc2f85744a18b6810d30baebe07a7a1bd332348e13b1a50d779edc616fb0c1
2021-08-20 19:51:22 +00:00
drh
d519bbdf5c Fix an off-by-one error in the error-handling logic of the Lemon
parser-generator.  This does not affect SQLite.
[forum:/forumpost/cff80737bf|Forum cff80737bf].

FossilOrigin-Name: 7cca80808cef192fe0479477056a028e230a164fd368e72100def065d424ca2c
2021-08-17 19:59:09 +00:00
drh
d519c03669 Attempt to fix the showwal.c utility program so that it works on WAL files
larger than 4GiB.

FossilOrigin-Name: 5c0f9ea98a2b944857fe05d53a0143cb827b7d8215c37f33f1bce47ec1189952
2021-08-06 19:38:23 +00:00
drh
15482bc3f3 Fix harmless compiler warnings. Omit redundant copies of os_common.h and
hwtime.h from the amalgamation.

FossilOrigin-Name: 091427007818537bb2f860c42dad867cb19050899186d4d180d195a1c6a98798
2021-08-06 15:26:01 +00:00
drh
20de9f6cb1 Minor tweaks to various TCL build scripts so that they work even for TCL 8.4,
which is obsolete, but is also all that is available for some legacy platforms.

FossilOrigin-Name: 2269ce64f707c4a198fcb9a72933648ea61a80b4251024b8058ff28ad81b4917
2021-07-29 16:49:28 +00:00
larrybr
1ae057d873 Remove sqldiff --visible-controls option, make it always happen. Add test cases for controls made visible
FossilOrigin-Name: ff74c0cc4cefa5271b12ecfff3f2fd4749852d9d1d01f4ae64a07a26decc001b
2021-07-26 19:49:01 +00:00
larrybr
e40875d211 Give sqldiff --visible-controls option to deal with non-graphic text content robustly across platforms
FossilOrigin-Name: 68d2373f5d578cf3aff9d1ac4b1ab3ac00b466e94e1eb516523fc7660dfc0549
2021-07-26 18:28:24 +00:00
drh
b4d9b2b537 Demonstration code to show how NOT NULL and CHECK constraints can be
verified after an ALTER TABLE ADD COLUMN.

FossilOrigin-Name: 039f540373b03af9e0c87499e5e0423eb093d1d343829282a5ac1de2d600b881
2021-07-20 07:35:07 +00:00
mistachkin
e13dfe4b19 By default, do not emit #line directives in the amalgamation.
FossilOrigin-Name: bacfa93677fbe014737fab7dbdb4e7a168a310bc5b914b17896ae2a48435c7b1
2021-07-15 23:34:14 +00:00
drh
480f5e3e6e Change references to the schema table in sqlite3_analyzer to the new
SQLITE_SCHEMA name.

FossilOrigin-Name: 3beb77d6a792d07ca605ec8e5402b8a305860cba4044fcafeed00b9fa862fa16
2021-07-15 16:39:42 +00:00
mistachkin
696555d7b5 Further revisions to #line handling for amalgamation builds.
FossilOrigin-Name: 9a84321229ad499ee0f7c85732c2728afb4476c72073a510401a559dda9be38f
2021-07-13 21:59:22 +00:00
larrybr
4902235796 Merge from trunk, rename tool option for its effect
FossilOrigin-Name: 9327f73c1b87fb9ca78e261d16b092763f497bb9c6f9784a33eabdc961b06343
2021-07-13 11:55:07 +00:00
larrybr
4b1c3eb5f9 Amalgamation has #line directives by default. Minor mksqlite3c.tcl changes
FossilOrigin-Name: ba3eff71973064cbc0ddf51aa822a246c162bbb65387e9523692c60e5340acda
2021-07-13 01:45:04 +00:00
drh
a612c1c9bc Add the ATOMIC_INTRINSICS compile-time output output. Move sqlite3Int.h
in front of ctime.c so that default values that are not overridden are
shown in PRAGMA compile-time option output.

FossilOrigin-Name: e306952690bfb140e2c404a74b05ff2d070c487f7e52c62d62a004505fba0e15
2021-07-05 18:37:37 +00:00
drh
a4df1bd5ff Adjust the mkshellc.tcl script so that the generated code always uses
unix-style line endings.

FossilOrigin-Name: 9f69af4dbcb273519fa87b7868f3792560fb71b192f4ffe53b8b465334da5ae4
2021-06-16 15:56:09 +00:00
larrybr
d95a652025 Avoid ominous warning in showdb.c
FossilOrigin-Name: f8d7ac0104b76555142ce0d32714594f42d19b311dce2f77f42f92756b5e0c93
2021-06-16 13:26:40 +00:00
drh
26ec568d28 Try to avoid a double-free in the showdb utility program when running
pgidx on a corrupt database.
See [forum:/forumpost/a60ea5a4d4|forum post a60ea5a4d4] for context

FossilOrigin-Name: e3188a866362894d98521b3006fb5b9a63fe4a3bb2ff4f1b58acb6eb4e52da8f
2021-06-08 17:56:16 +00:00
mistachkin
f9ac1ab1e7 Fix issue in 'mkopcodeh.tcl' tool that prevented its termination in rare circumstances.
FossilOrigin-Name: a8d921136f8ab132279984a77d0eeaf355342cdb0a98d7e1e59c8e6c8ed9459c
2021-06-01 21:07:49 +00:00
drh
48a296c589 Add the merge-test.tcl script to ease verification of LTS branches.
FossilOrigin-Name: f958ffbc61c693b71538cc3aa5f95ce0f0b5d4906efbb0c075f543e19883a669
2021-05-27 16:31:04 +00:00
larrybr
14e250ac16 Incorporate ..._DESERIALIZE revision.
FossilOrigin-Name: b70587cca9e4f0116621e27362186e9329bcea8016c6565cd3ec5a9bf4a99d46
2021-05-19 20:01:53 +00:00
larrybr
4f878f33a9 merge from trunk
FossilOrigin-Name: 19ffe3cfe278a4046f32df56f75080c2377e4c44ad40a02d39db8e7701526204
2021-05-19 19:55:10 +00:00
drh
e74ca517b4 Improved comments on the generated opcodes.h file.
FossilOrigin-Name: f2a17f1fad08779486e4d50d0d9277c7f87a9558a53af1a68aa5fe2ec30e820e
2021-05-18 12:36:35 +00:00
drh
8d889afc0d Enable the sqlite3_serialize() and sqlite3_deserialize() interfaces by
default.  Omit the SQLITE_ENABLE_DESERIALIZE option and replace it with
the SQLITE_OMIT_DESERIALIZE option.

FossilOrigin-Name: 6df3b03e00b1143be8fed3a39a58ce81063020275aa1ac13d87c84f1ceda6e27
2021-05-08 17:18:23 +00:00
larrybr
3ec4861c00 merge latest trunk
FossilOrigin-Name: 3ff228249adf2da345d3e19e9af3e23d1354f6b9a35ddbe9864e1a07716d871c
2021-04-27 04:47:27 +00:00
drh
2f40dc9884 Better error messages on showdb.
FossilOrigin-Name: 7e18e114b245d17aa259ea9ab42752ccc9ad5303bbac8d8e46928dd10319f545
2021-04-27 00:05:03 +00:00
drh
19a7f72ce2 Improved robustness of the "showdb" debugging program when it is parsing
corrupt database files.

FossilOrigin-Name: 3eabac2ee50fd70b22a927d3d2934718a15e1f666d8d271b854579156c8b01de
2021-04-26 23:57:02 +00:00
larrybr
5ae13144ef Dial back assumptions on compile option defaults to reflect actual conditionals.
FossilOrigin-Name: cb3127725dbb9490f9bb3a95d7fd52acd78390981ee8b7c6da35bdfb84ad0359
2021-04-16 10:25:54 +00:00
larrybr
cf5ad4210e Merge from (forked) trunk. Handle compile options that differ from default by being 0.
FossilOrigin-Name: 6eb83f83d280f82bd225972f52c52922257303740a968457ff0be08d43993d59
2021-04-15 23:43:25 +00:00
larrybr
f8fb27f4a9 Bring pragma compile_options up to date. And make mkctimec.tcl help do so.
FossilOrigin-Name: 63ea3e298c575a408e5c5e12368292c966db6dcffcb6e1c770734f28b8757635
2021-04-15 00:26:34 +00:00
drh
a875b72d6b Add the SQLITE_ALLOW_ROWID_IN_VIEW option to omitttest.tcl.
FossilOrigin-Name: 83b8e4c281c5295950fbf2330a45193b73054b0749b51a6c2c4fbc79a7a5f82d
2021-04-07 18:08:23 +00:00
drh
9cffb0ffb9 Document the "%token" directive for Lemon. This directive has been in place
for a while, but was previously undocumented.

FossilOrigin-Name: 36624d3740a8d095eee061bcc5037deabddb88a53444ec1a956a8af7684efa43
2021-03-28 20:44:01 +00:00
dan
42470513b7 Fix a problem in sqldiff virtual table hanlding to do with tab and other non-space whitespace characters in the CREATE VIRTUAL TABLE statement.
FossilOrigin-Name: 1737e4fdfc9a3628415b234338a68a64cbbaadb23598517761e571ab7ed7ad14
2021-03-17 11:25:42 +00:00
drh
745912efac Add the AS MATERIALIZED and AS NOT MATERIALIZED syntax that works like it
does in PostgreSQL.

FossilOrigin-Name: a6bb272ec0c758ab069bfc07443624e0ea7910b1f23224ee078d050fa3ccf068
2021-02-22 03:04:25 +00:00
drh
2053f313bf Lexer and grammar rules for a RETURNING clause on DELETE/INSERT/UPDATE.
Actually making this work, though, will involve a lot more code which will
likely slow down processing for the common case where there is no
RETURNING clause.  Furthermore, RETURNING seems to be of limited usefulness
and it is not standard SQL.  So we abandon it here.  These experimental
changes are parked in a branch as an historical reference.  If circumstances
changes, we might take up the cause again some day.

FossilOrigin-Name: abf8da815646055df5b871d54b99994c1470182dee7952fc5fd627e4379406cb
2021-01-12 20:16:31 +00:00
drh
c2dbf35f49 Fix harmless typos in comments per
[forum:/forumpost/7849e58dd5|forum post 7849e58dd5]

FossilOrigin-Name: d1e22e2f76cce7eb9f9029646176daef2d9e41c7bb1d3e1da182fbdd0096605c
2021-01-07 16:10:14 +00:00
drh
e81f879f51 In Lemon, factor the parser stack overflow detection logic out of the
yy_reduce() subroutine and into the main parser routine, so that when overflow
is detected, it can exit immediately.  This saves a single conditional in
the main loop of the parser.

FossilOrigin-Name: 203c049c662380411522d0c7c493201331bbb2792a7c5b12684f04f532a0695d
2021-01-02 23:56:37 +00:00
drh
bb497fe36d Parameterize the hash function in mkkeywordhash.c. This was an attempt to
find a better hash function, which turned out to not be successful.

FossilOrigin-Name: 2195d731f51a18f917c4299d8f4c7ee7c139c2527f62869d6da171a6d1d89ea6
2020-12-02 02:58:05 +00:00
dan
aff1a57f4d Fix trivial memory leaks in the shell and sqldiff programs.
FossilOrigin-Name: 272793e5edc47e431be77d589718a001f2696869e3e15f1371a1890645a995a7
2020-11-17 21:09:56 +00:00
mistachkin
d5157e01b8 Enhancements to TclKit batch tool for MSVC.
FossilOrigin-Name: 2a8a4552112be6e39e3475e9a8579582b5157086d3efd37971463c0e3958068d
2020-10-14 21:31:20 +00:00
mistachkin
273ee15121 Fix harmless compiler warning seen with MSVC.
FossilOrigin-Name: 4591ee03d7a1ef3f0f6ad0629493fdb7a1c0ddb3277a9e87aa244cb0ca770593
2020-09-21 20:18:44 +00:00
drh
9ca41fbfa9 Remove a new assert() that the compiler finds is always true at compile-time,
to avoid a compiler warning.

FossilOrigin-Name: 8bbaee238593741da107b92b254cb5f0cf8b6bcc760bf2b25d20e46c8edee2a9
2020-09-20 13:33:28 +00:00
drh
79d9af960b Attempt to silence harmless static analyzer warnings in Lemon and in the
Lemon-generated parser.

FossilOrigin-Name: de8ce22a46c90afa5475cd24c28b7a82b26410dc72d662af2f9d9e5e528e0eec
2020-09-20 12:10:28 +00:00
drh
18ef40e563 Fix harmless compiler warnings in Lemon.
FossilOrigin-Name: 6c94ba4b1c16b676978808dcb24f63c2f22915af5dcfe9f635c037011affcf4b
2020-09-16 16:55:56 +00:00
drh
786142a994 If an amalgamation is created using SQLITE_ENABLE_UPDATE_DELETE_LIMIT,
ensure that it can still be compiled without that option by setting the
SQLITE_UDL_CAPABLE_PARSER flag in the preamble.

FossilOrigin-Name: 5b905d7d7714d1d2c433ff58f5d6917d6d27302d44ca347aa740e768f1354b16
2020-09-10 12:41:46 +00:00
drh
2b75d3beb0 Fix a bug in Fossil that might cause it to crash if there is
a multi-terminal token with a space following the "|" separator.
This does not affect SQLite.

FossilOrigin-Name: 430c5d1da57af452f236cc862139d84ab97b6020f6d327dae5268c58e6e83a87
2020-09-05 06:21:54 +00:00
mistachkin
52cfe0312a Fix harmless compiler warning.
FossilOrigin-Name: a711e8cd2c7b64e06241736ecef478ac64ddbe7b58e0933b6febba63f7fb06e1
2020-09-01 19:02:52 +00:00
drh
512aa78ca2 In the Lemon output, add a prefix comment that explains that the output file
is automatically generated and shows the name of the source file.

FossilOrigin-Name: d34caf3bb63d0512ea116a8c8c8343b76aa39441bd4b3e98231747a705b91d54
2020-09-01 12:26:55 +00:00
drh
60c71b02ca Lemon updates: (1) include the #defines for all tokens in the generated C
file, so that the C-file can be stand-alone.  (2) If the grammar begins with
a %include {...} directive on line one, make that directive the header for
the generated C file.  (3) Enhance the lemon.html documentation.

FossilOrigin-Name: 84d54eb35716174195ee7e5ac846f47308e5dbb0056e8ff568daa133860bab74
2020-09-01 11:20:03 +00:00
dan
e0404386f2 Fix an inconsequential memory leak in sqldiff. Update the "Sanitize" case in wapptest.tcl to use -fsanitize=address,undefined, and to run more tests.
FossilOrigin-Name: 613fb5c2525be77e48bad0a74e8b7bf53489365060fb9c7713a0caddb1820c71
2020-08-14 16:14:40 +00:00
drh
b19493434f Add the --checkpoint option to speedtest1.
FossilOrigin-Name: 4cffa9bb44d6f0bdb23cae913adfb224f0814e65a2abb9120179f0b288e70f77
2020-08-07 14:47:55 +00:00
drh
55550b7602 Enhance showdb to be 32-bit clean.
FossilOrigin-Name: a8200327d4e8e78abef09c64345e0036f730fbbb20ae88935ef6c9972e6c7d5e
2020-07-22 11:42:50 +00:00
drh
4e6861d23d Add the "enlargedb" utility program used to construct very large database
files for testing.

FossilOrigin-Name: 66858d87507bfdd17bb76c0afb1108ad5dec752438a79bf57f0f51690232e943
2020-07-20 14:54:36 +00:00
drh
0a34cf551c In lemon, add "%if" and "%else" and allow boolean expressions as the
argument to "%if", "%ifdef", and "%ifndef".

FossilOrigin-Name: 951d22b72f80de9e23df645abcc3d88ca1a275b46ea23b84152ef48716922b37
2020-07-03 15:41:08 +00:00
drh
4b849b0b09 Fix the pragma_foreign_key_check virtual table so that it accepts arguments.
FossilOrigin-Name: 07f849dee3d245ecf80ba3c3ce8dfc630e71ddb1e9c0bcc1f08cee22001fcb07
2020-07-03 12:32:04 +00:00
drh
6df54c30fc Improvements to speedtest1. Added the --memdb and --output options. The
--verify option now outputs a hash of SQL outputs.  The speed-check.sh script
disables the hashing feature with --legacy and adds the --verify option.

FossilOrigin-Name: f3455cecf22ea98f9ad48e92d620c8e2ec94877e4581731afff0f2bd32014a1d
2020-06-26 15:42:55 +00:00
drh
3c99dbb18b Add --verify to speed-check.sh and add --memdb and --output to speedtest1.c.
Other improvements to speedtest1.c.

FossilOrigin-Name: 89a11120ab2ce13f8a539cb05a9d0628a1f83b4790910b2023c21d60aabc43ee
2020-06-26 14:05:58 +00:00
drh
0f40e8dd41 Update the showlocks utility program so that it functions on files with
a huge number of locks without overflowing the stack.

FossilOrigin-Name: adb7484f93329c7a94cd84e30bc4a8dbf2d6e901eba17cc3454afb8ba346cbf4
2020-06-25 23:21:09 +00:00
drh
24aee8af6e Try to remove end-of-line whitespace when building the amalgamation.
FossilOrigin-Name: be3e7814e4cdbc09eaa5112d7d4135b3a2cedbfe66217d9973b1b39a44464e93
2020-06-23 17:57:08 +00:00
mistachkin
96e3c39bd5 Reverse unintentional spacing change in the previous check-in.
FossilOrigin-Name: c7b2ee1edb108430454578c1623ba6aee1e2a7bc30cb2f9884ea3e21c3b75635
2020-06-19 15:35:07 +00:00
mistachkin
7cff0e34e0 Include 'sqlite3rc.h' in the amalgamation archive targets.
FossilOrigin-Name: 3df579ca32e8250725957d1982897a43281c73e8373af49abd6e7bd674f30e74
2020-06-19 15:33:23 +00:00
drh
067b92ba00 Extend the refactoring into extensions. Clean up stray newlines.
FossilOrigin-Name: 7a876209a678a34c198b54ceef9e3c041f128a14dc73357f6a57cadadaa6cf7b
2020-06-19 15:24:12 +00:00
drh
1e32bed3c1 Further refactoring of the schema table name.
FossilOrigin-Name: 9536fa0ae0c1ae6e2e98d2fa11e5acda7f3c9b8ca5061b6f7f8cae63a11d936b
2020-06-19 13:33:53 +00:00
drh
477a357278 Add support for PRAGMA analyze_limit and approximate analysis.
FossilOrigin-Name: 812547525d35df975f40cbbeb604cc9cd2dec809c1ca083cbb139fe59ffa1d73
2020-05-02 03:46:32 +00:00
drh
51f1c6f3ec Merge recent enhancements from trunk.
FossilOrigin-Name: 96dfc71ea599702ef38b60952d03e95dce5a8c534cd943e076e9c76b00e61e65
2020-05-01 18:58:21 +00:00
drh
e754830eae Merge recent trunk enhancements.
FossilOrigin-Name: 2100b2c8f339e9778723fa0c91e479bab8675cf6fbea1664b6af49f40db6d27b
2020-05-01 15:04:13 +00:00
drh
542bd6521e Fix an off-by-one error in the "calculated" page count output from the
sqlite3_analyzer utility for databases that are more than 1GB in size.

FossilOrigin-Name: 8789368b91fb5b7477bdba3a953412fc3839b4894443b65186f7b8f79f6369c9
2020-04-22 13:49:25 +00:00
drh
49a76a8fe5 Add "PRAGMA analysis_limit=N;" to limit the number of rows visited by
ANALYZE when N is positive.  Positive N also disables collecting stat4.

FossilOrigin-Name: a279b151c1623807774daf4975175c62ea252eefb71f9820ced6773769b392c5
2020-03-31 20:57:06 +00:00
drh
691b5c54b8 Infrastructure for the bytecode() table-valued function. The function itself
is not yet implemented.

FossilOrigin-Name: 2795f0d633577e0de66b389d9e8e44c55e85975bdc62f1a0b8f93959d19b22bf
2020-03-23 15:49:22 +00:00
drh
b48c0d59fa Simplify the code by removing the unsupported and undocumented
SQLITE_HAS_CODEC compile-time option

FossilOrigin-Name: 5a877221ce90e7523059353a68650c5fdd28ed032807afc2f10afbfbf864bdfe
2020-02-07 01:12:53 +00:00
drh
0de19cac43 Unroll the comparison loop inside keywordCode() for to avoid unnecessary
comparisions and thus help that routine run faster.

FossilOrigin-Name: cec5f920f5c2a963f88329a08a443fc04be2dd6f7f2d840be63c0ab1de898f0a
2020-02-06 15:38:43 +00:00
drh
ef9f719d0b Fix #ifdefs so it compiles cleanly with all SQLITE_OMIT compile-time options.
Update compile-time option testing.

FossilOrigin-Name: 7584e4b649d57767aac3906da6b06549d5b772aaa69f469c623ae5da834d54d5
2020-01-17 19:14:08 +00:00
drh
c1f73e29bf For the showdb utility program, more accurate detection of when the database
is in autovacuum mode for the "pgidx" subcommand.

FossilOrigin-Name: 9ce2192b81a81bb8928e3184664694ed2f863ce41c2777cdc35e6b61486aea46
2020-01-14 13:24:14 +00:00
drh
2b1c2aad9f Create the "trusted_schema" pragma. Add sqlite3_vtab_config() calls to set
the risk rank for many virtual tables.

FossilOrigin-Name: 4c21373c21c9b17b222ae65297a039a035e6ec6b505c00c33704e3c03f94f834
2020-01-07 19:45:40 +00:00
drh
79d5bc80c7 Enhance PRAGMA function_list so that it shows all instances of each FuncDef,
the number of arguments, the encoding, the type, and the flags.  Use this
capability to locate and fix incorrect function flags in the standard build.

FossilOrigin-Name: 9ca906d24a2e88eddb2fd067783512b66cfc49dce1596d816a1c38a09d128218
2020-01-04 01:43:02 +00:00
mistachkin
e99cb2da5f Export the public RBU entry points from the Win32 DLL.
FossilOrigin-Name: e62d1791f428b7a9bb14a59483f12d8ee08afbf4061a5e3be8f64787444301e7
2019-12-20 17:41:15 +00:00
drh
59c5679691 Fix incorrect SQL generated by the Lemon change of the previous check-in.
FossilOrigin-Name: fccfb8a9ed3c1df9f23762bb8df6fdf36a21118899e3fae41f451169a5f2c08e
2019-12-19 13:17:07 +00:00
drh
3e5f7fef33 Modify the parse.sql output file from Lemon so that the RULE table contains
a column with the complete text of the rule.

FossilOrigin-Name: 329cbb372d4d77f774f01a87d104c40ef42d713afbe76195b65f5ca205c5ea7b
2019-12-19 12:29:31 +00:00