-C Small\ssize\sreduction\sand\sperformance\sincrease\sfor\sreleaseMemArray().
-D 2014-09-19T16:13:12.685
+C Remove\sa\slocal\svariable\sfrom\sthe\sOP_Column\simplementation,\sresulting\sin\sa\nmodest\ssize\sreduction\sand\sa\sperformance\sincrease.
+D 2014-09-19T16:56:45.748
F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f
F Makefile.in cf57f673d77606ab0f2d9627ca52a9ba1464146a
F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23
F src/utf.c fc6b889ba0779b7722634cdeaa25f1930d93820c
F src/util.c 4006c01772bd8d8ac4306d523bbcee41d3e392d8
F src/vacuum.c 59f03f92bcff57faa6a8ca256eb29ccddfb0614a
-F src/vdbe.c 9f2a0a2dfa06e99feabd754e9be3a436ac3cf97d
+F src/vdbe.c c90b7ebe856beb75077cf4486efc1863de219f34
F src/vdbe.h 09f5b4e3719fa454f252322b1cdab5cf1f361327
F src/vdbeInt.h f177bed1ec8d4eb5c7089f012aeb95f374745735
F src/vdbeapi.c e9e33b59834e3edc8790209765e069874c269d9d
F tool/warnings-clang.sh f6aa929dc20ef1f856af04a730772f59283631d4
F tool/warnings.sh 0abfd78ceb09b7f7c27c688c8e3fe93268a13b32
F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f
-P 9b42c3da6b2593a10b8fe4b2fcc3d650132625c1
-R 351b243201f0eb22d3adcd68e13fd4a5
+P 24cd32d681df58f687b2afbe4b13d579e3efdd4b
+R dfacf0845df6af56f07b0acf2e71dc1f
U drh
-Z 9538899cfe34e917b2f35980fa39505f
+Z 845eafc57b4e53556b2c7ee6a79ebdad
int p2; /* column number to retrieve */
VdbeCursor *pC; /* The VDBE cursor */
BtCursor *pCrsr; /* The BTree cursor */
- u32 *aType; /* aType[i] holds the numeric type of the i-th column */
u32 *aOffset; /* aOffset[i] is offset to start of data for i-th column */
int len; /* The length of the serialized data for the column */
int i; /* Loop counter */
u32 szField; /* Number of bytes in the content of a field */
u32 avail; /* Number of bytes of available data */
u32 t; /* A type code from the record header */
+ u16 fx; /* pDest->flags value */
Mem *pReg; /* PseudoTable input register */
p2 = pOp->p2;
pC = p->apCsr[pOp->p1];
assert( pC!=0 );
assert( p2<pC->nField );
- aType = pC->aType;
- aOffset = aType + pC->nField;
+ aOffset = pC->aType + pC->nField;
#ifndef SQLITE_OMIT_VIRTUALTABLE
assert( pC->pVtabCursor==0 ); /* OP_Column never called on virtual table */
#endif
}
/* Make sure at least the first p2+1 entries of the header have been
- ** parsed and valid information is in aOffset[] and aType[].
+ ** parsed and valid information is in aOffset[] and pC->aType[].
*/
if( pC->nHdrParsed<=p2 ){
/* If there is more header available for parsing in the record, try
zData = pC->aRow;
}
- /* Fill in aType[i] and aOffset[i] values through the p2-th field. */
+ /* Fill in pC->aType[i] and aOffset[i] values through the p2-th field. */
i = pC->nHdrParsed;
offset = aOffset[i];
zHdr = zData + pC->iHdrOffset;
}else{
zHdr += sqlite3GetVarint32(zHdr, &t);
}
- aType[i] = t;
+ pC->aType[i] = t;
szField = sqlite3VdbeSerialTypeLen(t);
offset += szField;
if( offset<szField ){ /* True if offset overflows */
}
/* Extract the content for the p2+1-th column. Control can only
- ** reach this point if aOffset[p2], aOffset[p2+1], and aType[p2] are
+ ** reach this point if aOffset[p2], aOffset[p2+1], and pC->aType[p2] are
** all valid.
*/
assert( p2<pC->nHdrParsed );
assert( rc==SQLITE_OK );
assert( sqlite3VdbeCheckMemInvariants(pDest) );
if( VdbeMemDynamic(pDest) ) sqlite3VdbeMemSetNull(pDest);
+ t = pC->aType[p2];
if( pC->szRow>=aOffset[p2+1] ){
/* This is the common case where the desired content fits on the original
** page - where the content is not on an overflow page */
- sqlite3VdbeSerialGet(pC->aRow+aOffset[p2], aType[p2], pDest);
+ sqlite3VdbeSerialGet(pC->aRow+aOffset[p2], t, pDest);
}else{
/* This branch happens only when content is on overflow pages */
- t = aType[p2];
if( ((pOp->p5 & (OPFLAG_LENGTHARG|OPFLAG_TYPEOFARG))!=0
&& ((t>=12 && (t&1)==0) || (pOp->p5 & OPFLAG_TYPEOFARG)!=0))
|| (len = sqlite3VdbeSerialTypeLen(t))==0
** used. The following code does the equivalent of Deephemeralize()
** but does it faster. */
if( (pDest->flags & MEM_Ephem)!=0 && pDest->z ){
- u16 f = pDest->flags & (MEM_Str|MEM_Blob);
- assert( f!=0 );
+ fx = pDest->flags & (MEM_Str|MEM_Blob);
+ assert( fx!=0 );
zData = (const u8*)pDest->z;
len = pDest->n;
if( sqlite3VdbeMemClearAndResize(pDest, len+2) ) goto no_mem;
memcpy(pDest->z, zData, len);
pDest->z[len] = 0;
pDest->z[len+1] = 0;
- pDest->flags = f|MEM_Term;
+ pDest->flags = fx|MEM_Term;
}
op_column_error:
UPDATE_MAX_BLOBSIZE(pDest);