SQLite

Check-in [7c6a19ba9b]
Login

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

Overview
Comment:Avoid unnecessary function prologues in the sqlite3VdbeAddOp3() routine.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 7c6a19ba9b0bdb1cc0b9a9796b7c1c114944d927
User & Date: drh 2015-11-09 12:33:39.340
Context
2015-11-09
12:44
Check in the cg_anno.tcl and run-speed-test.sh scripts, as an historical record. (check-in: 836418d3b7 user: drh tags: trunk)
12:33
Avoid unnecessary function prologues in the sqlite3VdbeAddOp3() routine. (check-in: 7c6a19ba9b user: drh tags: trunk)
02:08
Small size reduction and performance increase in the parser. (check-in: d62cd757a6 user: drh tags: trunk)
Changes
Unified Diff Ignore Whitespace Patch
Changes to src/vdbeaux.c.
153
154
155
156
157
158
159






160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
**
**    p1, p2, p3      Operands
**
** Use the sqlite3VdbeResolveLabel() function to fix an address and
** the sqlite3VdbeChangeP4() function to change the value of the P4
** operand.
*/






int sqlite3VdbeAddOp3(Vdbe *p, int op, int p1, int p2, int p3){
  int i;
  VdbeOp *pOp;

  i = p->nOp;
  assert( p->magic==VDBE_MAGIC_INIT );
  assert( op>0 && op<0xff );
  if( p->pParse->nOpAlloc<=i ){
    if( growOpArray(p, 1) ){
      return 1;
    }
  }
  p->nOp++;
  pOp = &p->aOp[i];
  pOp->opcode = (u8)op;
  pOp->p5 = 0;
  pOp->p1 = p1;
  pOp->p2 = p2;







>
>
>
>
>
>








<
|
<







153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173

174

175
176
177
178
179
180
181
**
**    p1, p2, p3      Operands
**
** Use the sqlite3VdbeResolveLabel() function to fix an address and
** the sqlite3VdbeChangeP4() function to change the value of the P4
** operand.
*/
static SQLITE_NOINLINE int growOp3(Vdbe *p, int op, int p1, int p2, int p3){
  assert( p->pParse->nOpAlloc<=p->nOp );
  if( growOpArray(p, 1) ) return 1;
  assert( p->pParse->nOpAlloc>p->nOp );
  return sqlite3VdbeAddOp3(p, op, p1, p2, p3);
}
int sqlite3VdbeAddOp3(Vdbe *p, int op, int p1, int p2, int p3){
  int i;
  VdbeOp *pOp;

  i = p->nOp;
  assert( p->magic==VDBE_MAGIC_INIT );
  assert( op>0 && op<0xff );
  if( p->pParse->nOpAlloc<=i ){

    return growOp3(p, op, p1, p2, p3);

  }
  p->nOp++;
  pOp = &p->aOp[i];
  pOp->opcode = (u8)op;
  pOp->p5 = 0;
  pOp->p1 = p1;
  pOp->p2 = p2;