1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-06 15:49:35 +03:00

Avoid duplicate OP_Column opcodes by remembering prior results.

This is similar to CSE, but only applies to columns. (CVS 4943)

FossilOrigin-Name: c29ee0fed23dcdbd9dde6b1e42b603100ea2389c
This commit is contained in:
drh
2008-03-31 23:48:03 +00:00
parent 678ccce8b3
commit e55cbd7228
9 changed files with 209 additions and 47 deletions

View File

@@ -12,7 +12,7 @@
** This file contains C code routines that are called by the parser
** in order to generate code for DELETE FROM statements.
**
** $Id: delete.c,v 1.164 2008/03/25 17:23:33 drh Exp $
** $Id: delete.c,v 1.165 2008/03/31 23:48:04 drh Exp $
*/
#include "sqliteInt.h"
@@ -534,6 +534,7 @@ int sqlite3GenerateIndexKey(
if( doMakeRec ){
sqlite3VdbeAddOp3(v, OP_MakeRecord, regBase, nCol+1, regOut);
sqlite3IndexAffinityStr(v, pIdx);
sqlite3ExprExpireColumnCacheLines(pParse, regBase, regBase+nCol);
}
sqlite3ReleaseTempRange(pParse, regBase, nCol+1);
return regBase;