aboutsummaryrefslogtreecommitdiff
path: root/src/vdbeaux.c
Commit message (Collapse)AuthorAge
...
* Merge latest trunk changes into this branch.dan2019-07-13
|\ | | | | FossilOrigin-Name: 86ab963cc5743867e0535b78a5776e18c13835aa44bf2009f77642df8407cb3f
| * Move the sqlite3VdbeSerialType() routine in-line in the OP_MakeRecord opcode.drh2019-07-11
| | | | | | | | | | | | | | Optimizing compilers were doing this already. By doing it manually, we can omit some redundant tests and make the whole thing run a million cycles faster and use about 80 bytes less code space. FossilOrigin-Name: d837ab0da52632699abc09320980606aef020df5020c253f99c97e24bf3c6d00
* | Minor performance improvement in vdbeRecordCompareString().dan2019-07-12
|/ | | FossilOrigin-Name: 777fec84a5db968e033883920586ec0afef65578be0c1eb3021fce525111edde
* Smaller and faster sqlite3IsNaN() implementation makes deserialization ofdrh2019-05-30
| | | | | floating point values much faster. FossilOrigin-Name: ea748edecb261f2b862d542daff6e99a6fd8879a8ace94b440d99e110577d1c1
* Fix a problem in [b5ca442a] causing an assert() to fail in REINDEX commands.dan2019-05-21
| | | FossilOrigin-Name: a3e77c7776ab01dadb9d30d6067ac97e9d4b09ec54834558a5fa1ffed7b52c72
* Use a statement journal for all CREATE INDEX statements in case an indexed ↵dan2019-05-21
| | | | | exprsesion throws an exception when it is evaluated. Fix for [b5ca442a]. FossilOrigin-Name: b8071d10cba8f6c19fb8d5df3877f72567dc6d6a94744a39cbc1f58b2e2f343b
* Disable the optimization where a REAL value with no fractional partdrh2019-05-09
| | | | | | | | is stored as an INTEGER when the integer uses as much space as the real value it proposes to stand in for (8 bytes). This avoids corner cases of comparing integers against real values that are beyond the resolution of an IEEE 754 double. Fix for ticket [6c1d3febc00b22d457c78c2] FossilOrigin-Name: 9b0915272f4d4052aa31e9297424a7db9a0234b676e8e2a44c3f2dc54236705a
* Do not commit an "OR FAIL" statement that causes foriegn key constraint ↵dan2019-05-07
| | | | | violations. FossilOrigin-Name: 659c551dcc374a0d349ba9419f692e3363839e11d791a17cc35fa1854a674a51
* New testcase macros to ensure that MEM_IntReal is fully tested.drh2019-05-04
| | | FossilOrigin-Name: 8b8ef445ccccc148af2cda5975986af0d134352fe16283f65d0f8a91c9ffa932
* Make MEM_IntReal a completely independent type, meaning a floating pointdrh2019-05-02
| | | | | | | | value stored as an integer. This fixes a problem with arithmetic within arguments to string functions on indexes of expressions. But it is a big change and needs lots of new testcase() macros for MC/DC and so it is initially put on this branch. FossilOrigin-Name: dba836e31cb29d339b4520acb06188a892a52e45c50aba9742966b01108e251a
* Fixes for harmless compiler warnings.drh2019-04-13
| | | FossilOrigin-Name: c28c973ad6debd63f13e5d4d3da036f680baaec9d863eda039f2747db9f1cfd5
* Enforce the SQLITE_LIMIT_COLUMN limit on virtual tables.drh2019-04-13
| | | FossilOrigin-Name: 0b6ae032c28e7fe34d81d1769f6e2901addbd1b95cd9a255dcef274061fb0164
* Ensure that ALTER TABLE commands open statement transactions. Fix for ↵dan2019-03-15
| | | | | [596d059a]. FossilOrigin-Name: 0f2129f59f7df929106e2af876c2976dea6528c1dc1850d64cddb256f20e121a
* Window functions that can abort should indicate this, so that if they aredrh2019-01-27
| | | | | used in DML statement, a statement journal will be used. FossilOrigin-Name: 0ea05a0eb96acb860d8af2e788e29a5ae3b161e7892ab62f1ff2f3e722c0dcb6
* Fix harmless compiler warnings.drh2019-01-25
| | | FossilOrigin-Name: 3ff220ad378d547538b4501e6b2201e835a2c66891e5e40856db377c101a50e5
* Change a integer variable in sqlite3VdbeRecordUnpack() to unsigned in orderdrh2019-01-24
| | | | | to avoid any possibility of an integer overflow. FossilOrigin-Name: 1b536f6fd8d58800042f130842f0586aaa357841ee0d1b690a9815c865d50826
* Ensure that a key comparison does not read a collating sequence past thedrh2019-01-22
| | | | | | end of the KeyInfo, even if the key field of an index is corrupted by having a string in the last column instead of the ROWID. FossilOrigin-Name: 058a8006dceda78a894ea9446f057aa60b6d38e96506d4d91bda0ee2f9314ba3
* When parsing a corrupt record using sqlite3VdbeRecordUnpack(), make suredrh2019-01-14
| | | | | | that the resulting UnpackedRecord object is completely initialized, to avoid (harmless) MSAN warnings. FossilOrigin-Name: ddc3697efd61830fad55c6bf7f9115f4a7f53e08838eba5a82e1406c7a721665
* Prevent unsigned 32-bit integer overflow from leading to a buffer overreaddrh2019-01-12
| | | | | | inside of an assert(). The problem fixed here is no reachable in production code. FossilOrigin-Name: 0f850a25d67a752fe1e9059c0c3f78e00c222113e556a7605fd3c50817b573cb
* Improved detection of cell corruption in sqlite3VdbeRecordCompareWithSkip().drh2019-01-11
| | | FossilOrigin-Name: fa47f4c6589c431cf678560ac33dea6b695052012bea2096b2c92869ed51c688
* Merge enhancements and bug fixes from trunk.drh2018-12-31
|\ | | | | FossilOrigin-Name: 9fb646f29c05bca5f677a2c7c4f45c36bfe0a0c6a88cb7968b4a0459bdd63bb2
| * Additional small performance increase and size reduction to thedrh2018-12-29
| | | | | | | | | | sqlite3VdbeMakeLabel() mechanism. FossilOrigin-Name: 1bdee199a71e0a6c247b85e72de9e3a3099b7179c33288735721facef3b96459
| * A new implementation of sqlite3VdbeMakeLabel() is faster and makes fewerdrh2018-12-29
| | | | | | | | | | | | | | | | | | memory allocations by deferring memory allocation until sqlite3VdbeResolveLabel() is called, at which point the code generator has a better idea of how big the relocation table needs to be. The sqlite3VdbeMakeLabel() routine now takes a Parse* parameter instead of Vdbe*. FossilOrigin-Name: 4a0929ac76d8aa5dd65eac3b83d6bbf41e505e01d175ca0fb2b19ba02d439415
* | Merge performance enhancements from trunk.drh2018-12-28
|\| | | | | FossilOrigin-Name: 0f1b9ff9e1e6f13e03045fcb7d0907227085054f9eb0b0b8471fb26b0094b13a
| * Faster allocation of new sqlite3_stmt objects.drh2018-12-28
| | | | | | FossilOrigin-Name: 891f1f72187f0f9ec0d24fda98cc08be3ae3c3ff8b27c4e409ee7135c3106398
| * Move the nOpAlloc field from Parse into Vdbe to avoid an extra pointerdrh2018-12-28
| | | | | | | | | | deference on the fast path in sqlite3VdbeAddOp3(). FossilOrigin-Name: 8f10efc29dea7b816b1ba401726c268950d6671d890f686911269082a241d8d9
* | Merge patches and enhancements from trunk.drh2018-12-28
|\| | | | | FossilOrigin-Name: da53f3d3ff26cc32d3a5ac788b6785baa3d1688e50d9354025a3130dc7e71a38
| * Fix a problem causing the sqlite_master entry corresponding to a virtual tabledan2018-12-28
| | | | | | | | | | | | to be removed by a DROP TABLE even if the call to the vtabs xDestroy() method failed. FossilOrigin-Name: 0140f6dbfbea93eadcd7f727d84064a0c0d1f0806dbe3e5ef1017da603157e3b
| * Always include OP_Explain opcodes in the bytecode when SQLITE_DEBUG is enabled.drh2018-12-24
| | | | | | FossilOrigin-Name: d8c1235c02b745138ac2b12e8bbb00dda4cac321176be92a2fa9547be029b3d0
* | Improvements to EXPLAIN QUERY PLAN formatting. The MULTI-INDEX OR now showsdrh2018-12-24
|/ | | | | | a separate "INDEX" subtree for each index. SCALAR SUBQUERY entries provide a subquery number that is related back to the .selecttrace output. FossilOrigin-Name: 7153552bac51295c56a1c42ca79d57195851e232509f9e9610375692f48c7e86
* Further refinements to the sqlite3_normalized_sql() interface. TH3 nowdrh2018-12-10
| | | | | gives 100% MC/DC on that interface. FossilOrigin-Name: c96bf6cca220e363b099455ce35195ce7e89d374a52dc787f56e7b11e587bced
* Refactor the sqlite3_normalized_sql() implementation. This is adrh2018-12-10
| | | | | work-in-progress. There are still issues. FossilOrigin-Name: a4c890b0af9786295e6df05022009d8946550adb873535c610be805c2b7a4083
* Fix the sqlite3_normalized_sql() interface so that it rendersdrh2018-12-07
| | | | | double-quoted string literals as "?". FossilOrigin-Name: 0d8e150434bbd179696f1ffe71d1e06cb3d43e6468496c7e481fca8486387bad
* When masking bits off of sqlite3.flags, make sure the mask is 64 bitsdrh2018-12-06
| | | | | in size so as not to accidentally mask of high-order bits. FossilOrigin-Name: 53d3b169d8e1892163526caff2c843302c92e280fdeff6831e23a9bb15b82be3
* Enhance the sqlite3_normalize_sql() interface so that it works even if thedrh2018-12-05
| | | | | | | | | prepared statement was not initially compiled using SQLITE_PREPARE_NORMALIZED. Enhance the ".trace" command in the CLI so that it is able to access the full scope of functionality provided by sqlite3_trace_v2() and in particular so that it is able to show normalized SQL output using the newly enhanced sqlite3_normalize_sql() interface. FossilOrigin-Name: 7da617e97eb905cb009c47403786682b911e32a630f266e1c53ea72836fc88b5
* Add the sqlite3_normalized_sql() API.mistachkin2018-10-29
| | | FossilOrigin-Name: 592b66e8058dd03a056a036e2606247c9efdb06d15eebe9bcc455f7f55e30ae6
* Fix a potential crash that can occur while reading an index from a corruptdrh2018-10-01
| | | | | | | database file. The corruption is a record-header-size that is larger than 0x7fffffff. Problem detected by OSSFuzz against GDAL and reported to us (with a suggested fix) by Even Rouault. The test case is in TH3. FossilOrigin-Name: 8ac2cdda68f92b0352bc7f0b4be5fca4bb58565ca65055fb34153cc284ed6922
* Fix a harmless compiler warning that arose from the ENABLE_CURSOR_HINTSdrh2018-09-12
| | | | | fix of check-in [0af18674ca5b34e67e] FossilOrigin-Name: f578e62ae6f6cc78d8281adab9fa93f3f58711879c2860bbe19f291d257dc0af
* Remove an old testcase() macro that is no longer valid.drh2018-09-05
| | | FossilOrigin-Name: e628713338f6e584a32d5fc3436ddbd9ee8cf88401c321c1ebe7daa1e695c623
* Also free up the MEM_RowSet bit in the Mem.flags field and have RowSet objectsdrh2018-08-29
| | | | | be destroyed using Mem.xDel. This change results in faster code. FossilOrigin-Name: f48e9feb3fca514e4e586932e6d19a5e34a384204effeba553006dcddf5f13d2
* Free up the MEM_Frame bit in Mem.flags object. Store VdbeFrame objectsdrh2018-08-29
| | | | | as MEM_Blob with a special Mem.xDel pointer instead. FossilOrigin-Name: 62db5fd47660bbc4fcf2c6d4a6c5a3077f12c6442a128d22b66b789a0409ef32
* Fix various harmless warnings generated by static analysis tools.drh2018-08-21
| | | FossilOrigin-Name: a04a0ea9e30e0ef12bafa0b90b7d1b7764865768bb4a738b0c73a7a3ef9416db
* Fix UPSERT so that it checks the target-constraint first and fires thedrh2018-08-14
| | | | | | | DO UPDATE if that constraint is violated regardless of whether or not other constraints are in violation. This aligns SQLite behavior with what PostgreSQL does. Fix for ticket [908f001483982c43cdb476dfb590a1a]. FossilOrigin-Name: 529fb55e3d00472f13446117527b0896827b11e870b581af7fe7cbb7392ef3cd
* Remove more column-cache residue: The OP_SetColTab and OP_VerifyColTabdrh2018-08-04
| | | | | opcodes and the associated SQLITE_DEBUG_COLUMNCACHE logic. FossilOrigin-Name: 80236e81cefdf3d3cda3dbdb6de1575c38e4e248cc4b72ca9ee96d3aa0464bfd
* Completely remove the column cache logic, which has been a persistent sourcedrh2018-08-03
| | | | | | | of bugs for many years. We recent enhancements to the performance of the OP_Column opcode, the removing the column cache actually makes speed-check.sh run faster. It also saves about 1,800 bytes of code space. FossilOrigin-Name: 3f5f60cd7529330209027fdae8129cca420cec1050eae50a7750d0b715b56972
* Do not abort running queries due to a CREATE INDEX statement. Allow themdrh2018-07-24
| | | | | | to run to completion before being reprepared. Fix for ticket [c694113e50321afdf9]. FossilOrigin-Name: 2bd593332da0aade467e7a4ee89e966aa6302f37540a2c5e23671f98a6cb599c
* Improvements to SCopy correctness tracking when SQLITE_DEBUG is enabled.drh2018-06-12
| | | FossilOrigin-Name: b2973f2357a2c5e22e0d612c970adbc6d51cbc5e4ff7ac6d2b678722e553e8ec
* Add the OP_SetTabCol and OP_VerifyTabCol opcodes, only when compiling withdrh2018-06-11
| | | | | SQLITE_DEBUG, to do run-time verification of the column cache. FossilOrigin-Name: b37614a3670770919a7c7f8157c5fd6578d736447998640b52e5cef8174cadc2
* Strengthen the sqlite3VdbeMemAboutToChange() run-time verification mechanismdrh2018-06-11
| | | | | to better detect missed calls to AboutToChange(). FossilOrigin-Name: 793e942205a12eedb7ecc5ad8a27e3e52bbd4e1d50a0d1453d04a83ba728884e
* Remove the NextIfOpen and PrevIfOpen opcodes which are no longer neededdrh2018-06-07
| | | | | when the IN-early-out optimization is working. FossilOrigin-Name: 439c8162272795b422a0e01b01b832fbc12b39914c9632a674162af8bdecff98