Commit Graph

9565 Commits

Author SHA1 Message Date
dan
5134d1357e Instead of a temporary b-tree, use a linked-list and merge-sort to sort records in main memory in vdbesort.c.
FossilOrigin-Name: 7769fb988d9be0f2d8129aaac19620ac88f9b4a6
2011-09-02 10:31:11 +00:00
drh
1c9d835d49 Use OP_SorterOpen instead of OP_OpenEphemeral to implement GROUP BY.
FossilOrigin-Name: ebf819aaa555bd79fddfc0a6f9827a2539095d6c
2011-09-01 16:01:27 +00:00
drh
c6aff30ca4 Experimental code-generator changes to utilize new opcodes for sorting.
FossilOrigin-Name: bab2e560f6cb989c83a96aad60f666960ede7abe
2011-09-01 15:32:47 +00:00
drh
96862072b8 Avoid using uninitialized variables after failures in the merge sort code.
FossilOrigin-Name: 2869ed28299b1c9f355ecc24635830f7f1249126
2011-08-31 23:57:22 +00:00
drh
20f8e13b44 Formerly, we enabled fdatasync() on linux only. But now we learn that
fdatasync() is not supported on Android.  So we disable fdatasync() on
Linux too.  It can be reenabled at compile-time for those who really need it.

FossilOrigin-Name: 70b5b309568ac55565558d5456aca1e431cfd26b
2011-08-31 21:01:55 +00:00
drh
5a201fb41d Add the SQLITE_MAX_SCHEMA_RETRY compile-time option to the set of options
understood by "PRAGMA compile_options;" and by the 
"sqlite_compileoption_used()" function.

FossilOrigin-Name: 1b124af40a8fa4d3094f24a9213096b66411b8f9
2011-08-31 20:47:50 +00:00
drh
1b1e8a8be6 The server1.test script should only run if mutexes are functional.
Fix to the #ifdef change of check-in [9e6a4c1473].

FossilOrigin-Name: 6489848590db7088d965b7fa7feabc8c66e2e2b1
2011-08-31 19:40:58 +00:00
drh
fd53231c85 Always include the unixShm.id field, even when not debugging.
FossilOrigin-Name: 07803476206b8cde60ccc320b9ccdc0d48a41d65
2011-08-31 18:35:34 +00:00
drh
7730c4457e Only create the sqlite3OSTrace global variable if compiling with
SQLITE_TEST.

FossilOrigin-Name: 9e6a4c1473a4cb061a88f6a437a2828368b3ddc8
2011-08-31 18:04:54 +00:00
drh
4515a45b8c Backslash escaping is not working right in tostr.awk on the latest ubuntu.
The easiest fix is to simply not use any backslashes in the spaceanal.tcl
script.

FossilOrigin-Name: df550066657cb41bad34ac8e722b8148ab7eabfb
2011-08-31 17:46:50 +00:00
drh
e42a9b431b Add checks to make sure cells in corrupt database files
do not overflow a page when doing autovacuum.
Problem detected by valgrind.

FossilOrigin-Name: d0b347b412376d22e9f0770ac083dafb5e480dd0
2011-08-31 13:27:19 +00:00
drh
0ee469c9a8 Enable the thread test logic to work with the SQLITE_HAS_CODEC compile-time
option.

FossilOrigin-Name: 20ddfb4780b87953718f3a8e67b777dcff0e3b5e
2011-08-30 19:52:32 +00:00
drh
307ff30b54 Change the build process so that it does not require the unix "sort"
command.  This avoids confusion between ms-sort and mingw-sort on
windows systems.

FossilOrigin-Name: f1bd5bbae505068d24bfd9cc6bab6a8b8940bad6
2011-08-30 01:29:04 +00:00
mistachkin
d589a5444b Make sure SQLITE_FCNTL_SIZE_HINT a no-op if the chunk size is not greater than zero.
FossilOrigin-Name: 88b763e8d73fafa1538b08af28b1c8b723b39c61
2011-08-30 01:23:34 +00:00
drh
e0a59cf0e1 Fix a total unimportant file descriptor leak in lemon. This is to silence
warning messages.

