drh
d963982049
Merge recent trunk changes into the sessions branch.
...
FossilOrigin-Name: 2d33afe0c43cb99caa521c48b721c3b0971e967c
2014-05-20 00:20:23 +00:00
drh
c007f61bb0
Repurpose the SQLITE_TESTCTRL_FAULT_INSTALL test-control to register a
...
callback to be invoked by sqlite3FaultSim(). That test-control has been
unused since 2008-06-20 and was never used in any official release.
FossilOrigin-Name: 0d43a7ad9abe821e33e0bf83a997aa4461b1e3f2
2014-05-16 14:17:01 +00:00
drh
224155dd1c
Fix long-standing typos in comments.
...
FossilOrigin-Name: b9f91317c34d07769a95dc2f905a6ccabceb64a3
2014-04-30 13:19:09 +00:00
drh
2e525f18e2
Merge all recent trunk enhancements and fixes into the sessions branch.
...
FossilOrigin-Name: e158812c34b01ce516d26636a489509bf61d1c27
2014-04-28 18:02:21 +00:00
dan
8ad1d8ba38
If the user provides likelihood() data for a WHERE clause term used as part of an index key, have the planner use it when calculating the expected number of rows visited by the loop.
...
FossilOrigin-Name: c51efaa5d29ee0a91b9e6a83a8dd82530670811a
2014-04-25 20:22:45 +00:00
dan
cfc9df76e1
Store values loaded from the stat1 table as logarithmic values in memory.
...
FossilOrigin-Name: 1bd74c49ddab6f53bb6eaa57907eff44c2580dd6
2014-04-25 15:01:01 +00:00
dan
374cd78c1d
Avoid discarding an ORDER BY clause in the case where an identical GROUP BY clauses uses an index to group, but not sort, the rows. Fix for [b75a9ca6b0].
...
FossilOrigin-Name: de9a490f594183f337a2ec9e0f87792eac83548b
2014-04-21 13:21:56 +00:00
drh
a1a483d54e
Merge recent trunk changes into sessions.
...
FossilOrigin-Name: 95e77efe076ab421bd246119c47dba5dacf9d087
2014-04-18 01:10:05 +00:00
drh
71794dbaeb
Add the SQLITE_RUNTIME_BYTEORDER compile-time option to force SQLite to check
...
the processor byte-order at run-time. Add additional compile-time byte order
checks for ARM, PPC, and SPARC.
FossilOrigin-Name: 2c5363873a6f990a0abaacac6303acd46b48befc
2014-04-18 00:49:29 +00:00
drh
2cf4acbd9f
Add the SQLITE_TESTCTRL_BYTEORDER test control to interrogate SQLite's notion
...
of the processor byte order and whether the byte order is known at compile-time
or determined at run-time.
FossilOrigin-Name: 9c6961967ae00e563ebe2859eaf2639a79f2cb01
2014-04-18 00:06:02 +00:00
drh
d249090450
Remove the unused second argument from sqlite3ExprCachePop(). Add an
...
ALWAYS() on an always-true conditional in sqlite3VdbeResolveLabel().
FossilOrigin-Name: ab23abf392175d3e256ff619b13abbbe732a49ed
2014-04-13 19:28:15 +00:00
drh
87744513e7
Make sure column cache elements are cleared correctly when jumping over
...
code for key generation in a partial index.
Fix for ticket [2ea3e9fe6379fc3f6].
FossilOrigin-Name: 3122b8364082be783821da01d4af2af6a9586327
2014-04-13 19:15:49 +00:00
drh
d83cad235a
Modify the OR-clause handling so that it can safely deal with OR-clause
...
with 17 or more terms. Fix for ticket [10fb063b1179be53ea0b53bb].
FossilOrigin-Name: a67b5312f63909737c052fe58ab5772d45530d49
2014-04-10 02:24:48 +00:00
drh
652cc4b6dc
Merge all recent changes from trunk,
...
including the fix for the OP_SCopy-vs-OP_Copy problem.
FossilOrigin-Name: 9515c8344a6743bbb0c6a6e49fb79fb3139090df
2014-04-03 16:35:33 +00:00
drh
a1f7c0a21c
Enhance the sqlite3VdbeRecordCompare() routines so that if they encounter
...
database corruption, they will set the UnpackedRecord.isCorrupt field and
return 0. The sqlite3BtreeMovetoUnpacked() routine detects this and returns
SQLITE_CORRUPT, causing the corruption to be reported back to the top-level.
FossilOrigin-Name: 7fa85eaaaf6d211378620d728a759fdfe30a15b0
2014-03-28 03:12:48 +00:00
drh
24ed9d0445
Merge in fixes (including the corrupt-database crash fix) and
...
performance enhancements from trunk.
FossilOrigin-Name: fc8ca1a87e7127bd28f32fd809aec3e24355fbfa
2014-03-26 19:43:30 +00:00
dan
b22f38a779
Remove unused variables Parse.nColCache and Parse.iColCache.
...
FossilOrigin-Name: 4d7551ce464c8038147e81667368924f2a7485a6
2014-03-24 16:30:06 +00:00
drh
9a4444778f
Add the ability to use indices for the first few terms of an ORDER BY clause,
...
then sort in batches to handle the later terms.
FossilOrigin-Name: fa06a6fed9f48322d9b89721799ba12c46efa898
2014-03-21 20:58:42 +00:00
drh
8e1ee88c88
Change the names of SRT_DistTable and SRT_Table used by CTE to more
...
meaningful SRT_DistFifo and SRT_Fifo, respectively. Simplify the
IgnorableOrderby() macro in the process.
FossilOrigin-Name: 45d8cc678d128f1dda6469864215a8ed9de4366a
2014-03-21 19:56:09 +00:00
dan
9afccba269
Avoid leaking memory in an obscure case where the flattener adds an ORDER BY clause to the recursive part of a recursive query.
...
FossilOrigin-Name: 1f413aca00015100224273480e1ce39a76bf93ab
2014-03-21 19:27:54 +00:00
drh
f9f1bdb0c8
Merge trunk fixes for "x IN (?)" handling.
...
FossilOrigin-Name: eca35871c34374ca9189c7c9b6d490ac3c30357f
2014-03-20 20:56:49 +00:00
drh
fbb24d1092
The "x IN (?)" optimization in check-ins [2ff3b25f40] and [e68b427afb] is
...
incorrect, as demonstrated by the in4-5.1 test case in this check-in.
The "COLLATE binary" that was being added to the RHS of IN was overriding
the implicit collating sequence of the LHS. This change defines the EP_Generic
expression node property that blocks all affinity or collating sequence
information in the expression subtree and adds that property to the expression
taken from RHS of the IN operator.
FossilOrigin-Name: 2ea4a9f75f46eaa928ba17e9e91bc0432750d46d
2014-03-20 17:03:30 +00:00
drh
4ef7efad5e
Fix harmless compiler warnings.
...
FossilOrigin-Name: b1435f26b07b2208cfcca557f96342a5bd0d5328
2014-03-20 15:14:08 +00:00
drh
079a307259
First attempt at getting block-sort to work. This is an incremental check-in.
...
There are many problems still to be worked out.
FossilOrigin-Name: 59742dd4c5259883850044d0938248b009ebd045
2014-03-19 14:10:55 +00:00
drh
f2eded23f5
Merge the latest 3.8.4 tweaks from trunk.
...
FossilOrigin-Name: 1ed463d91866182fbc884fb88770717ee5bf33ce
2014-03-06 13:48:31 +00:00
mistachkin
0d71d121ae
Better support for MinGW 4.x.
...
FossilOrigin-Name: 170e0585202eec6882e9513eba05e6d5767bfc5b
2014-03-06 00:28:57 +00:00
drh
3bde1354ff
Merge compiler-warning fixes from trunk.
...
FossilOrigin-Name: a1f2b0428518ec18af74a0e01deb4e40cd95a78f
2014-03-05 23:12:55 +00:00
drh
6d1626eb7c
Count the number of elements in a SrcList object using an "int" rather than
...
a "u8", to avoid overflows and to work around an issue in the C compiler on
AIX.
FossilOrigin-Name: eee2a13f2caa48b7b8a693680edc2bbc9275292c
2014-03-05 15:52:43 +00:00
drh
7826a9b83f
Merge the performance enhancements of trunk (and some obscure bug fixes)
...
into the sessions branch.
FossilOrigin-Name: 7f51ad97f0b24c57453d58faf25eee68861faa23
2014-03-04 14:34:14 +00:00
drh
a9e0aeb552
Do not assume that 'char' is signed. Make it explicit.
...
FossilOrigin-Name: 979da752e6f8767a61a8efed824ffad9605d0f4c
2014-03-04 00:15:16 +00:00
dan
3833e934d3
Remove the vdbeRecordCompareLargeHeader function. Fix some other details.
...
FossilOrigin-Name: 3861e853105cb8da344c7eebd2e455622b26395e
2014-03-01 19:44:56 +00:00
dan
a6efad8a97
Merge in latest trunk changes.
...
FossilOrigin-Name: 8f30b09518d23c3f6cecd244a66ef918fdb55323
2014-02-27 20:52:26 +00:00
dan
3b9330f83c
Further changes to sqlite3VdbeRecordCompare().
...
FossilOrigin-Name: 570893740067a7caa952f259fa078cdf67017d71
2014-02-27 20:44:18 +00:00
drh
0baa035a1e
Do not allow temporary registers to be in use across an OP_Yield within a
...
co-routine. Fix for ticket [8c63ff0eca81a9132d8].
FossilOrigin-Name: 97a8c9733cba97c78e979dfd5c66610c23e90288
2014-02-25 21:55:16 +00:00
dan
1fed5dab0d
Attempt to speed up sqlite3VdbeRecordCompare() by various means. This code is in an interim state.
...
FossilOrigin-Name: 85206e0bbac29adab52bef795f6d1479f2ae2c0e
2014-02-25 21:01:25 +00:00
drh
5e990bea51
QNX requires that _FILE_OFFSET_BITS be set prior to any system #include.
...
FossilOrigin-Name: 953cdd6adadfd46b51ad61d7939cecca154a02cb
2014-02-25 14:52:01 +00:00
drh
3d77dee935
Add the SQLITE_NOTNULL P5 code for comparison operations - really a composite
...
of SQLITE_NULLEQ and SQLITE_JUMPIFNULL. This flag indicates that NULL operands
are not possible and raises and assert() if NULL operands are seen.
Also omit an unnecessary scan of the sqlite_sequence table when writing
into an AUTOINCREMENT table.
FossilOrigin-Name: d2c047f304848e49864ed8c216b48fd671fa3916
2014-02-19 14:20:49 +00:00
drh
7d1761059b
Add VdbeCoverage() and VdbeCoverageIf() macros for improved VDBE coverage
...
testing.
FossilOrigin-Name: b92d31a97d5fe4606d9ae1393c7f3e052f46bf5a
2014-02-18 03:07:12 +00:00
drh
688852ab15
Add logic to do test coverage measurements on the VDBE code.
...
FossilOrigin-Name: ce184c7bb16988641d37c908d9b3042456d4be3d
2014-02-17 22:40:43 +00:00
drh
57bf4a8eeb
Avoid unnecessary calls to applyAffinity() during INSERT and UPDATE
...
operations, especially for table that have indices and tables for which
all columns have affinity "NONE".
FossilOrigin-Name: 35b4d6e938164fabaf30b504c54cfd9a69060cee
2014-02-17 14:59:22 +00:00
mistachkin
65acf373c9
Use the modern MinGW major version macro, not the deprecated one.
...
FossilOrigin-Name: 057c16ee9786efcad6372a29b02d743ff3d628ff
2014-02-16 19:20:00 +00:00
drh
05a86c5c0f
Enhance the code generator for INSERT INTO ... SELECT so that the SELECT
...
generates output directly in the registers that INSERT INTO will be using,
in many cases, and OP_SCopy operations can thus be avoided.
FossilOrigin-Name: aa2d8b0e8154dd2f5e2c837dc11ab362b083495b
2014-02-16 01:55:49 +00:00
mistachkin
a7b3b63524
Better support for MinGW 4.x.
...
FossilOrigin-Name: e147230767383ed9f64085b613fd18508f74be21
2014-02-14 23:35:49 +00:00
drh
5671ef69ec
Sync the latest trunk changes, and in particular the STAT4 IS NOT NULL fix.
...
FossilOrigin-Name: b006792695d23980e1923b21915d5c1138ecf29d
2014-02-11 04:30:29 +00:00
drh
d227a291b2
Use the WITH clause to help resolve names for SELECT statements on the left
...
of a compound query. Proposed fix for ticket [31a19d11b97088296a].
FossilOrigin-Name: 67bfd59d9087a987f15f6148efa1ff104983e1fb
2014-02-09 18:02:09 +00:00
drh
5f61229504
Do away with the "multi-register pseudo-table" abstration. Instead, just
...
use an OP_SCopy to load results directory from the result registers of
the co-routine.
FossilOrigin-Name: 1e64dd782a126f48d78c43a664844a41d0e6334e
2014-02-08 23:20:32 +00:00
drh
aceb31b120
Change the OP_Trace opcode to OP_Init and give it the ability to jump to the
...
initialization code at the bottom of the program, thus avoiding the need for
an extra OP_Goto.
FossilOrigin-Name: 192dea97316144f15f6dd0eabff08a0bf9ef203e
2014-02-08 01:40:27 +00:00
drh
dddf6978d2
Fix redundant definitions of _LARGE_FILE and _LARGEFILE_SOURCE.
...
FossilOrigin-Name: 4043d879795bfad55af35e9cb48e0a42eb4087ae
2014-02-07 19:33:31 +00:00
drh
ee06c99b49
Remove the SF_Materialize flag from the SELECT object as it does not
...
accomplish anything useful.
FossilOrigin-Name: 65d5dcddbd34dfb2733a7a908c7c652ce2d610fe
2014-02-04 20:46:41 +00:00
drh
7df89c8c8a
Rearrange fields in the Parse object for a tighter packing, resulting in
...
an 8% size reduction on x64.
FossilOrigin-Name: 3e1a3f68d7457ff708222a3448404b593f018fc2
2014-02-04 15:55:25 +00:00