]>
git.ipfire.org Git - thirdparty/sqlite.git/log
dan [Mon, 28 Apr 2014 20:11:20 +0000 (20:11 +0000)]
Do not reduce the number of rows scanned at all for "IS NOT NULL" constraints. Fix a bug in calculating the number of rows visited by scans of partial indicies.
FossilOrigin-Name:
a8ae93f0cffa116df0ba34d46a53f49d42dace41
dan [Mon, 28 Apr 2014 19:34:06 +0000 (19:34 +0000)]
The trunk assumes that an open range constraint on an indexed term (col>?) term matches 1/4 of the indexed rows, and that a closed constraint (col BETWEEN ? AND ?) matches 1/64. Change this branch to do the same.
FossilOrigin-Name:
4047ac75e2a8f0b330255501c42e4f04e5ab500d
drh [Mon, 28 Apr 2014 18:02:21 +0000 (18:02 +0000)]
Merge all recent trunk enhancements and fixes into the sessions branch.
FossilOrigin-Name:
e158812c34b01ce516d26636a489509bf61d1c27
drh [Mon, 28 Apr 2014 17:56:19 +0000 (17:56 +0000)]
Add the sqlite3_rtree_query_callback() API to the RTree virtual table.
(Cherrypick from the sessions branch.)
FossilOrigin-Name:
af2cbe64adab5f9e3b0f3da00d06428088589d7f
drh [Mon, 28 Apr 2014 17:51:12 +0000 (17:51 +0000)]
Add the sqlite3_rtree_query_callback() API to the RTree virtual table.
FossilOrigin-Name:
3dca2809352c6c6d56db74447a814f77011c6220
dan [Mon, 28 Apr 2014 15:11:25 +0000 (15:11 +0000)]
Update unordered.test to take into account for the fact that SQLite now prefers a full-table scan over a non-covering index scan that visits a large percentage of the table rows.
FossilOrigin-Name:
20f468dfbcb247e51446fad411a6e6cc0d130411
dan [Mon, 28 Apr 2014 12:08:23 +0000 (12:08 +0000)]
Add an extra column to a table in analyze9.test to give the planner a little more reason to select an index.
FossilOrigin-Name:
1b95544f84bf83c28cc15f6d0690fdf8a6bb3941
dan [Mon, 28 Apr 2014 10:00:59 +0000 (10:00 +0000)]
Update test script analyze3.test to account for the fact that SQLite now prefers a full-table scan over a non-covering index scan that visits a large percentage of the table rows.
FossilOrigin-Name:
35f46a55d866b9a87c1321aab8e0cfe86ccadb93
dan [Mon, 28 Apr 2014 09:35:31 +0000 (09:35 +0000)]
Modify internal function whereLoopAdjustCost() so that it does not prefer a skip-scan over a regular index scan even if the regular scan uses a subset of the WHERE terms used by the skip-scan.
FossilOrigin-Name:
88a5758dcce891eb7be15432ebdc9f80071d413b
dan [Mon, 28 Apr 2014 08:49:54 +0000 (08:49 +0000)]
Fix an error in estimating of the number of rows visited by a range scan.
FossilOrigin-Name:
d491de62fce69d93e89f65f7713972f7c2c451f7
dan [Sat, 26 Apr 2014 20:21:14 +0000 (20:21 +0000)]
Fix an sqlite3_stmt_status() problem caused by recent changs on this branch.
FossilOrigin-Name:
dee204092421a239f9f60ab83c3a5b3e24d1baea
drh [Sat, 26 Apr 2014 19:23:14 +0000 (19:23 +0000)]
Update requirements marks to fix typos in the requirements text.
No changes to code.
FossilOrigin-Name:
f5a263658187250044afc1a74000e6f6962733ca
drh [Sat, 26 Apr 2014 17:52:08 +0000 (17:52 +0000)]
Allow the xfer optimization to proceed if the DEFAULT on the very first
column of the two tables is different. This is a refinement of the
fix for ticket [
f67b41381a ].
FossilOrigin-Name:
349f483499dd685a8da94923b6bd810a52e5e236
dan [Sat, 26 Apr 2014 14:07:57 +0000 (14:07 +0000)]
Avoid transfering records between tables unless the default values for all columns are the same. Fix for [
f67b41381a ].
FossilOrigin-Name:
f8c4c495e6de1f124d205383d4bafa46accbff5c
dan [Fri, 25 Apr 2014 20:22:45 +0000 (20:22 +0000)]
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
drh [Fri, 25 Apr 2014 17:37:16 +0000 (17:37 +0000)]
Add test cases to ensure correct operation of joins with a virtual table
that include DISTINCT and ORDER BY clauses. Verification for ticket
[
388d01d4bb8f9 ].
FossilOrigin-Name:
5ada136f43ce744ae8c349eff39838eb44611b6e
drh [Fri, 25 Apr 2014 16:29:03 +0000 (16:29 +0000)]
Enhance the sqlite3_rtree_query_info object to report on the number of
elements in the priority queue at each level.
FossilOrigin-Name:
f7dad408dd46a1e3612b6142a3afb1d0d4fcda00
dan [Fri, 25 Apr 2014 15:01:01 +0000 (15:01 +0000)]
Store values loaded from the stat1 table as logarithmic values in memory.
FossilOrigin-Name:
1bd74c49ddab6f53bb6eaa57907eff44c2580dd6
drh [Fri, 25 Apr 2014 14:42:17 +0000 (14:42 +0000)]
Make sure ORDER BY clauses on joins that involve virtual tables and that
have a DISTINCT clause work correctly. This is a candidate fix for
ticket [
388d01d4bb8f9 ]. Test cases for that ticket will be checked in
separately.
FossilOrigin-Name:
171138122690faafde0dcab0201b90bdf02d3637
drh [Fri, 25 Apr 2014 12:35:31 +0000 (12:35 +0000)]
When VDBE_PROFILE is enabled, ignore negative opcode times, which sometimes
occur, perhaps due to context swaps.
FossilOrigin-Name:
4e88042f9d3e678914da96c0eb276f3d8fca5a94
dan [Thu, 24 Apr 2014 20:04:49 +0000 (20:04 +0000)]
Changes to the way the planner calculates the costs of various table and index scans. Some test cases still failing.
FossilOrigin-Name:
c5a6ec0a880652dc8f4593d9f7acd58ddc3dc5f3
drh [Thu, 24 Apr 2014 16:25:25 +0000 (16:25 +0000)]
Improved header comment on the vdbesort.c module. No changes to code.
FossilOrigin-Name:
bf09ce24d054bc68c226064f5f28d97e0e648a13
drh [Thu, 24 Apr 2014 15:06:25 +0000 (15:06 +0000)]
Reopen the orderby-planning branch and merge in the latest trunk enhancements
and fixes.
FossilOrigin-Name:
6077ddcd93318e24b9756adaaf293ba9fb3cedf7
drh [Thu, 24 Apr 2014 12:28:28 +0000 (12:28 +0000)]
Improvements to comments. Store some extra information in SqliteThread that
is useful for debugging.
FossilOrigin-Name:
9fb5e212089d85cdd3b4787dd69c72e6d84560b6
drh [Wed, 23 Apr 2014 12:57:55 +0000 (12:57 +0000)]
Merge all recent trunk changes into the threads branch.
FossilOrigin-Name:
e2c9f71a451e44040624b9f255b4510743513019
drh [Tue, 22 Apr 2014 19:42:22 +0000 (19:42 +0000)]
Change from using the win32-none VFS to just a query parameter.
FossilOrigin-Name:
ffceacf61905dc3553978ba5f68e133947eca2fa
mistachkin [Tue, 22 Apr 2014 19:34:16 +0000 (19:34 +0000)]
Add some OSTRACE calls for consistency.
FossilOrigin-Name:
be292d559748a24ff012266a1f58ce6c027e0411
drh [Tue, 22 Apr 2014 19:30:00 +0000 (19:30 +0000)]
Add the win32-none VFS which omits rollback-journal locking.
FossilOrigin-Name:
03e3c5a8b17a219a49bfbe79b7debd27ace8ad85
drh [Mon, 21 Apr 2014 18:13:37 +0000 (18:13 +0000)]
Fix the generation of sqlite3_rtree_query_info.iRowid and add test cases
to verify that it is fixed.
FossilOrigin-Name:
eba95ead49f8f8ce45d400186562ff0066537c5c
mistachkin [Mon, 21 Apr 2014 18:00:11 +0000 (18:00 +0000)]
Preliminary changes to support building VSIX packages for Windows 8.0 and Windows Phone 8.0 using Visual Studio 2013.
FossilOrigin-Name:
3bf97c811a25babf760f256245c756ed6710f8ba
drh [Mon, 21 Apr 2014 15:53:45 +0000 (15:53 +0000)]
Be sure to initialize the sqlite3_rtree_query_info.iRowid field for the
leaves of the R-Tree when doing a query callback search.
FossilOrigin-Name:
4394693882c04c19ebe87ef7547c57e679554397
drh [Mon, 21 Apr 2014 15:21:19 +0000 (15:21 +0000)]
Fix an off-by-one error in setting the "iLevel" field of the
sqlite3_rtree_query_info structure passed into the RTree query callback.
FossilOrigin-Name:
d708f159abfb3b87e2844463088d4fb7f8da9c97
drh [Mon, 21 Apr 2014 13:36:54 +0000 (13:36 +0000)]
Comment tweaks on the test case for the [
b75a9ca6b0 ] bug fix.
FossilOrigin-Name:
65d2544af9adc1e2f1d193e57f8be0422fb0d5eb
dan [Mon, 21 Apr 2014 13:21:56 +0000 (13:21 +0000)]
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
drh [Fri, 18 Apr 2014 22:20:31 +0000 (22:20 +0000)]
Clean up the proper-subset cost adjustment logic to make it more compact
and easier to read and so that full branch test coverage is more easily
obtained.
FossilOrigin-Name:
9a5d38c79d2482a23bcfbc3ff35ca4fa269c768d
drh [Fri, 18 Apr 2014 13:57:39 +0000 (13:57 +0000)]
Add to speedtest1.c the --threads option for setting the
SQLITE_CONFIG_WORKER_THREADS configuration.
FossilOrigin-Name:
5fce40c44aacf883df2e8e9472c399a6e92197b3
drh [Fri, 18 Apr 2014 13:40:07 +0000 (13:40 +0000)]
Fix harmless compiler warnings.
FossilOrigin-Name:
f8f72ecb9052a4cace1db75879fb8b5131ea4f50
drh [Fri, 18 Apr 2014 12:38:54 +0000 (12:38 +0000)]
Merge recent trunk changes into the threads branch.
FossilOrigin-Name:
8729aa3e3ed1da2e15408ef8705cbe185cd2a5ac
drh [Fri, 18 Apr 2014 01:37:08 +0000 (01:37 +0000)]
Further improvements to the RTREE_DECODE_COORD() method, to take advantage
of known processor byte orders when available. This makes the code 3% faster,
according to valgrind. Also add test cases to make sure the on-disk
representation is correct.
FossilOrigin-Name:
6f3e94f4b1b403cd7bfc5e8e0ffbd61b5174d3a4
drh [Fri, 18 Apr 2014 01:14:46 +0000 (01:14 +0000)]
Merge the latest changes from sessions.
FossilOrigin-Name:
d9eef5b03c7c4bb69c11eda41152ee81aed1cac7
drh [Fri, 18 Apr 2014 01:10:05 +0000 (01:10 +0000)]
Merge recent trunk changes into sessions.
FossilOrigin-Name:
95e77efe076ab421bd246119c47dba5dacf9d087
drh [Fri, 18 Apr 2014 00:49:29 +0000 (00:49 +0000)]
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
mistachkin [Fri, 18 Apr 2014 00:08:13 +0000 (00:08 +0000)]
Preliminary changes to support building VSIX packages for Windows Phone 8.1.
FossilOrigin-Name:
a1b2f28ba85b043df68875f5d3446140db4f2cb0
drh [Fri, 18 Apr 2014 00:06:02 +0000 (00:06 +0000)]
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
drh [Thu, 17 Apr 2014 23:23:29 +0000 (23:23 +0000)]
Performance optimization on byte-swapping in R-Tree.
FossilOrigin-Name:
444084fd620fc3f45cfb87b83f532d76bd2744e7
drh [Thu, 17 Apr 2014 15:34:58 +0000 (15:34 +0000)]
More test cases with very long priority queues.
FossilOrigin-Name:
71692aa97c78676f0ba80eaeec0ad9ac225f4427
drh [Thu, 17 Apr 2014 14:52:20 +0000 (14:52 +0000)]
Test cases and bug fixes for the sqlite3_rtree_query_callback()
mechanism.
FossilOrigin-Name:
1ccaaed6b516ec2ce953c1b31025a82ba76d00e7
drh [Thu, 17 Apr 2014 13:15:33 +0000 (13:15 +0000)]
Refactor the constraint checking logic in RTree. The new-style constraint
callbacks created by sqlite3_rtree_query_callback() are now hooked up from
end to end, though still untested.
FossilOrigin-Name:
32a13870175a1dd1d33af3572dde09ff607a04b6
dan [Thu, 17 Apr 2014 08:57:17 +0000 (08:57 +0000)]
Fix build problems in vdbesort.c. Add further comments and changes to make things easier to understand.
FossilOrigin-Name:
12b190db1d20c34390c768614b40ff58a9d3b74c
drh [Wed, 16 Apr 2014 21:02:28 +0000 (21:02 +0000)]
Performance optimization on nodeGetCell() in R-Tree.
FossilOrigin-Name:
5d20ff9ec837ad35bc44d6c25d13764b350e81dd
dan [Wed, 16 Apr 2014 19:04:23 +0000 (19:04 +0000)]
Clarify the purpose of the nField argument passed to sqlite3VdbeSorterInit().
FossilOrigin-Name:
c0c8cff17b7311bbc4fd081313a5552f927c3833
dan [Wed, 16 Apr 2014 17:41:22 +0000 (17:41 +0000)]
Change the name of vdbeIncrInit2 to vdbePmaReaderIncrInit. Add a header comment to the same function.
FossilOrigin-Name:
6622d87675c1d7992b1e6d52ae7da1007a1568a4
drh [Wed, 16 Apr 2014 17:23:23 +0000 (17:23 +0000)]
Convert the RTree module query mechanism over to using a priority queue for
walking the RTree.
FossilOrigin-Name:
f26936f71a16ab25590540f7feb273514dfb69ff
drh [Wed, 16 Apr 2014 17:15:14 +0000 (17:15 +0000)]
TCL tests now all pass.
FossilOrigin-Name:
f864baccd3fe0ee939ac1ec20069792f649cddc0
dan [Wed, 16 Apr 2014 16:43:05 +0000 (16:43 +0000)]
Rework the way trees of MergeEngine objects are built in vdbesort.c to make it easier to follow. Fix memory leaks that could follow an OOM or IO error. Add various comments to explain functions in vdbesort.c.
FossilOrigin-Name:
69026ec7dc3bd3e33bbe17c221a53cf1dd0f8945
drh [Wed, 16 Apr 2014 14:45:11 +0000 (14:45 +0000)]
Fix a bug in rowid=? query handling. More problems remain.
FossilOrigin-Name:
5b0e6ba4a5050cf81cf41b977b28d714163569e0
drh [Wed, 16 Apr 2014 13:00:08 +0000 (13:00 +0000)]
Bug fixes to the priority-queue implementation for R-Trees. Improved tracing
capability. Some queries work now, but still many problems.
FossilOrigin-Name:
a439ddd629c6bb5ea2e7e274673fee4f5c207acf
drh [Tue, 15 Apr 2014 21:06:14 +0000 (21:06 +0000)]
Initial attempt at getting R-Tree queries to work using a priority queue.
This check-in compiles, but R-Trees do not work well. And there are
debugging printf()s left in the code. This is an incremental check-in.
FossilOrigin-Name:
53688a25c23c394278a357829793889970aa4157
dan [Tue, 15 Apr 2014 20:52:27 +0000 (20:52 +0000)]
Fix some problems to do with OOM conditions in vdbesort.c. Some problems remain.
FossilOrigin-Name:
2f94f9ce9bf11f1599bbc640b3fc8c15da588416
dan [Tue, 15 Apr 2014 19:52:34 +0000 (19:52 +0000)]
Fix further code and documentation issues in vdbesort.c.
FossilOrigin-Name:
d03f5b8622d304f029f73c7cd0bee3182a81d081
drh [Mon, 14 Apr 2014 19:48:25 +0000 (19:48 +0000)]
Make sure the undocumented sqlite_rename_parent() function does not
crash even if it is invoked with NULL arguments.
Ticket [
264b970c4379fd4b94 ]
FossilOrigin-Name:
c6fa8d0d82805be230f672eabccdfa5680d4ddfd
dan [Mon, 14 Apr 2014 19:23:18 +0000 (19:23 +0000)]
Allow the sorter to begin returning data to the VDBE as soon as it is available, instead of waiting until all keys have been sorted.
FossilOrigin-Name:
cb0ab20c48962cdee03115efa93d7d501780ac73
dan [Mon, 14 Apr 2014 18:41:21 +0000 (18:41 +0000)]
Improve performance in single-threaded mode by having the final merge pass keys directly to the VDBE, instead of going via a final PMA.
FossilOrigin-Name:
02610cd9b77caa2c181210056088beb3ad6ce30f
drh [Mon, 14 Apr 2014 14:43:09 +0000 (14:43 +0000)]
Fix comments on the rtreenode() and rtreedepth() test function in the R-Tree
module.
FossilOrigin-Name:
ade5b986e8baab9df7bdaf7ccfaee2d6ba55fa3c
drh [Mon, 14 Apr 2014 12:18:17 +0000 (12:18 +0000)]
Remove over 300 lines of unused code, code that implemented the older
Guttman insertion algorithms that are no longer used.
FossilOrigin-Name:
3ba5f295c709faebf5505e61f6dc5266b811b086
dan [Mon, 14 Apr 2014 08:45:32 +0000 (08:45 +0000)]
Minor fixes so that builds with SQLITE_MAX_WORKER_THREADS=0 work.
FossilOrigin-Name:
e400bbbf26cdfe88f6cb231e96cdcddb9a6bcc0f
dan [Mon, 14 Apr 2014 07:30:39 +0000 (07:30 +0000)]
Improve use of multiple threads in sqlite3VdbeSorterRewind().
FossilOrigin-Name:
e1bdc4b810907cc0e55e0c923c8ebc777068cfe0
drh [Sun, 13 Apr 2014 19:28:15 +0000 (19:28 +0000)]
Remove the unused second argument from sqlite3ExprCachePop(). Add an
ALWAYS() on an always-true conditional in sqlite3VdbeResolveLabel().
FossilOrigin-Name:
ab23abf392175d3e256ff619b13abbbe732a49ed
drh [Sun, 13 Apr 2014 19:15:49 +0000 (19:15 +0000)]
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
drh [Sun, 13 Apr 2014 16:10:09 +0000 (16:10 +0000)]
Continuing work on the new custom query mechanism for r-tree.
FossilOrigin-Name:
ca7357e66ca60f59477b1db000c2cdaeb8082ae1
dan [Sat, 12 Apr 2014 19:34:44 +0000 (19:34 +0000)]
Fix many issues with new code.
FossilOrigin-Name:
62c406a042d7246f6df6b943421182a88483b2e3
drh [Sat, 12 Apr 2014 17:44:00 +0000 (17:44 +0000)]
Continuing clean-up of the R-Tree module in preparation for cutting in the
new generalized query mechanism.
FossilOrigin-Name:
66c858f20586424e15d0bfa3d7b56643bde66226
drh [Fri, 11 Apr 2014 23:14:48 +0000 (23:14 +0000)]
Add the new interfaces to rtree, though they do not yet work. Add the
"show_speedtest1_rtree.tcl" script for showing the test data used for the
R-Tree tests of speedtest1. Change speedtest1 to generate better R-Tree
test data.
FossilOrigin-Name:
0b70275972c7a6a533566c1e50bffbf3ac531e95
dan [Fri, 11 Apr 2014 19:43:07 +0000 (19:43 +0000)]
Avoid having the sorter merge too many PMAs at a time when incrementally merging data following a SorterRewind().
FossilOrigin-Name:
98bf0307b121b0776a7170108cc8d3f948a7ebfe
drh [Fri, 11 Apr 2014 17:41:08 +0000 (17:41 +0000)]
Add the --verify option to speedtest1. Add verification test cases to
the "rtree" testset and a case that uses a custom geometry callback.
FossilOrigin-Name:
9d485c4207a81f32334857d4a608c5c511dd2b83
drh [Fri, 11 Apr 2014 16:14:54 +0000 (16:14 +0000)]
Update comments in the R-Tree module in preparation for some big changes.
Add an "rtree" performance test to speedtest1.
FossilOrigin-Name:
20a73ec0b2f56609a4504052e198e32803d30207
drh [Thu, 10 Apr 2014 02:24:48 +0000 (02:24 +0000)]
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
dan [Wed, 9 Apr 2014 20:04:17 +0000 (20:04 +0000)]
Experimental multi-threaded sorting changes to allow the sorter to begin returning items to the VDBE before all data is sorted.
FossilOrigin-Name:
f9d5e09afaf64d68a0e461c1c2f38179bcea4b1f
drh [Fri, 4 Apr 2014 22:44:59 +0000 (22:44 +0000)]
Fix harmless compiler warnings.
FossilOrigin-Name:
e54dded2012f0ab486ee138e9bd57c528af33980
mistachkin [Fri, 4 Apr 2014 21:40:38 +0000 (21:40 +0000)]
Fix typo in a Windows threading support routine.
FossilOrigin-Name:
5e3dfa27c71a666e122e3cf64897038ff8424800
drh [Fri, 4 Apr 2014 18:49:19 +0000 (18:49 +0000)]
Performance improvements when reading large blobs, especially if
SQLITE_DIRECT_OVERFLOW_READ is defined.
FossilOrigin-Name:
2312eb6a9eb31051db4e0baf19e033ba39adc7b1
drh [Fri, 4 Apr 2014 18:37:36 +0000 (18:37 +0000)]
Merge the latest trunk changes into the threads branch.
FossilOrigin-Name:
39ac79cffe716f88af0871bdd206231b6a6511ff
drh [Fri, 4 Apr 2014 18:20:35 +0000 (18:20 +0000)]
Merge changes to the query planner that strive to ensure that any index
usage that is a proper subset of some other index usage always has a slightly
higher cost.
FossilOrigin-Name:
683dd379a293b2f330e1e4cd746f190527fe48ee
drh [Fri, 4 Apr 2014 14:12:52 +0000 (14:12 +0000)]
Ensure the "PRAGMA journal_mode=WAL" works coming from any other journal_mode
with ATTACH-ed databases.
FossilOrigin-Name:
e54330b43127e46fc6494748cbb353a6fc91cfd7
dan [Fri, 4 Apr 2014 07:52:44 +0000 (07:52 +0000)]
Add test file sort3.test, which should have been part of commit [
9d3351b8d7 ].
FossilOrigin-Name:
dceed2c803fca23c83c02c448d5ae7c4698efee1
drh [Fri, 4 Apr 2014 02:13:26 +0000 (02:13 +0000)]
Change vdbeSorterExtendFile() so that it makes a best effort to create the
PMA file of the desired size, but does not return an error if unable.
FossilOrigin-Name:
217814bc4b53fab7bdad433e24e8aef8998c38fe
drh [Thu, 3 Apr 2014 16:42:21 +0000 (16:42 +0000)]
Merge all recent changes from trunk.
FossilOrigin-Name:
a0910079adde95245680dee59b43613b60903f10
drh [Thu, 3 Apr 2014 16:35:33 +0000 (16:35 +0000)]
Merge all recent changes from trunk,
including the fix for the OP_SCopy-vs-OP_Copy problem.
FossilOrigin-Name:
9515c8344a6743bbb0c6a6e49fb79fb3139090df
drh [Thu, 3 Apr 2014 16:29:31 +0000 (16:29 +0000)]
Use OP_Copy instead of OP_SCopy when moving results out of a subquery,
to prevent the subquery results from changing out from under the outer
query. Fix for ticket [
1e64dd782a126f48d78 ].
FossilOrigin-Name:
d5513dfa23baa0b0a095aaf17d19aacd30dcef61
dan [Thu, 3 Apr 2014 16:25:29 +0000 (16:25 +0000)]
Fix an integer overflow problem in the sorter.
FossilOrigin-Name:
9d3351b8d713232133dad149c73fb2a27c72abb1
drh [Thu, 3 Apr 2014 14:31:00 +0000 (14:31 +0000)]
Fix a typo in the "Synopsis:" comment for the OP_VFilter opcode.
FossilOrigin-Name:
48ecdd4aff03741f96c070dced69c3c273b652cb
dan [Thu, 3 Apr 2014 14:29:08 +0000 (14:29 +0000)]
Fix minor errors causing compilation to fail with SQLITE_MAX_WORKER_THREADS set to a value greater than zero.
FossilOrigin-Name:
0561272abf357a2f4709f6c02866e570d19cd344
drh [Thu, 3 Apr 2014 02:54:27 +0000 (02:54 +0000)]
Refactor local object and method names in vdbesort.c so that their names
more closely reflect their actual use.
FossilOrigin-Name:
d284e30eb1db144965fa85566e4234e30464350b
drh [Thu, 3 Apr 2014 00:32:13 +0000 (00:32 +0000)]
In the command-line shell, run set writable_schema before running the
".clone" command.
FossilOrigin-Name:
9d2ae6342c8afa904bec591ebe134ff7f536b71c
drh [Wed, 2 Apr 2014 18:58:49 +0000 (18:58 +0000)]
Add a big introductory comment to vdbesort.c explaining its operation at a
high level. Also adjust some symbolic names and fix other comment issues in
that file.
FossilOrigin-Name:
eef60f1bf54fcdc7b32f96ebb87a9a0bf0776e8b
dan [Wed, 2 Apr 2014 15:15:25 +0000 (15:15 +0000)]
Fix some problems with OOM handling in vdbesort.c.
FossilOrigin-Name:
47e702bd8392bc50c4edaf6a2c8c499af87b520e
drh [Wed, 2 Apr 2014 14:38:14 +0000 (14:38 +0000)]
Change the name of the SorterThread object to "SortSubtask" to avoid confusion
with the SQLiteThread object.
FossilOrigin-Name:
4ee2d910fbbed8d4def15e4e99ee225839f3a739
dan [Tue, 1 Apr 2014 18:41:51 +0000 (18:41 +0000)]
When sorting data for a CREATE INDEX statement in single-threaded mode, assume that keys are delivered to the sorter in primary key order. Also fix various comments that had fallen out of date.
FossilOrigin-Name:
821d1ac4504243fa13b9e3c0d56361ad9fb80d78
dan [Tue, 1 Apr 2014 15:38:44 +0000 (15:38 +0000)]
Even if compile time option SQLITE_MAX_WORKER_THREADS is set to one or greater, set the default number of worker threads to zero. Distribute data more evenly between threads in sqlite3VdbeSorterWrite() to improve performance when sorting large amounts of data. Add new test file sort2.test.
FossilOrigin-Name:
643c86a056168e39fcb7f39b8a72731f1eb246db
dan [Tue, 1 Apr 2014 10:19:02 +0000 (10:19 +0000)]
Fix a problem with OOM handling in the sorter code.
FossilOrigin-Name:
59cd5229e2b5be5272cf57c7e7d09e97d16a5425