Small size reduction and performance enhancement in whereScanInit().
FossilOrigin-Name: c23f5ef337533c1ec6e3ba78a2910352181cc9ee
This commit is contained in:
parent
392ddeb12d
commit
9904298bb3
12
manifest
12
manifest
@ -1,5 +1,5 @@
|
||||
C Small\ssize\sreduction\sand\sperformance\simprovement\sin\swhereScanNext().
|
||||
D 2016-10-26T17:57:40.045
|
||||
C Small\ssize\sreduction\sand\sperformance\senhancement\sin\swhereScanInit().
|
||||
D 2016-10-26T18:41:43.441
|
||||
F Makefile.in 6fd48ffcf7c2deea7499062d1f3747f986c19678
|
||||
F Makefile.linux-gcc 7bc79876b875010e8c8f9502eb935ca92aa3c434
|
||||
F Makefile.msc 5151cc64c4c05f3455f4f692ad11410a810d937f
|
||||
@ -468,7 +468,7 @@ F src/vxworks.h d2988f4e5a61a4dfe82c6524dd3d6e4f2ce3cdb9
|
||||
F src/wal.c 0b44e89742024d3b6992bf404d2ab692113e1e60
|
||||
F src/wal.h bf03a23da3100ab25e5c0363450233cfee09cfc2
|
||||
F src/walker.c 91a6df7435827e41cff6bb7df50ea00934ee78b0
|
||||
F src/where.c 694dd84a7017f2b284e1da55b5bf00bfd3e1f4e4
|
||||
F src/where.c 952f76e7a03727480b274b66ca6641b1657cd591
|
||||
F src/whereInt.h 2bcc3d176e6091cb8f50a30b65c006e88a73614d
|
||||
F src/wherecode.c 717a65294df46f30e9b9933d2a63a4bcbca5a9a8
|
||||
F src/whereexpr.c 379d0017fb7bc9e5a4d8cd4b056c747de946430e
|
||||
@ -1528,7 +1528,7 @@ F vsixtest/vsixtest.tcl 6a9a6ab600c25a91a7acc6293828957a386a8a93
|
||||
F vsixtest/vsixtest.vcxproj.data 2ed517e100c66dc455b492e1a33350c1b20fbcdc
|
||||
F vsixtest/vsixtest.vcxproj.filters 37e51ffedcdb064aad6ff33b6148725226cd608e
|
||||
F vsixtest/vsixtest_TemporaryKey.pfx e5b1b036facdb453873e7084e1cae9102ccc67a0
|
||||
P ec9dab8054c71d112c68f58a45821b38c2a45677
|
||||
R 48fa39390c766bcfb2f028645ad7c897
|
||||
P d861ee17eb900a607de6ec3f4a5d5c24cfb834a0
|
||||
R bd2e0f7c23b42c2ba66bc7a6e23d9160
|
||||
U drh
|
||||
Z 1bf2b72e2a8cf9aca52b2af50acc10fd
|
||||
Z f746697b9b9d8bf9f72c796f60e10bfb
|
||||
|
@ -1 +1 @@
|
||||
d861ee17eb900a607de6ec3f4a5d5c24cfb834a0
|
||||
c23f5ef337533c1ec6e3ba78a2910352181cc9ee
|
27
src/where.c
27
src/where.c
@ -202,7 +202,6 @@ static WhereTerm *whereScanNext(WhereScan *pScan){
|
||||
pWC = pScan->pWC;
|
||||
while(1){
|
||||
iColumn = pScan->aiColumn[pScan->iEquiv-1];
|
||||
if( iColumn==XN_EXPR && pScan->pIdxExpr==0 ) return 0;
|
||||
iCur = pScan->aiCur[pScan->iEquiv-1];
|
||||
assert( pWC!=0 );
|
||||
do{
|
||||
@ -299,24 +298,24 @@ static WhereTerm *whereScanInit(
|
||||
u32 opMask, /* Operator(s) to scan for */
|
||||
Index *pIdx /* Must be compatible with this index */
|
||||
){
|
||||
int j = 0;
|
||||
|
||||
/* memset(pScan, 0, sizeof(*pScan)); */
|
||||
pScan->pOrigWC = pWC;
|
||||
pScan->pWC = pWC;
|
||||
pScan->pIdxExpr = 0;
|
||||
pScan->idxaff = 0;
|
||||
pScan->zCollName = 0;
|
||||
if( pIdx ){
|
||||
j = iColumn;
|
||||
int j = iColumn;
|
||||
iColumn = pIdx->aiColumn[j];
|
||||
if( iColumn==XN_EXPR ) pScan->pIdxExpr = pIdx->aColExpr->a[j].pExpr;
|
||||
if( iColumn==pIdx->pTable->iPKey ) iColumn = XN_ROWID;
|
||||
}
|
||||
if( pIdx && iColumn>=0 ){
|
||||
pScan->idxaff = pIdx->pTable->aCol[iColumn].affinity;
|
||||
pScan->zCollName = pIdx->azColl[j];
|
||||
}else{
|
||||
pScan->idxaff = 0;
|
||||
pScan->zCollName = 0;
|
||||
if( iColumn==XN_EXPR ){
|
||||
pScan->pIdxExpr = pIdx->aColExpr->a[j].pExpr;
|
||||
}else if( iColumn==pIdx->pTable->iPKey ){
|
||||
iColumn = XN_ROWID;
|
||||
}else if( iColumn>=0 ){
|
||||
pScan->idxaff = pIdx->pTable->aCol[iColumn].affinity;
|
||||
pScan->zCollName = pIdx->azColl[j];
|
||||
}
|
||||
}else if( iColumn==XN_EXPR ){
|
||||
return 0;
|
||||
}
|
||||
pScan->opMask = opMask;
|
||||
pScan->k = 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user