/ Check-in [19d9f9ce]
Login
SQLite training in Houston TX on 2019-11-05 (details)
Part of the 2019 Tcl Conference

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Do not try to eliminate No-ops at the end of VDBE program as this can cause problems for some DISTINCT handling algorithms, and does not improve performance. This also fixes an assertion fault found by libFuzzer.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 19d9f9ce691963310fa73ac5ff728ea8dea9d2b2
User & Date: drh 2015-11-24 00:49:44
References
2015-11-24
03:50
Add a test case for the fix of check-in [19d9f9ce691963310] check-in: 19a9c07b user: drh tags: trunk
Context
2015-11-24
01:17
Add a clarifying comment to the virtual table test module 'test8'. check-in: e92f97a6 user: mistachkin tags: trunk
00:49
Do not try to eliminate No-ops at the end of VDBE program as this can cause problems for some DISTINCT handling algorithms, and does not improve performance. This also fixes an assertion fault found by libFuzzer. check-in: 19d9f9ce user: drh tags: trunk
2015-11-21
19:43
Fix an obscure memory leak found by libfuzzer that may occur under some circumstances if expanding a "*" expression causes a SELECT to return more than 32767 columns. check-in: 60de5f23 user: dan tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/vdbeaux.c.

   833    833   void sqlite3VdbeChangeToNoop(Vdbe *p, int addr){
   834    834     if( addr<p->nOp ){
   835    835       VdbeOp *pOp = &p->aOp[addr];
   836    836       sqlite3 *db = p->db;
   837    837       freeP4(db, pOp->p4type, pOp->p4.p);
   838    838       memset(pOp, 0, sizeof(pOp[0]));
   839    839       pOp->opcode = OP_Noop;
   840         -    if( addr==p->nOp-1 ) p->nOp--;
   841    840     }
   842    841   }
   843    842   
   844    843   /*
   845    844   ** If the last opcode is "op" and it is not a jump destination,
   846    845   ** then remove it.  Return true if and only if an opcode was removed.
   847    846   */