Lines Matching defs:nBlock

16239 static void *memsys3Checkout(u32 i, u32 nBlock){
16243 assert( mem3.aPool[i-1].u.hdr.size4x/4==nBlock );
16244 assert( mem3.aPool[i+nBlock-1].u.hdr.prevSize==nBlock );
16246 mem3.aPool[i-1].u.hdr.size4x = nBlock*4 | 1 | (x&2);
16247 mem3.aPool[i+nBlock-1].u.hdr.prevSize = nBlock;
16248 mem3.aPool[i+nBlock-1].u.hdr.size4x |= 2;
16257 static void *memsys3FromMaster(u32 nBlock){
16259 assert( mem3.szMaster>=nBlock );
16260 if( nBlock>=mem3.szMaster-1 ){
16270 newi = mem3.iMaster + mem3.szMaster - nBlock;
16272 mem3.aPool[mem3.iMaster+mem3.szMaster-1].u.hdr.prevSize = nBlock;
16274 mem3.aPool[newi-1].u.hdr.size4x = nBlock*4 + 1;
16275 mem3.szMaster -= nBlock;
16343 u32 nBlock;
16349 nBlock = 2;
16351 nBlock = (nByte + 11)/8;
16353 assert( nBlock>=2 );
16360 if( nBlock <= MX_SMALL ){
16361 i = mem3.aiSmall[nBlock-2];
16363 memsys3UnlinkFromList(i, &mem3.aiSmall[nBlock-2]);
16364 return memsys3Checkout(i, nBlock);
16367 int hash = nBlock % N_HASH;
16369 if( mem3.aPool[i-1].u.hdr.size4x/4==nBlock ){
16371 return memsys3Checkout(i, nBlock);
16380 if( mem3.szMaster>=nBlock ){
16381 return memsys3FromMaster(nBlock);
16392 for(toFree=nBlock*16; toFree<(mem3.nPool*16); toFree *= 2){
16407 if( mem3.szMaster>=nBlock ){
16408 return memsys3FromMaster(nBlock);
16773 int nBlock; /* Number of szAtom sized blocks in zPool */
16825 assert( i>=0 && i<mem5.nBlock );
16848 assert( i>=0 && i<mem5.nBlock );
16855 assert( x<mem5.nBlock );
16882 assert( i>=0 && i<mem5.nBlock );
16989 assert( iBlock>=0 && iBlock<mem5.nBlock );
16995 assert( iBlock+size-1<(u32)mem5.nBlock );
17015 if( (iBuddy+(1<<iLogsize))>mem5.nBlock ) break;
17159 mem5.nBlock = (nByte / (mem5.szAtom+sizeof(u8)));
17161 mem5.aCtrl = (u8 *)&mem5.zPool[mem5.nBlock*mem5.szAtom];
17170 if( (iOffset+nAlloc)<=mem5.nBlock ){
17175 assert((iOffset+nAlloc)>mem5.nBlock);