Commit Graph

16784 Commits

Author SHA1 Message Date
mistachkin 8705f868e0 Add the SQLITE_FCNTL_WIN32_GET_HANDLE file control.
FossilOrigin-Name: 16039be3739b8d3b34a1e6093eaebb09e07f984b
2016-10-14 21:27:50 +00:00
drh 9e31fe02ba Bump the version number in anticipation of the next development cycle.
FossilOrigin-Name: aa6de9c40ba2d906772b9032fd5d798661f6d4cc
2016-10-14 21:16:27 +00:00
drh 813646c182 Version 3.15.0
FossilOrigin-Name: 707875582fcba352b4906a595ad89198d84711d8
2016-10-14 10:20:30 +00:00
drh 989412a1cf Take care to avoid integer overflow when doing the initial page cache
allocation with an excessively large cache_size setting.

FossilOrigin-Name: 4d66ac98deaa85218be7ff0eb254f78b96d8e8d4
2016-10-13 12:56:18 +00:00
drh c436a03d02 Avoid reading the -1-th element of an array in the query planner. Fix to a
bug introduced by check-in [8e2b25f9b8a7] from earlier today.  Curiously,
the problem only appeared on 32-bit systems.

FossilOrigin-Name: 443913d582bcd953d85159047541592e2f68ade3
2016-10-12 18:55:53 +00:00
drh 432697467f Add to sqlite3_analyzer command-line options --version and --tclsh, and also
the undocumented --debug option.

FossilOrigin-Name: e87d02d289a2016ea3ee074e914b07a8ac22b21f
2016-10-12 18:26:26 +00:00
drh 013ae68b25 New testcase() macros to ensure coverage of the ORDER BY LIMIT optimization
code in where.c.

FossilOrigin-Name: 61f0526978af667781c57bcc87510e4524efd0d8
2016-10-12 15:15:30 +00:00
dan 83465a662f Fix a problem affecting queries that match the pattern (... WHERE ipk IN (....) ORDER BY ? LIMIT ?). Fix for [96c1454c].
FossilOrigin-Name: 8e2b25f9b8a7ed087d3cece74239814bee19429e
2016-10-12 14:48:00 +00:00
dan ef74652ceb Remove a stray line from session4.test causing a memory leak. No changes to SQLite code.
FossilOrigin-Name: 6624c4964b63e259d5ee006eaa7ec79ddadbd6a6
2016-10-10 14:48:36 +00:00
dan 90b2fe6b1e When handling ORDER BY expressions, do not assume all values of an indexed expressions are distinct. Fix for [4766f444].
FossilOrigin-Name: aebe429e52ffef026cb0803fb164339d61bd2e88
2016-10-10 14:34:00 +00:00
drh 48590fcb37 Make sure indexes on expressions skip over initial NULL values in the
index.  Fix for ticket [4baa464912129477f3c9]

FossilOrigin-Name: 71797ba431085f9ae381ed5ea6471967926f4043
2016-10-10 13:29:15 +00:00
dan ea5e5f0b89 Fix a case in which the rtree module was ignoring an OOM while generating an error message.
FossilOrigin-Name: 788f86bebe413b5a0ab41ba3d75ba8728827a964
2016-10-10 10:06:59 +00:00
dan e5ec01c481 Update test/trace3.test to account for the fact that casting a pointer to a 64-bit signed integer might produce a negative value.
FossilOrigin-Name: 010ec22541a4c37f2d3b01b6a531b4b4264102b7
2016-10-08 16:10:29 +00:00
drh dfe4e6bb33 Corrections to Lemon documentation. No SQLite changes.
FossilOrigin-Name: c568ae3eef31b49e846fad90e705914e2868a09c
2016-10-08 13:34:08 +00:00
dan 320d4c304d Add missing "static" to internal function whereRangeVectorLen().
FossilOrigin-Name: cbed3d75cf9a24037263d126727db7dd048a4f97
2016-10-08 11:55:12 +00:00
dan e288992e19 Updates to the tool/warnings.sh script to make it easier to use on OpenBSD.
FossilOrigin-Name: dbe2997f57f8d8f95e4b767bf73b8df3a5e4f783
2016-10-08 09:21:34 +00:00
dan 642f0146d7 Fix some compiler warnings in fts5.
FossilOrigin-Name: b066637bb75959267fe6104da323c5112ad78f82
2016-10-05 20:14:29 +00:00
drh e3c6b61cee Fix harmless compiler warnings.
FossilOrigin-Name: 2dde3375124198560c8ff15f87aadde2afd722c5
2016-10-05 20:10:32 +00:00
dan 4e59344a4c Add a test case for the fix in [a596b7c6cc].
FossilOrigin-Name: b2ef39b11f7c46e69e53439680c32adbb18903bd
2016-10-05 15:04:35 +00:00
drh da5c62400f Do not set MEM_Blob unless the appropriate fields of the Mem object have
been correctly initialized.