FossilOrigin-Name: e95cf2c576dda656c0f31eeec3d98e911b9003a1
2011-08-30 00:58:58 +00:00
drh
bc2be0c770 Fix a buffer overrun in test logic. No impact on the core SQLite.
FossilOrigin-Name: 49cd60e38bd8df9d736ced95e0ace6efea95ca7d
2011-08-30 00:53:50 +00:00
dan
54bbe7f15e Fix a broken assert() statement in select.c.
FossilOrigin-Name: ad78ef2b3a20e3c3191fba232cbae70656210cf5
2011-08-29 18:24:27 +00:00
drh
2f7820d8b5 Back out [05c9832e5f6eb] since it was causing a performance regression with
no obvious benefit.

FossilOrigin-Name: 639cc85a911454bffdcccb33f2976c683953ae64
2011-08-29 11:56:14 +00:00
drh
d4b708f671 Merge performance enhancements into trunk.
FossilOrigin-Name: 5a00d24b279424d257781ec3f1227e72a5d56f57
2011-08-29 03:08:47 +00:00
drh
2d36eb43a4 About a 1% overall performance improvement by using a macro to avoid
no-op calls to sqlite3MemReleaseExternal().

FossilOrigin-Name: ff71d20a9ed129bd1785a3f7a777ce62098735b7
2011-08-29 02:49:41 +00:00
drh
5a077b741f Small performance improvement to OP_Column.
FossilOrigin-Name: b6b73a747ad8d0f026074e41c2a4adc529ec2674
2011-08-29 02:16:18 +00:00
drh
e6f43fc4f8 About a 3% improvement in the performance of OP_Column.
FossilOrigin-Name: edff9d4a995095e555fcc9aec4c56f4bcaa1557e
2011-08-28 02:15:34 +00:00
drh
4a6f3aabca Correctly display P4_ADVANCE values on opcode traces. Mark an always-taken
branch in OP_Column as such.

FossilOrigin-Name: 087dc96086fe4e45da93ab6a0d5dda34c932ce97
2011-08-28 00:19:26 +00:00
dan
a205a486d2 Experimental changes to improve the performance of OP_Next.
FossilOrigin-Name: 1a249845251199c00817893add300a1a654b4df9
2011-08-27 18:48:57 +00:00
drh
3d4435b234 Fix several harmless compiler warnings and a documentation bug.
FossilOrigin-Name: 5454d0fe227b7c1f0e7715b6c08f97019628fc4c
2011-08-26 20:55:50 +00:00
drh
009a5f811b Merge the stat3-enhancement branch with trunk, but keep the resulting merge
in a separate branch for now.

FossilOrigin-Name: 63f2c7859fa6e5d0e2cdd218ff52a3ec2d44c61d
2011-08-26 13:16:33 +00:00
mistachkin
25d054fabd Update compiler error message regarding the choice of memory allocator defines.
FossilOrigin-Name: 1dada5158215d1816edb69ff2610f9d2259ce19d
2011-08-26 11:25:02 +00:00
mistachkin
d2f496aab5 Merge Win32 native heap support into trunk.
FossilOrigin-Name: 5238a74987507f27af4080e2842f53e049b5b111
2011-08-26 11:18:44 +00:00
mistachkin
4d60be5e30 In the MSVC makefile, allow symbols to be enabled without NDEBUG defined. Also, for the win32lock test, make sure the database is closed prior to shutdown.
FossilOrigin-Name: 5ed7633d41b99929309a7e13d37375a4fdae43b3
2011-08-26 05:40:31 +00:00
mistachkin
7da32b5841 Disable checking the winMemData structure signature when compiled with NDEBUG.
FossilOrigin-Name: 50edc2f9141bd13277119afd129387029ebe5c01
2011-08-26 01:45:50 +00:00
mistachkin
155892cccc Allow the Win32 native heap flags to be overridden at compile-time.
FossilOrigin-Name: 1c2ecec8e7320bc5b532b3107005fb7f0370f25c
2011-08-26 01:32:24 +00:00
drh
2a5d9908f9 Create a new pager type, PAGER_SORTER, for use in the external merge sort.
Such pagers are always held in memory but do report when they are under
memory pressure by calling pagerStress.

FossilOrigin-Name: c71d73201d950355862dd8d5de142c9673888755
2011-08-26 00:34:45 +00:00
drh
c5dbffe741 Reorder some of the branches in backup.c in order to make the code
easier to test.

