1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-12-03 08:01:19 +03:00

Use memcmp() instead of the BINARY collating function where possible, for

a performance boost.

FossilOrigin-Name: c5a3a1af3c7bd34886e944a1fef2f6340ded24a0
This commit is contained in:
drh
2013-12-06 22:45:31 +00:00
parent 72b8ef6ce3
commit b8a9bb4fb9
3 changed files with 10 additions and 9 deletions

View File

@@ -4183,8 +4183,9 @@ KeyInfo *sqlite3KeyInfoOfIndex(Parse *pParse, Index *pIdx){
assert( sqlite3KeyInfoIsWriteable(pKey) );
for(i=0; i<nCol; i++){
char *zColl = pIdx->azColl[i];
if( NEVER(zColl==0) ) zColl = "BINARY";
pKey->aColl[i] = sqlite3LocateCollSeq(pParse, zColl);
assert( zColl!=0 );
pKey->aColl[i] = strcmp(zColl,"BINARY")==0 ? 0 :
sqlite3LocateCollSeq(pParse, zColl);
pKey->aSortOrder[i] = pIdx->aSortOrder[i];
}
if( pParse->nErr ){