FossilOrigin-Name: a596b7c6cc780525120604090493f3f7d962b9fa
2016-10-05 15:02:00 +00:00
drh e0251d44fa Fix the backup_malloc.test script so that it works on Windows.
FossilOrigin-Name: d080012daaaa399663a0f767c792a2fff3e1037a
2016-10-05 01:33:57 +00:00
drh 4eda15e715 Fix a problem with the lempar.c parser template.
FossilOrigin-Name: 3a9d802fda10585654332b314d317250dc5d894e
2016-10-04 12:20:12 +00:00
drh 44728d7e01 Do not bother to initialize unused fields in the BtreePayload object.
FossilOrigin-Name: b10d0f939c82c4de3faa90b86de9ec4a89992856
2016-10-04 00:47:26 +00:00
drh a71c743aae Allow deterministic functions in the WHERE clause of a partial index.
FossilOrigin-Name: c6e9b9421805c904b20900b711fa0e51773aef3e
2016-10-03 18:13:23 +00:00
drh c9b39288ae Size and performance optimizations on the sqlite3ExprAssignVarNumber() routine.
FossilOrigin-Name: 109852e51e2cc2674940ba3e5097a92e66f88bb8
2016-10-03 16:33:14 +00:00
drh de25a88c50 Avoid unnecessary strlen() calls in sqlite3ExprAssignVarNumber() by passing in
the token length from the parser.

FossilOrigin-Name: d15ae2e530cffea60263f203ac5f89b6790f4bd5
2016-10-03 15:28:24 +00:00
drh 87c05f0c58 Avoid unnecessary memset() calls in the query optimizer.
FossilOrigin-Name: 5bb7cde0731d23411e9df02a957010f94203397b
2016-10-03 14:44:47 +00:00
drh cca8a4ad6f Fix an obsolete comment on a variable definition in expr.c. No code changes.
FossilOrigin-Name: 012ff6dd306328f7ea71a6600471c871e7ffe37b
2016-10-03 12:56:48 +00:00
drh 1dd518cfcd Make sure the sqlite_sequence table is updated when an optional xfer
optimization is used.  Fix for ticket [7b3328086a5c1].

FossilOrigin-Name: 81e4d4f897553f6fee540a38c3e83ceac5ba9b78
2016-10-03 02:59:33 +00:00
drh cb43a937e5 Allocate Parse objects off of the stack where appropriate for a substantial
performance increase and a size reduction.

FossilOrigin-Name: ea8affa9e453b201b479162f621b591e7a65a489
2016-10-03 01:21:51 +00:00
drh 1a7df58c1a Add SQLITE_USE_ALLOCA to the --lean configuration in speed-check.sh.
FossilOrigin-Name: fe07609efc31c4639c40fbda501c55f443756ad2
2016-10-01 23:55:23 +00:00
drh 445f3d564c Rearrange fields in the Parse object to reduce the amount of initialization
required.

FossilOrigin-Name: 361940b44dd17bf2b39fc0e0716c0de6b2b7f4f7
2016-10-01 21:43:37 +00:00
drh 216b70ff82 Reduce the width of a memset() to avoid double-initializing some variables.
FossilOrigin-Name: 34edbfd12d6cfa6bbfa30eef9276a4865eadc869
2016-10-01 20:43:41 +00:00
drh 230368c30d Remove an unnecessary memset() call.
FossilOrigin-Name: a76bff74ce47c9c98106566bde5d781992657e22
2016-10-01 19:32:54 +00:00
drh d8e4b13256 Use sqlite3DbMallocRawNN() where appropriate, instead of
sqlite3DbMallocRaw().

