Lines Matching refs:sz

8803 SQLITE_PRIVATE void sqlite3PCacheBufferSetup(void *, int sz, int n);
9359 u16 sz; /* Size of each buffer in bytes */ member
18175 int i, n, sz; in sqlite3MallocInit() local
18177 sz = ROUNDDOWN8(sqlite3GlobalConfig.szScratch); in sqlite3MallocInit()
18178 sqlite3GlobalConfig.szScratch = sz; in sqlite3MallocInit()
18184 pSlot->pNext = (ScratchFreeslot*)(sz+(char*)pSlot); in sqlite3MallocInit()
18462 return db->lookaside.sz; in sqlite3DbMallocSize()
18630 if( n>db->lookaside.sz ){ in sqlite3DbMallocRaw()
18672 if( n<=db->lookaside.sz ){ in sqlite3DbRealloc()
18677 memcpy(pNew, p, db->lookaside.sz); in sqlite3DbRealloc()
21693 int i, sz; in sqlite3FileSuffix3() local
21694 sz = sqlite3Strlen30(z); in sqlite3FileSuffix3()
21695 for(i=sz-1; i>0 && z[i]!='/' && z[i]!='.'; i--){} in sqlite3FileSuffix3()
21696 if( z[i]=='.' && ALWAYS(sz>i+4) ) memcpy(&z[i+1], &z[sz-3], 4); in sqlite3FileSuffix3()
22910 sqlite3_int64 sz = *(sqlite3_int64*)pArg;
22912 os2Truncate(id, sz);
25068 static int robust_ftruncate(int h, sqlite3_int64 sz){
25070 do{ rc = osFtruncate(h,sz); }while( rc<0 && errno==EINTR );
32715 sqlite3_int64 sz = *(sqlite3_int64*)pArg;
32717 winTruncate(id, sz);
33288 sqlite3_int64 sz; /* Current size of wal-index file */
33296 rc = winFileSize((sqlite3_file *)&pShmNode->hFile, &sz);
33302 if( sz<nByte ){
34606 SQLITE_PRIVATE int sqlite3BitvecBuiltinTest(int sz, int *aOp){
34615 pBitvec = sqlite3BitvecCreate( sz );
34616 pV = sqlite3_malloc( (sz+7)/8 + 1 );
34619 memset(pV, 0, (sz+7)/8 + 1);
34647 i = (i & 0x7fffffff)%sz;
34664 rc = sqlite3BitvecTest(0,0) + sqlite3BitvecTest(pBitvec, sz+1)
34666 + (sqlite3BitvecSize(pBitvec) - sz);
34667 for(i=1; i<=sz; i++){
35458 SQLITE_PRIVATE void sqlite3PCacheBufferSetup(void *pBuf, int sz, int n){
35461 sz = ROUNDDOWN8(sz);
35462 pcache1.szSlot = sz;
35472 pBuf = (void*)&((char*)pBuf)[sz];
35509 int sz = sqlite3MallocSize(p);
35511 sqlite3StatusAdd(SQLITE_STATUS_PAGECACHE_OVERFLOW, sz);
35605 SQLITE_PRIVATE void *sqlite3PageMalloc(int sz){
35606 return pcache1Alloc(sz);
35828 int sz; /* Bytes of memory required to allocate the new cache */
35848 sz = sizeof(PCache1) + sizeof(PGroup)*separateCache;
35849 pCache = (PCache1 *)sqlite3_malloc(sz);
35851 memset(pCache, 0, sz);
38108 i64 sz;
38109 rc = sqlite3OsFileSize(pPager->jfd, &sz);
38110 if( rc==SQLITE_OK && sz>iLimit ){
45968 int sz;
45970 sz = pWal->hdr.szPage;
45971 sz = (pWal->hdr.szPage&0xfe00) + ((pWal->hdr.szPage&0x0001)<<16);
45972 testcase( sz<=32768 );
45973 testcase( sz>=65536 );
45974 iOffset = walFrameOffset(iRead, sz) + WAL_FRAME_HDRSIZE;
46187 i64 sz;
46190 rx = sqlite3OsFileSize(pWal->pWalFd, &sz);
46191 if( rx==SQLITE_OK && (sz > pWal->mxWalSize) ){
48944 int sz; /* Size of a cell */
48954 sz = cellSizePtr(pPage, &data[pc]);
48955 testcase( pc+sz==usableSize );
48956 if( pc+sz>usableSize ){
52909 static void dropCell(MemPage *pPage, int idx, int sz, int *pRC){
52920 assert( sz==cellSize(pPage, idx) );
52928 testcase( pc+sz==pPage->pBt->usableSize );
52929 if( pc < (u32)get2byte(&data[hdr+5]) || pc+sz > pPage->pBt->usableSize ){
52933 rc = freeSpace(pPage, pc, sz);
52970 int sz, /* Bytes of content in pCell */
52997 assert( sz==cellSizePtr(pPage, pCell) || (sz==8 && iChild>0) );
52998 if( pPage->nOverflow || sz+2>pPage->nFree ){
53000 memcpy(pTemp+nSkip, pCell+nSkip, sz-nSkip);
53021 rc = allocateSpace(pPage, sz, &idx);
53026 assert( idx+sz <= (int)pPage->pBt->usableSize );
53028 pPage->nFree -= (u16)(2 + sz);
53029 memcpy(&data[idx+nSkip], pCell+nSkip, sz-nSkip);
53083 u16 sz = aSize[i];
53085 cellbody -= sz;
53087 memcpy(&data[cellbody], apCell[i], sz);
53560 u16 sz = (u16)szNew[i];
53563 szCell[nCell] = sz;
53565 iSpace1 += sz;
53566 assert( sz<=pBt->maxLocal+23 );
53568 memcpy(pTemp, apDiv[i], sz);
53771 int sz;
53775 sz = szCell[j] + leafCorrection;
53789 sz = 4 + putVarint(&pCell[4], info.nKey);
53806 sz = cellSizePtr(pParent, pCell);
53809 iOvflSpace += sz;
53810 assert( sz<=pBt->maxLocal+23 );
53812 insertCell(pParent, nxDiv, pCell, sz, pTemp, pNew->pgno, &rc);
55164 u32 sz;
55173 sz = info.nData;
55174 if( !pPage->intKey ) sz += (int)info.nKey;
55185 assert( sz==info.nPayload );
55186 if( (sz>info.nLocal)
55189 int nPage = (sz - info.nLocal + usableSize - 5)/(usableSize - 4);
76476 static const int sz = sizeof(IndexSample)*SQLITE_INDEX_SAMPLES;
76477 pIdx->aSample = (IndexSample *)sqlite3DbMallocRaw(0, sz);
76482 memset(pIdx->aSample, 0, sz);
108376 static int setupLookaside(sqlite3 *db, void *pBuf, int sz, int cnt){
108391 if( sz<=(int)sizeof(LookasideSlot*) ) sz = 0;
108393 if( sz==0 || cnt==0 ){
108394 sz = 0;
108397 sz = ROUNDDOWN8(sz); /* IMP: R-33038-09382 */
108399 pStart = sqlite3Malloc( sz*cnt ); /* IMP: R-61949-35727 */
108402 sz = ROUNDDOWN8(sz); /* IMP: R-33038-09382 */
108407 db->lookaside.sz = (u16)sz;
108411 assert( sz > (int)sizeof(LookasideSlot*) );
108416 p = (LookasideSlot*)&((u8*)p)[sz];
108446 int sz = va_arg(ap, int); /* IMP: R-47871-25994 */
108448 rc = setupLookaside(db, pBuf, sz, cnt);
110658 int sz = va_arg(ap, int);
110660 rc = sqlite3BitvecBuiltinTest(sz, aProg);
110819 int sz;
110820 sz = va_arg(ap, int);
110823 if( sz ) *ppNew = sqlite3ScratchMalloc(sz);