mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-18 10:21:03 +03:00
Prevent the WhereLoop.rSetup cost estimate from going negative on complex
queries. FossilOrigin-Name: f81050859170c8708a1b296da8dd3ef0dd314a11
This commit is contained in:
12
manifest
12
manifest
@@ -1,5 +1,5 @@
|
|||||||
C Fix\sthe\shandling\sof\sOP_Eq\sopcodes\sthat\scompare\sa\sregister\sagainst\sitself\nand\sthat\srequire\san\saffinity\schange.
|
C Prevent\sthe\sWhereLoop.rSetup\scost\sestimate\sfrom\sgoing\snegative\son\scomplex\nqueries.
|
||||||
D 2016-06-25T11:43:47.381
|
D 2016-06-26T04:06:28.081
|
||||||
F Makefile.in bc2b4864a23a4a21c3e26d7b4350f51bab324d45
|
F Makefile.in bc2b4864a23a4a21c3e26d7b4350f51bab324d45
|
||||||
F Makefile.linux-gcc 7bc79876b875010e8c8f9502eb935ca92aa3c434
|
F Makefile.linux-gcc 7bc79876b875010e8c8f9502eb935ca92aa3c434
|
||||||
F Makefile.msc 50149765ef72f4e652b9a0f1f6462c4784bb9423
|
F Makefile.msc 50149765ef72f4e652b9a0f1f6462c4784bb9423
|
||||||
@@ -462,7 +462,7 @@ F src/vxworks.h d2988f4e5a61a4dfe82c6524dd3d6e4f2ce3cdb9
|
|||||||
F src/wal.c 02eeecc265f6ffd0597378f5d8ae9070b62a406a
|
F src/wal.c 02eeecc265f6ffd0597378f5d8ae9070b62a406a
|
||||||
F src/wal.h 2f7c831cf3b071fa548bf2d5cac640846a7ff19c
|
F src/wal.h 2f7c831cf3b071fa548bf2d5cac640846a7ff19c
|
||||||
F src/walker.c 0f142b5bd3ed2041fc52d773880748b212e63354
|
F src/walker.c 0f142b5bd3ed2041fc52d773880748b212e63354
|
||||||
F src/where.c 0ce4793497af2feb051147a5cc6356f95d3ab381
|
F src/where.c 48eed8ebe319c6cbc7bf7682018f32af0f5189f5
|
||||||
F src/whereInt.h e5b939701a7ceffc5a3a8188a37f9746416ebcd0
|
F src/whereInt.h e5b939701a7ceffc5a3a8188a37f9746416ebcd0
|
||||||
F src/wherecode.c e20cb381ff621e56a4684c71e31999aca2547ca6
|
F src/wherecode.c e20cb381ff621e56a4684c71e31999aca2547ca6
|
||||||
F src/whereexpr.c c32d47085dbaca0b8fd013210f56693c7d220d48
|
F src/whereexpr.c c32d47085dbaca0b8fd013210f56693c7d220d48
|
||||||
@@ -1502,7 +1502,7 @@ F vsixtest/vsixtest.tcl 6a9a6ab600c25a91a7acc6293828957a386a8a93
|
|||||||
F vsixtest/vsixtest.vcxproj.data 2ed517e100c66dc455b492e1a33350c1b20fbcdc
|
F vsixtest/vsixtest.vcxproj.data 2ed517e100c66dc455b492e1a33350c1b20fbcdc
|
||||||
F vsixtest/vsixtest.vcxproj.filters 37e51ffedcdb064aad6ff33b6148725226cd608e
|
F vsixtest/vsixtest.vcxproj.filters 37e51ffedcdb064aad6ff33b6148725226cd608e
|
||||||
F vsixtest/vsixtest_TemporaryKey.pfx e5b1b036facdb453873e7084e1cae9102ccc67a0
|
F vsixtest/vsixtest_TemporaryKey.pfx e5b1b036facdb453873e7084e1cae9102ccc67a0
|
||||||
P 77e4f7a36e6e0ebe842bcb36b2557a5bfba90d3f
|
P 507014e4c7a70cd09410c89c8ed466c8edab39d2
|
||||||
R 3ef1ee60339b9a478f36c983b60b7e48
|
R ae55d782914cbf2db58c75f82f862316
|
||||||
U drh
|
U drh
|
||||||
Z 7d552df043719cedc46422a9795a23bd
|
Z e21bca843071316b56d3c29d5bf9cc08
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
507014e4c7a70cd09410c89c8ed466c8edab39d2
|
f81050859170c8708a1b296da8dd3ef0dd314a11
|
||||||
@@ -2701,6 +2701,7 @@ static int whereLoopAddBtree(
|
|||||||
pNew->rSetup += 24;
|
pNew->rSetup += 24;
|
||||||
}
|
}
|
||||||
ApplyCostMultiplier(pNew->rSetup, pTab->costMult);
|
ApplyCostMultiplier(pNew->rSetup, pTab->costMult);
|
||||||
|
if( pNew->rSetup<0 ) pNew->rSetup = 0;
|
||||||
/* TUNING: Each index lookup yields 20 rows in the table. This
|
/* TUNING: Each index lookup yields 20 rows in the table. This
|
||||||
** is more than the usual guess of 10 rows, since we have no way
|
** is more than the usual guess of 10 rows, since we have no way
|
||||||
** of knowing how selective the index will ultimately be. It would
|
** of knowing how selective the index will ultimately be. It would
|
||||||
|
|||||||
Reference in New Issue
Block a user