FossilOrigin-Name: 54a449a41d8d32da2f8b73689227ced866974a18
2016-10-01 19:21:56 +00:00
drh 8dfef1175e Make sure deleting an unused prepared statement does not reference
uninitialized fields in the structure.

FossilOrigin-Name: 7983eef0422439bfc85950554b000d46a9767ee3
2016-10-01 16:53:45 +00:00
drh 76336d5b9d Avoid accessing Vdbe.pc if it is uninitialized. Check Vdbe.magic first.
FossilOrigin-Name: 6ac6e4462a08cb2f3d28e4a23218fc1b110a2148
2016-10-01 11:39:53 +00:00
drh ab3182f7c4 Avoid unnecessary zeroing of fields in the Vdbe object when it is allocated.
FossilOrigin-Name: 1e21bbe836539e64d24857f4faa3d12cd607dc7e
2016-10-01 00:37:50 +00:00
drh cd9af608e1 Avoid initializing the column-cache section of the Parse object, since entries
in the cache will be initialized as they are used, and avoiding the initial
memset() saves many CPU cycles.

FossilOrigin-Name: 63cf7eafae5c3c1379edf416c5157010c7c120b5
2016-09-30 22:24:29 +00:00
drh 94881d732b Fix an always-true conditional left over from the previous commit.
FossilOrigin-Name: ab12fce3318db447995e1465f34a1e43cd623d6a
2016-09-30 21:20:37 +00:00
drh 9b40d13f43 Fix the Parse.aColCache column cache so that all of the valid entries are
in the first Parse.nColCache slots.

FossilOrigin-Name: 6028502059ccbd3699637b7a70a6d8ce1b7c3dad
2016-09-30 20:22:27 +00:00
drh e05950d878 Another simplification to the Parse object.
FossilOrigin-Name: c1419727f5e4cb3ef63b5853b6ef3b1e53af0651
2016-09-30 19:14:32 +00:00
drh 1d96cc60d0 Remove unnecessary fields from the Parse object.
FossilOrigin-Name: 814e41da3563eecf5514811bc8ab2df4f5cc0d4b
2016-09-30 18:35:36 +00:00
drh 2a1df937ab Avoid unnecessary Mem initializations when generating a new sqlite3_stmt
object.

FossilOrigin-Name: 47ae1cda8dc255d100aeb8cb90ea4c9e449509be
2016-09-30 17:46:44 +00:00
drh dd3bfe8648 Small size and performance optimization to sqlite3VdbeChangeP5().
FossilOrigin-Name: 3c93c8f5bbf54ed2a331079b28fdd94eb0e59e69
2016-09-29 20:28:34 +00:00
drh 2831c4d123 Remove the peep-hole optimization of removing OP_Close opcodes that come
before OP_Halt, as the extra work of removing those opcodes uses more cycles
than just running them.

FossilOrigin-Name: 984a96d79656c1b095aba1f88aca4bb787ba0bd8
2016-09-29 19:50:02 +00:00
drh 42735c7d30 Size and performance optimization to sqlite3ValueFromExpr()
FossilOrigin-Name: 945f82bc44c5a431c0fef0d36cf016671d7ade1e
2016-09-29 19:27:16 +00:00
drh 22fa36dc04 Clarification and typo-fixes in comments. No changes to code.
FossilOrigin-Name: e2cd79aa3104c51035bf29c548c322564731b75f
2016-09-29 15:53:28 +00:00
drh 5f33eaa6a4 Use Knuth multiplicative hashing for the symbol table.
FossilOrigin-Name: cc29ddd6be60bdbf107f285c9eb57d5896ebca2d
2016-09-28 20:42:31 +00:00
drh 5e769a50ad Two more typo fixes in comments.
FossilOrigin-Name: 40c0fb0af678797c39a99853f9f4102464c16f4b
2016-09-28 16:05:53 +00:00