Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Changes In Branch optimize-cellinfo Excluding Merge-Ins
This is equivalent to a diff from 7adfa4a5 to 78507154
2015-12-30
| ||
18:18 | Reduce the size of the CellInfo object from 32 to 24 bytes on 64-bit machines, for a small performance increase and library size reduction. check-in: 6a4cfc7a user: drh tags: trunk | |
2015-12-18
| ||
16:29 | Micro-optimizations and comment fixes on the mem5.c memory allocator module. check-in: 8bf5e056 user: drh tags: trunk | |
03:59 | Reduce the size of the CellInfo object from 32 to 24 bytes on 64-bit machines. Closed-Leaf check-in: 78507154 user: drh tags: optimize-cellinfo | |
2015-12-17
| ||
20:36 | Add the "offsets=0" option to fts5, to create a smaller index without term offset information. A few things are currently broken on this branch. check-in: 40b5bbf0 user: dan tags: fts5-offsets | |
17:30 | Reduce the size of the VdbeCursor object by a pointer (the pBt pointer used for ephemeral tables). check-in: 98b710c3 user: drh tags: optimize-vdbecursor | |
14:18 | Fix the spellfix1_scriptcode() function to ignore whitespace and punctuation, and to recognize hebrew and arabic scripts. check-in: 7adfa4a5 user: drh tags: trunk | |
13:28 | Fixes for harmless compiler warnings. check-in: 85ebd46c user: drh tags: trunk | |
Changes to src/btree.c.
︙ | |||
1047 1048 1049 1050 1051 1052 1053 | 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 | - + - | testcase( surplus==maxLocal ); testcase( surplus==maxLocal+1 ); if( surplus <= maxLocal ){ pInfo->nLocal = (u16)surplus; }else{ pInfo->nLocal = (u16)minLocal; } |
︙ | |||
1080 1081 1082 1083 1084 1085 1086 | 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 | - | assert( pPage->childPtrSize==4 ); #ifndef SQLITE_DEBUG UNUSED_PARAMETER(pPage); #endif pInfo->nSize = 4 + getVarint(&pCell[4], (u64*)&pInfo->nKey); pInfo->nPayload = 0; pInfo->nLocal = 0; |
︙ | |||
1150 1151 1152 1153 1154 1155 1156 | 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 | - | if( nPayload<=pPage->maxLocal ){ /* This is the (easy) common case where the entire payload fits ** on the local page. No overflow is required. */ pInfo->nSize = nPayload + (u16)(pIter - pCell); if( pInfo->nSize<4 ) pInfo->nSize = 4; pInfo->nLocal = (u16)nPayload; |
︙ | |||
1189 1190 1191 1192 1193 1194 1195 | 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 | - | if( nPayload<=pPage->maxLocal ){ /* This is the (easy) common case where the entire payload fits ** on the local page. No overflow is required. */ pInfo->nSize = nPayload + (u16)(pIter - pCell); if( pInfo->nSize<4 ) pInfo->nSize = 4; pInfo->nLocal = (u16)nPayload; |
︙ | |||
1305 1306 1307 1308 1309 1310 1311 | 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 | - - + + | ** for the overflow page. */ static void ptrmapPutOvflPtr(MemPage *pPage, u8 *pCell, int *pRC){ CellInfo info; if( *pRC ) return; assert( pCell!=0 ); pPage->xParseCell(pPage, pCell, &info); |
︙ | |||
3344 3345 3346 3347 3348 3349 3350 | 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 | - - - + + + - + | nCell = pPage->nCell; for(i=0; i<nCell; i++){ u8 *pCell = findCell(pPage, i); if( eType==PTRMAP_OVERFLOW1 ){ CellInfo info; pPage->xParseCell(pPage, pCell, &info); |
︙ | |||
5990 5991 5992 5993 5994 5995 5996 | 5986 5987 5988 5989 5990 5991 5992 5993 5994 5995 5996 5997 5998 5999 6000 6001 6002 6003 6004 6005 6006 | - + - + - + | int rc; int nOvfl; u32 ovflPageSize; assert( sqlite3_mutex_held(pPage->pBt->mutex) ); pPage->xParseCell(pPage, pCell, &info); *pnSize = info.nSize; |
︙ | |||
6145 6146 6147 6148 6149 6150 6151 | 6141 6142 6143 6144 6145 6146 6147 6148 6149 6150 6151 6152 6153 6154 | - | { CellInfo info; pPage->xParseCell(pPage, pCell, &info); assert( nHeader=(int)(info.pPayload - pCell) ); assert( info.nKey==nKey ); assert( *pnSize == info.nSize ); assert( spaceLeft == info.nLocal ); |
︙ | |||
6855 6856 6857 6858 6859 6860 6861 | 6850 6851 6852 6853 6854 6855 6856 6857 6858 6859 6860 6861 6862 6863 6864 6865 | - - + + | for(j=0; j<pPage->nCell; j++){ CellInfo info; u8 *z; z = findCell(pPage, j); pPage->xParseCell(pPage, z, &info); |
︙ | |||
9162 9163 9164 9165 9166 9167 9168 | 9157 9158 9159 9160 9161 9162 9163 9164 9165 9166 9167 9168 9169 9170 9171 9172 9173 | - + - + | maxKey = info.nKey; } /* Check the content overflow list */ if( info.nPayload>info.nLocal ){ int nPage; /* Number of pages on the overflow chain */ Pgno pgnoOvfl; /* First page of the overflow chain */ |
︙ |
Changes to src/btreeInt.h.
︙ | |||
466 467 468 469 470 471 472 | 466 467 468 469 470 471 472 473 474 475 476 477 478 479 | - | ** based on information extract from the raw disk page. */ struct CellInfo { i64 nKey; /* The key for INTKEY tables, or nPayload otherwise */ u8 *pPayload; /* Pointer to the start of payload */ u32 nPayload; /* Bytes of payload */ u16 nLocal; /* Amount of payload held locally, not on overflow */ |
︙ |