Lines Matching refs:pCell

71723   u8 *pCell,              /* Pointer to the cell text. */
71749 pInfo->nSize = (u16)(&pInfo->pPayload[pInfo->nLocal] - pCell) + 4;
71786 u8 *pCell, /* Pointer to the cell text. */
71795 pInfo->nSize = 4 + getVarint(&pCell[4], (u64*)&pInfo->nKey);
71803 u8 *pCell, /* Pointer to the cell text. */
71814 pIter = pCell;
71880 pInfo->nSize = nPayload + (u16)(pIter - pCell);
71884 btreeParseCellAdjustSizeForOverflow(pPage, pCell, pInfo);
71889 u8 *pCell, /* Pointer to the cell text. */
71898 pIter = pCell + pPage->childPtrSize;
71917 pInfo->nSize = nPayload + (u16)(pIter - pCell);
71921 btreeParseCellAdjustSizeForOverflow(pPage, pCell, pInfo);
71946 static u16 cellSizePtr(MemPage *pPage, u8 *pCell){
71947 u8 *pIter = pCell + 4; /* For looping over bytes of pCell */
71957 pPage->xParseCell(pPage, pCell, &debuginfo);
71973 nSize += (u32)(pIter - pCell);
71983 nSize += 4 + (u16)(pIter - pCell);
71988 static u16 cellSizePtrIdxLeaf(MemPage *pPage, u8 *pCell){
71989 u8 *pIter = pCell; /* For looping over bytes of pCell */
71999 pPage->xParseCell(pPage, pCell, &debuginfo);
72015 nSize += (u32)(pIter - pCell);
72025 nSize += 4 + (u16)(pIter - pCell);
72030 static u16 cellSizePtrNoPayload(MemPage *pPage, u8 *pCell){
72031 u8 *pIter = pCell + 4; /* For looping over bytes of pCell */
72040 pPage->xParseCell(pPage, pCell, &debuginfo);
72048 assert( debuginfo.nSize==(u16)(pIter - pCell) || CORRUPT_DB );
72049 return (u16)(pIter - pCell);
72051 static u16 cellSizePtrTableLeaf(MemPage *pPage, u8 *pCell){
72052 u8 *pIter = pCell; /* For looping over bytes of pCell */
72062 pPage->xParseCell(pPage, pCell, &debuginfo);
72088 nSize += (u32)(pIter - pCell);
72098 nSize += 4 + (u16)(pIter - pCell);
72120 static void ptrmapPutOvflPtr(MemPage *pPage, MemPage *pSrc, u8 *pCell,int *pRC){
72123 assert( pCell!=0 );
72124 pPage->xParseCell(pPage, pCell, &info);
72127 if( SQLITE_OVERFLOW(pSrc->aDataEnd, pCell, pCell+info.nLocal) ){
72132 ovfl = get4byte(&pCell[info.nSize-4]);
74345 u8 *pCell = findCell(pPage, i);
74347 ptrmapPutOvflPtr(pPage, pPage, pCell, &rc);
74350 Pgno childPgno = get4byte(pCell);
74396 u8 *pCell = findCell(pPage, i);
74399 pPage->xParseCell(pPage, pCell, &info);
74401 if( pCell+info.nSize > pPage->aData+pPage->pBt->usableSize ){
74404 if( iFrom==get4byte(pCell+info.nSize-4) ){
74405 put4byte(pCell+info.nSize-4, iTo);
74410 if( pCell+4 > pPage->aData+pPage->pBt->usableSize ){
74413 if( get4byte(pCell)==iFrom ){
74414 put4byte(pCell, iTo);
76321 u8 *pCell; /* Pointer to current cell in pPage */
76337 pCell = findCellPastPtr(pPage, idx);
76339 while( 0x80 <= *(pCell++) ){
76340 if( pCell>=pPage->aDataEnd ){
76345 getVarint(pCell, (u64*)&nCellKey);
76419 u8 *pCell = findCellPastPtr(pPage, idx);
76421 nCell = pCell[0];
76426 testcase( pCell+nCell+1==pPage->aDataEnd );
76427 c = xRecordCompare(nCell, (void*)&pCell[1], pIdxKey);
76428 }else if( !(pCell[1] & 0x80)
76429 && (nCell = ((nCell&0x7f)<<7) + pCell[1])<=pPage->maxLocal
76433 testcase( pCell+nCell+2==pPage->aDataEnd );
76434 c = xRecordCompare(nCell, (void*)&pCell[2], pIdxKey);
76565 u8 *pCell; /* Pointer to current cell in pPage */
76580 pCell = findCellPastPtr(pPage, idx);
76590 nCell = pCell[0];
76595 testcase( pCell+nCell+1==pPage->aDataEnd );
76596 c = xRecordCompare(nCell, (void*)&pCell[1], pIdxKey);
76597 }else if( !(pCell[1] & 0x80)
76598 && (nCell = ((nCell&0x7f)<<7) + pCell[1])<=pPage->maxLocal
76602 testcase( pCell+nCell+2==pPage->aDataEnd );
76603 c = xRecordCompare(nCell, (void*)&pCell[2], pIdxKey);
76615 u8 * const pCellBody = pCell - pPage->childPtrSize;
77425 unsigned char *pCell, /* First byte of the Cell */
77436 testcase( pCell + pInfo->nSize == pPage->aDataEnd );
77437 testcase( pCell + (pInfo->nSize-1) == pPage->aDataEnd );
77438 if( pCell + pInfo->nSize > pPage->aDataEnd ){
77442 ovflPgno = get4byte(pCell + pInfo->nSize - 4);
77497 #define BTREE_CLEAR_CELL(rc, pPage, pCell, sInfo) \
77498 pPage->xParseCell(pPage, pCell, &sInfo); \
77500 rc = clearCellOverflow(pPage, pCell, &sInfo); \
77520 unsigned char *pCell, /* Complete text of the cell */
77539 assert( pCell<pPage->aData || pCell>=&pPage->aData[pPage->pBt->pageSize]
77549 nHeader += putVarint32(&pCell[nHeader], nPayload);
77550 nHeader += putVarint(&pCell[nHeader], *(u64*)&pX->nKey);
77555 nHeader += putVarint32(&pCell[nHeader], nPayload);
77559 pPayload = &pCell[nHeader];
77588 pPrior = &pCell[nHeader+n];
77608 pPage->xParseCell(pPage, pCell, &info);
77609 assert( nHeader==(int)(info.pPayload - pCell) );
77778 u8 *pCell, /* Content of the new cell */
77794 assert( sz==pPage->xCellSize(pPage, pCell) || CORRUPT_DB );
77799 memcpy(pTemp, pCell, sz);
77800 pCell = pTemp;
77802 put4byte(pCell, iChild);
77808 pPage->apOvfl[j] = pCell;
77839 memcpy(&data[idx+4], pCell+4, sz-4);
77854 ptrmapPutOvflPtr(pPage, pPage, pCell, &rc2);
77875 u8 *pCell, /* Content of the new cell */
77889 assert( sz==pPage->xCellSize(pPage, pCell) || CORRUPT_DB );
77898 pPage->apOvfl[j] = pCell;
77924 memcpy(&data[idx], pCell, sz);
77938 ptrmapPutOvflPtr(pPage, pPage, pCell, &rc2);
78118 u8 *pCell = pCArray->apCell[i];
78121 if( SQLITE_WITHIN(pCell,aData+j,pEnd) ){
78122 if( ((uptr)(pCell+sz))>(uptr)pEnd ) return SQLITE_CORRUPT_BKPT;
78123 pCell = &pTmp[pCell - aData];
78124 }else if( (uptr)(pCell+sz)>(uptr)pSrcEnd
78125 && (uptr)(pCell)<(uptr)pSrcEnd
78134 memmove(pData, pCell, sz);
78135 assert( sz==pPg->xCellSize(pPg, pCell) || CORRUPT_DB );
78261 u8 *pCell = pCArray->apCell[i];
78262 if( SQLITE_WITHIN(pCell, pStart, pEnd) ){
78270 iOfst = (u16)(pCell - aData);
78401 u8 *pCell = pCArray->apCell[i+iNew];
78403 if( SQLITE_WITHIN(pCell, aData, &aData[pPg->pBt->usableSize]) ){
78404 pCell = &pTmp[pCell - aData];
78406 assert( 0==memcmp(pCell, &aData[iOff],
78467 u8 *pCell = pPage->apOvfl[0];
78468 u16 szCell = pPage->xCellSize(pPage, pCell);
78477 b.apCell = &pCell;
78500 ptrmapPutOvflPtr(pNew, pNew, pCell, &rc);
78517 pCell = findCell(pPage, pPage->nCell-1);
78518 pStop = &pCell[9];
78519 while( (*(pCell++)&0x80) && pCell<pStop );
78520 pStop = &pCell[9];
78521 while( ((*(pOut++) = *(pCell++))&0x80) && pCell<pStop );
79224 u8 *pCell = b.apCell[i];
79245 || !SQLITE_WITHIN(pCell,pOld->aData,pOld->aDataEnd)
79248 ptrmapPut(pBt, get4byte(pCell), PTRMAP_BTREE, pNew->pgno, &rc);
79251 ptrmapPutOvflPtr(pNew, pOld, pCell, &rc);
79260 u8 *pCell;
79269 pCell = b.apCell[j];
79273 memcpy(&pNew->aData[8], pCell, 4);
79283 pCell = pTemp;
79284 sz = 4 + putVarint(&pCell[4], info.nKey);
79287 pCell -= 4;
79301 sz = pParent->xCellSize(pParent, pCell);
79309 if( SQLITE_OVERFLOW(pSrcEnd, pCell, pCell+sz) ){
79313 rc = insertCell(pParent, nxDiv+i, pCell, sz, pTemp, pNew->pgno);
80274 unsigned char *pCell; /* Pointer to cell to delete */
80304 pCell = findCell(pPage, iCellIdx);
80308 if( pCell<&pPage->aCellIdx[pPage->nCell] ){
80331 || (pPage->nFree+pPage->xCellSize(pPage,pCell)+2) >
80375 BTREE_CLEAR_CELL(rc, pPage, pCell, info);
80399 pCell = findCell(pLeaf, pLeaf->nCell-1);
80400 if( pCell<&pLeaf->aData[4] ) return SQLITE_CORRUPT_PAGE(pLeaf);
80401 nCell = pLeaf->xCellSize(pLeaf, pCell);
80407 rc = insertCell(pPage, iCellIdx, pCell-4, nCell+4, pTmp, n);
80647 unsigned char *pCell;
80666 pCell = findCell(pPage, i);
80668 rc = clearDatabasePage(pBt, get4byte(pCell), 1, pnChange);
80671 BTREE_CLEAR_CELL(rc, pPage, pCell, info);
81302 u8 *pCell; /* Cell content */
81403 pCell = &data[pc];
81404 pPage->xParseCell(pPage, pCell, &info);
81426 pgnoOvfl = get4byte(&pCell[info.nSize - 4]);
81437 pgno = get4byte(pCell);
211132 RtreeCell *pCell, /* The cell to write */
211137 p += writeInt64(p, pCell->iRowid);
211139 p += writeCoord(p, &pCell->aCoord[ii]);
211165 RtreeCell *pCell /* The cell to be inserted */
211175 nodeOverwriteCell(pRtree, pNode, pCell, nCell);
211272 RtreeCell *pCell /* OUT: Write the cell contents here */
211277 pCell->iRowid = nodeGetRowid(pRtree, pNode, iCell);
211279 pCoord = pCell->aCoord;
212539 RtreeCell *pCell, /* Cell to insert into rtree */
212564 if( cellContains(pRtree, &cell, pCell) ){
212584 cellUnion(pRtree, &cell, pCell);
212614 RtreeCell *pCell /* This cell was just inserted */
212636 if( !cellContains(pRtree, &cell, pCell) ){
212637 cellUnion(pRtree, &cell, pCell);
212828 RtreeCell *pCell = &aCell[aaSorted[iBestDim][ii]];
212829 nodeInsertCell(pRtree, pTarget, pCell);
212830 cellUnion(pRtree, pBbox, pCell);
212865 RtreeCell *pCell,
212896 memcpy(&aCell[nCell], pCell, sizeof(RtreeCell));
212964 if( iRowid==pCell->iRowid ){
212980 rc = updateMapping(pRtree, pCell->iRowid, pLeft, iHeight);
213160 RtreeCell *pCell,
213165 RtreeNode *pChild = nodeHashLookup(pRtree, pCell->iRowid);
213172 if( nodeInsertCell(pRtree, pNode, pCell) ){
213173 rc = SplitNode(pRtree, pNode, pCell, iHeight);
213175 rc = AdjustTree(pRtree, pNode, pCell);
213178 rc = rowidWrite(pRtree, pCell->iRowid, pNode->iNode);
213180 rc = parentWrite(pRtree, pCell->iRowid, pNode->iNode);
214323 u8 *pCell, /* Pointer to cell coordinates */
214331 readCoord(&pCell[4*2*i], &c1);
214332 readCoord(&pCell[4*(2*i + 1)], &c2);
214402 u8 *pCell = &aNode[4 + i*(8 + pCheck->nDim*2*4)];
214403 i64 iVal = readInt64(pCell);
214404 rtreeCheckCellCoord(pCheck, iNode, i, &pCell[8], aParent);
214408 rtreeCheckNode(pCheck, iDepth-1, &pCell[8], iVal);
223985 StatCell *pCell = &p->aCell[i];
223990 pCell->iChildPg = sqlite3Get4byte(&aData[iOff]);
224006 pCell->nLocal = nLocal;
224015 pCell->nLastOvfl = (nPayload-nLocal) - (nOvfl-1) * (nUsable-4);
224016 pCell->nOvfl = nOvfl;
224017 pCell->aOvfl = sqlite3_malloc64(sizeof(u32)*nOvfl);
224018 if( pCell->aOvfl==0 ) return SQLITE_NOMEM_BKPT;
224019 pCell->aOvfl[0] = sqlite3Get4byte(&aData[iOff+nLocal]);
224022 u32 iPrev = pCell->aOvfl[j-1];
224029 pCell->aOvfl[j] = sqlite3Get4byte(sqlite3PagerGetData(pPg));
224151 StatCell *pCell = &p->aCell[p->iCell];
224152 while( pCell->iOvfl<pCell->nOvfl ){
224160 if( pCell->iOvfl<pCell->nOvfl-1 ){
224163 pCsr->nPayload += pCell->nLastOvfl;
224164 pCsr->nUnused += nUsable - 4 - pCell->nLastOvfl;
224166 iOvfl = pCell->iOvfl;
224167 pCell->iOvfl++;
224170 pCsr->iPageno = pCell->aOvfl[iOvfl];