1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-14 00:22:38 +03:00

Avoid calling sqlite3VdbeCursorMoveto() from more than one point in vdbe.c. Doing so prevents it from being inlined as part of OP_Column.

FossilOrigin-Name: 166d5af8914c6954fb24a06e9686f194c0d0acde
This commit is contained in:
dan
2015-09-14 09:23:47 +00:00
parent 7210b3d1e8
commit c6157e1971
4 changed files with 23 additions and 17 deletions

View File

@@ -1069,7 +1069,11 @@ Bitmask sqlite3WhereCodeOneLoopStart(
iRowidReg = ++pParse->nMem;
sqlite3VdbeAddOp2(v, OP_IdxRowid, iIdxCur, iRowidReg);
sqlite3ExprCacheStore(pParse, iCur, -1, iRowidReg);
sqlite3VdbeAddOp2(v, OP_Seek, iCur, iRowidReg); /* Deferred seek */
if( pWInfo->okOnePass ){
sqlite3VdbeAddOp3(v, OP_NotExists, iCur, 0, iRowidReg);
}else{
sqlite3VdbeAddOp2(v, OP_Seek, iCur, iRowidReg); /* Deferred seek */
}
}else if( iCur!=iIdxCur ){
Index *pPk = sqlite3PrimaryKeyIndex(pIdx->pTable);
iRowidReg = sqlite3GetTempRange(pParse, pPk->nKeyCol);