Lines Matching refs:pCell
72733 u8 *pCell, /* Pointer to the cell text. */
72759 pInfo->nSize = (u16)(&pInfo->pPayload[pInfo->nLocal] - pCell) + 4;
72797 u8 *pCell, /* Pointer to the cell text. */
72806 pInfo->nSize = 4 + getVarint(&pCell[4], (u64*)&pInfo->nKey);
72814 u8 *pCell, /* Pointer to the cell text. */
72825 pIter = pCell;
72893 pInfo->nSize = (u16)nPayload + (u16)(pIter - pCell);
72897 btreeParseCellAdjustSizeForOverflow(pPage, pCell, pInfo);
72902 u8 *pCell, /* Pointer to the cell text. */
72911 pIter = pCell + pPage->childPtrSize;
72932 pInfo->nSize = (u16)nPayload + (u16)(pIter - pCell);
72936 btreeParseCellAdjustSizeForOverflow(pPage, pCell, pInfo);
72961 static u16 cellSizePtr(MemPage *pPage, u8 *pCell){
72962 u8 *pIter = pCell + 4; /* For looping over bytes of pCell */
72972 pPage->xParseCell(pPage, pCell, &debuginfo);
72988 nSize += (u32)(pIter - pCell);
72998 nSize += 4 + (u16)(pIter - pCell);
73003 static u16 cellSizePtrIdxLeaf(MemPage *pPage, u8 *pCell){
73004 u8 *pIter = pCell; /* For looping over bytes of pCell */
73014 pPage->xParseCell(pPage, pCell, &debuginfo);
73030 nSize += (u32)(pIter - pCell);
73040 nSize += 4 + (u16)(pIter - pCell);
73045 static u16 cellSizePtrNoPayload(MemPage *pPage, u8 *pCell){
73046 u8 *pIter = pCell + 4; /* For looping over bytes of pCell */
73055 pPage->xParseCell(pPage, pCell, &debuginfo);
73063 assert( debuginfo.nSize==(u16)(pIter - pCell) || CORRUPT_DB );
73064 return (u16)(pIter - pCell);
73066 static u16 cellSizePtrTableLeaf(MemPage *pPage, u8 *pCell){
73067 u8 *pIter = pCell; /* For looping over bytes of pCell */
73077 pPage->xParseCell(pPage, pCell, &debuginfo);
73103 nSize += (u32)(pIter - pCell);
73113 nSize += 4 + (u16)(pIter - pCell);
73135 static void ptrmapPutOvflPtr(MemPage *pPage, MemPage *pSrc, u8 *pCell,int *pRC){
73138 assert( pCell!=0 );
73139 pPage->xParseCell(pPage, pCell, &info);
73142 if( SQLITE_OVERFLOW(pSrc->aDataEnd, pCell, pCell+info.nLocal) ){
73147 ovfl = get4byte(&pCell[info.nSize-4]);
75368 u8 *pCell = findCell(pPage, i); local
75370 ptrmapPutOvflPtr(pPage, pPage, pCell, &rc);
75373 Pgno childPgno = get4byte(pCell);
75419 u8 *pCell = findCell(pPage, i); local
75422 pPage->xParseCell(pPage, pCell, &info);
75424 if( pCell+info.nSize > pPage->aData+pPage->pBt->usableSize ){
75427 if( iFrom==get4byte(pCell+info.nSize-4) ){
75428 put4byte(pCell+info.nSize-4, iTo);
75433 if( pCell+4 > pPage->aData+pPage->pBt->usableSize ){
75436 if( get4byte(pCell)==iFrom ){
75437 put4byte(pCell, iTo);
77363 u8 *pCell; /* Pointer to current cell in pPage */ local
77379 pCell = findCellPastPtr(pPage, idx);
77381 while( 0x80 <= *(pCell++) ){
77382 if( pCell>=pPage->aDataEnd ){
77387 getVarint(pCell, (u64*)&nCellKey);
77461 u8 *pCell = findCellPastPtr(pPage, idx); local
77463 nCell = pCell[0];
77468 testcase( pCell+nCell+1==pPage->aDataEnd );
77469 c = xRecordCompare(nCell, (void*)&pCell[1], pIdxKey);
77470 }else if( !(pCell[1] & 0x80)
77471 && (nCell = ((nCell&0x7f)<<7) + pCell[1])<=pPage->maxLocal
77475 testcase( pCell+nCell+2==pPage->aDataEnd );
77476 c = xRecordCompare(nCell, (void*)&pCell[2], pIdxKey);
77607 u8 *pCell; /* Pointer to current cell in pPage */ local
77622 pCell = findCellPastPtr(pPage, idx);
77632 nCell = pCell[0];
77637 testcase( pCell+nCell+1==pPage->aDataEnd );
77638 c = xRecordCompare(nCell, (void*)&pCell[1], pIdxKey);
77639 }else if( !(pCell[1] & 0x80)
77640 && (nCell = ((nCell&0x7f)<<7) + pCell[1])<=pPage->maxLocal
77644 testcase( pCell+nCell+2==pPage->aDataEnd );
77645 c = xRecordCompare(nCell, (void*)&pCell[2], pIdxKey);
77657 u8 * const pCellBody = pCell - pPage->childPtrSize;
78467 unsigned char *pCell, /* First byte of the Cell */
78478 testcase( pCell + pInfo->nSize == pPage->aDataEnd );
78479 testcase( pCell + (pInfo->nSize-1) == pPage->aDataEnd );
78480 if( pCell + pInfo->nSize > pPage->aDataEnd ){
78484 ovflPgno = get4byte(pCell + pInfo->nSize - 4);
78539 #define BTREE_CLEAR_CELL(rc, pPage, pCell, sInfo) \ argument
78540 pPage->xParseCell(pPage, pCell, &sInfo); \
78542 rc = clearCellOverflow(pPage, pCell, &sInfo); \
78562 unsigned char *pCell, /* Complete text of the cell */
78581 assert( pCell<pPage->aData || pCell>=&pPage->aData[pPage->pBt->pageSize]
78591 nHeader += putVarint32(&pCell[nHeader], nPayload);
78592 nHeader += putVarint(&pCell[nHeader], *(u64*)&pX->nKey);
78597 nHeader += putVarint32(&pCell[nHeader], nPayload);
78601 pPayload = &pCell[nHeader];
78630 pPrior = &pCell[nHeader+n];
78650 pPage->xParseCell(pPage, pCell, &info);
78651 assert( nHeader==(int)(info.pPayload - pCell) );
78820 u8 *pCell, /* Content of the new cell */
78836 assert( sz==pPage->xCellSize(pPage, pCell) || CORRUPT_DB );
78841 memcpy(pTemp, pCell, sz);
78842 pCell = pTemp;
78844 put4byte(pCell, iChild);
78850 pPage->apOvfl[j] = pCell;
78881 memcpy(&data[idx+4], pCell+4, sz-4);
78896 ptrmapPutOvflPtr(pPage, pPage, pCell, &rc2);
78917 u8 *pCell, /* Content of the new cell */
78931 assert( sz==pPage->xCellSize(pPage, pCell) || CORRUPT_DB );
78940 pPage->apOvfl[j] = pCell;
78966 memcpy(&data[idx], pCell, sz);
78980 ptrmapPutOvflPtr(pPage, pPage, pCell, &rc2);
79161 u8 *pCell = pCArray->apCell[i]; local
79164 if( SQLITE_WITHIN(pCell,aData+j,pEnd) ){
79165 if( ((uptr)(pCell+sz))>(uptr)pEnd ) return SQLITE_CORRUPT_BKPT;
79166 pCell = &pTmp[pCell - aData];
79167 }else if( (uptr)(pCell+sz)>(uptr)pSrcEnd
79168 && (uptr)(pCell)<(uptr)pSrcEnd
79177 memmove(pData, pCell, sz);
79178 assert( sz==pPg->xCellSize(pPg, pCell) || CORRUPT_DB );
79306 u8 *pCell = pCArray->apCell[i]; local
79307 if( SQLITE_WITHIN(pCell, pStart, pEnd) ){
79315 iOfst = (u16)(pCell - aData);
79450 u8 *pCell = pCArray->apCell[i+iNew]; local
79452 if( SQLITE_WITHIN(pCell, aData, &aData[pPg->pBt->usableSize]) ){
79453 pCell = &pTmp[pCell - aData];
79455 assert( 0==memcmp(pCell, &aData[iOff],
79516 u8 *pCell = pPage->apOvfl[0]; local
79517 u16 szCell = pPage->xCellSize(pPage, pCell);
79526 b.apCell = &pCell;
79550 ptrmapPutOvflPtr(pNew, pNew, pCell, &rc);
79567 pCell = findCell(pPage, pPage->nCell-1);
79568 pStop = &pCell[9];
79569 while( (*(pCell++)&0x80) && pCell<pStop );
79570 pStop = &pCell[9];
79571 while( ((*(pOut++) = *(pCell++))&0x80) && pCell<pStop );
80276 u8 *pCell = b.apCell[i]; local
80297 || !SQLITE_WITHIN(pCell,pOld->aData,pOld->aDataEnd)
80300 ptrmapPut(pBt, get4byte(pCell), PTRMAP_BTREE, pNew->pgno, &rc);
80303 ptrmapPutOvflPtr(pNew, pOld, pCell, &rc);
80312 u8 *pCell; local
80321 pCell = b.apCell[j];
80325 memcpy(&pNew->aData[8], pCell, 4);
80335 pCell = pTemp;
80336 sz = 4 + putVarint(&pCell[4], info.nKey);
80339 pCell -= 4;
80353 sz = pParent->xCellSize(pParent, pCell);
80362 if( SQLITE_OVERFLOW(pSrcEnd, pCell, pCell+sz) ){
80366 rc = insertCell(pParent, nxDiv+i, pCell, sz, pTemp, pNew->pgno);
81327 unsigned char *pCell; /* Pointer to cell to delete */ local
81357 pCell = findCell(pPage, iCellIdx);
81361 if( pCell<&pPage->aCellIdx[pPage->nCell] ){
81384 || (pPage->nFree+pPage->xCellSize(pPage,pCell)+2) >
81428 BTREE_CLEAR_CELL(rc, pPage, pCell, info);
81452 pCell = findCell(pLeaf, pLeaf->nCell-1);
81453 if( pCell<&pLeaf->aData[4] ) return SQLITE_CORRUPT_PAGE(pLeaf);
81454 nCell = pLeaf->xCellSize(pLeaf, pCell);
81460 rc = insertCell(pPage, iCellIdx, pCell-4, nCell+4, pTmp, n);
81700 unsigned char *pCell; local
81719 pCell = findCell(pPage, i);
81721 rc = clearDatabasePage(pBt, get4byte(pCell), 1, pnChange);
81724 BTREE_CLEAR_CELL(rc, pPage, pCell, info);
82355 u8 *pCell; /* Cell content */ local
82456 pCell = &data[pc];
82457 pPage->xParseCell(pPage, pCell, &info);
82479 pgnoOvfl = get4byte(&pCell[info.nSize - 4]);
82490 pgno = get4byte(pCell);
214288 RtreeCell *pCell, /* The cell to write */
214293 p += writeInt64(p, pCell->iRowid);
214295 p += writeCoord(p, &pCell->aCoord[ii]);
214321 RtreeCell *pCell /* The cell to be inserted */
214331 nodeOverwriteCell(pRtree, pNode, pCell, nCell);
214428 RtreeCell *pCell /* OUT: Write the cell contents here */
214433 pCell->iRowid = nodeGetRowid(pRtree, pNode, iCell);
214435 pCoord = pCell->aCoord;
215695 RtreeCell *pCell, /* Cell to insert into rtree */
215720 if( cellContains(pRtree, &cell, pCell) ){
215740 cellUnion(pRtree, &cell, pCell);
215770 RtreeCell *pCell /* This cell was just inserted */
215792 if( !cellContains(pRtree, &cell, pCell) ){
215793 cellUnion(pRtree, &cell, pCell);
215984 RtreeCell *pCell = &aCell[aaSorted[iBestDim][ii]];
215985 nodeInsertCell(pRtree, pTarget, pCell);
215986 cellUnion(pRtree, pBbox, pCell);
216021 RtreeCell *pCell,
216052 memcpy(&aCell[nCell], pCell, sizeof(RtreeCell));
216120 if( iRowid==pCell->iRowid ){
216136 rc = updateMapping(pRtree, pCell->iRowid, pLeft, iHeight);
216316 RtreeCell *pCell,
216321 RtreeNode *pChild = nodeHashLookup(pRtree, pCell->iRowid);
216328 if( nodeInsertCell(pRtree, pNode, pCell) ){
216329 rc = SplitNode(pRtree, pNode, pCell, iHeight);
216331 rc = AdjustTree(pRtree, pNode, pCell);
216334 rc = rowidWrite(pRtree, pCell->iRowid, pNode->iNode);
216336 rc = parentWrite(pRtree, pCell->iRowid, pNode->iNode);
217479 u8 *pCell, /* Pointer to cell coordinates */
217487 readCoord(&pCell[4*2*i], &c1);
217488 readCoord(&pCell[4*(2*i + 1)], &c2);
217558 u8 *pCell = &aNode[4 + i*(8 + pCheck->nDim*2*4)];
217559 i64 iVal = readInt64(pCell);
217560 rtreeCheckCellCoord(pCheck, iNode, i, &pCell[8], aParent);
217564 rtreeCheckNode(pCheck, iDepth-1, &pCell[8], iVal);
227170 StatCell *pCell = &p->aCell[i];
227175 pCell->iChildPg = sqlite3Get4byte(&aData[iOff]);
227191 pCell->nLocal = nLocal;
227200 pCell->nLastOvfl = (nPayload-nLocal) - (nOvfl-1) * (nUsable-4);
227201 pCell->nOvfl = nOvfl;
227202 pCell->aOvfl = sqlite3_malloc64(sizeof(u32)*nOvfl);
227203 if( pCell->aOvfl==0 ) return SQLITE_NOMEM_BKPT;
227204 pCell->aOvfl[0] = sqlite3Get4byte(&aData[iOff+nLocal]);
227207 u32 iPrev = pCell->aOvfl[j-1];
227214 pCell->aOvfl[j] = sqlite3Get4byte(sqlite3PagerGetData(pPg));
227336 StatCell *pCell = &p->aCell[p->iCell];
227337 while( pCell->iOvfl<pCell->nOvfl ){
227345 if( pCell->iOvfl<pCell->nOvfl-1 ){
227348 pCsr->nPayload += pCell->nLastOvfl;
227349 pCsr->nUnused += nUsable - 4 - pCell->nLastOvfl;
227351 iOvfl = pCell->iOvfl;
227352 pCell->iOvfl++;
227355 pCsr->iPageno = pCell->aOvfl[iOvfl];