FossilOrigin-Name: 2c443d47ecee7b43a89f0a4bf299c46c66e3f80d
2011-08-25 20:18:47 +00:00
dan
4b2704021a Replace an assert() that a condition may not occur in backup.c with code to handle that condition, which can occur.
FossilOrigin-Name: 472c74b3452c5a07dfb006010441232b09599ad5
2011-08-25 19:28:47 +00:00
drh
860e332cdc Fix harmless compiler warnings in test code. No changes to the core.
FossilOrigin-Name: 16f83fec77668c021694fbb189b415bd3b90adc8
2011-08-25 18:54:46 +00:00
drh
d7f6e906db Disable external merge source when SQLITE_TEMP_STORE==3. Add documentation
to the OP_OpenSorter opcode.

FossilOrigin-Name: 5a690486811379cea40c6ed48b2902f421234832
2011-08-25 18:01:28 +00:00
dan
ee140c4d71 Fix the SQLITE_DISABLE_DIRSYNC compile time option.
FossilOrigin-Name: 6deb3ea1f080324ea23ebdc9008753fbbc4063e2
2011-08-25 13:46:32 +00:00
mistachkin
f2d25f2005 Add comments for the various debug levels. When debugging, disable optimizations. Prevent the win32lock tests from spinning forever.
FossilOrigin-Name: 401859236b0d97bde82b11f32efce6eb9d490941
2011-08-25 04:09:12 +00:00
drh
26541c9a00 Fix an file separator character issue with test_quota.c that was causing
it to fail on windows.

FossilOrigin-Name: ddb8d3e80df868bda0704feed31171fa055432b5
2011-08-25 03:38:31 +00:00
mistachkin
753c544495 In the MSVC makefile, support several levels of debugging, each one building on the previous. Also, add comment about the SQLITE_WIN32_MALLOC_VALIDATE macro.
FossilOrigin-Name: 4257e9b7ca78feb03df08fde56da947ae64c5c6f
2011-08-25 02:02:25 +00:00
drh
31e8097658 Cherrypick the [d4f6437f8d] change so that SQLITE_FCNTL_SIZE_HINT is always
honored and never undone by memory pressure on windows.

FossilOrigin-Name: 67ff8d27f6aa6e0beff1f6b72a997b30a9647879
2011-08-25 01:58:17 +00:00
drh
b6020c4eef Add the sqlite3_quota_file() interface to test_quota.c.
FossilOrigin-Name: 2b7fe8e5b74c3504edd0e3ff78096e357ee1b47c
2011-08-25 01:42:12 +00:00
mistachkin
4458bc8e3e Make sure that SQLITE_FCNTL_SIZE_HINT on Windows does not shrink the file.
FossilOrigin-Name: d4f6437f8de82482dfaa4c084f4221e89e21eb00
2011-08-25 01:16:42 +00:00
drh
e4cf0b3106 Add the SQLITE_EXTRA_INIT macro.
FossilOrigin-Name: a3220f36c164dd2edf085c07ea08d617d8438812
2011-08-25 00:14:41 +00:00
mistachkin
468690ef60 Add error logging to native Win32 heap support.
FossilOrigin-Name: 7fca5a284cded6d7531060da6e99a57aed50cf8f
2011-08-24 17:42:22 +00:00
mistachkin
1b186a9947 Experimental work to allow SQLite to use the native Win32 heap API.
FossilOrigin-Name: bf3d0ab53829350637283442f75071fe6d925245
2011-08-24 16:13:57 +00:00
drh
2d1017e47f Updates to the sqlite3_mem_methods documentation.
FossilOrigin-Name: 988998fe7b0a21ed113b67f812e51f357045bef4
2011-08-24 15:18:16 +00:00
drh
88caeac774 Fix some harmless compiler warnings.
FossilOrigin-Name: 46f5a68bfa4199a4bd398030bf88bfbb4df3d5ca
2011-08-24 15:12:08 +00:00
drh
796af156c7 Changes to test_quota.c to make quota groups persistent even after files
are closed.  Files remain a part of the quota group until they are
deleted.

FossilOrigin-Name: 04111ce980df9692b7fe65a36105e7de9627a3bb
2011-08-24 01:25:55 +00:00
drh
8115d5feaa Simplifications to the SQLITE_PAGECACHE_BLOCKALLOC logic. Reduce the number
of difficult-to-reach branches.

FossilOrigin-Name: d5d835fe8352cb2009133246d4ed1cd310803f75
2011-08-23 23:41:40 +00:00