Lines Matching refs:sz

85     explicit AllocInfo(int sz) : p((int*)scalable_malloc(sz*sizeof(int))),  in AllocInfo()  argument
86 val(rand()), size(sz) { in AllocInfo()
187 size_t sz; member
198 blocks1[i].sz = rand() % minLargeObjectSize; in operator ()()
199 blocks1[i].ptr = StartupBlock::allocate(blocks1[i].sz); in operator ()()
200 REQUIRE((blocks1[i].ptr && StartupBlock::msize(blocks1[i].ptr)>=blocks1[i].sz in operator ()()
202 memset(blocks1[i].ptr, i, blocks1[i].sz); in operator ()()
205 blocks2[i].sz = rand() % minLargeObjectSize; in operator ()()
206 blocks2[i].ptr = StartupBlock::allocate(blocks2[i].sz); in operator ()()
207 REQUIRE((blocks2[i].ptr && StartupBlock::msize(blocks2[i].ptr)>=blocks2[i].sz in operator ()()
209 memset(blocks2[i].ptr, i, blocks2[i].sz); in operator ()()
211 for (size_t j=0; j<blocks1[i].sz; j++) in operator ()()
217 for (size_t j=0; j<blocks2[i].sz; j++) in operator ()()
426 for (size_t sz=minLargeObjectSize; sz<1*1024*1024; in operator ()() local
427 sz+=LargeObjectCache::LargeBSProps::CacheStep) { in operator ()()
428 void *ptr = pool_malloc(my_mallocPool, sz); in operator ()()
430 memset(ptr, sz, sz); in operator ()()
1232 for (size_t sz = min_sz; sz <= 64; sz *= 2) { in TestSlabAlignment() local
1233 for (size_t i = 0; i < space/sz; i++) { in TestSlabAlignment()
1234 pointers[i] = scalable_malloc(sz); in TestSlabAlignment()
1241 for (size_t i = 0; i < space/sz; i++) in TestSlabAlignment()
1636 size_t sz = LargeObjectCache::maxHugeSize; in TestHugeSizeThreshold() local
1637 size_t aligned_sz = LargeObjectCache::alignToBin(sz); in TestHugeSizeThreshold()
1638 REQUIRE_MESSAGE(sz == aligned_sz, "maxHugeSize should be aligned."); in TestHugeSizeThreshold()
1639 REQUIRE_MESSAGE(!loc->sizeInCacheRange(sz), "Upper bound sized object shouldn't be cached."); in TestHugeSizeThreshold()
1640 REQUIRE_MESSAGE(loc->get(sz) == nullptr, "Upper bound sized object shouldn't be cached."); in TestHugeSizeThreshold()