Lines Matching refs:malloc
60 TEST(malloc, malloc_std) { in TEST() argument
62 void *ptr = malloc(100); in TEST()
68 TEST(malloc, malloc_overflow) { in TEST() argument
71 ASSERT_EQ(nullptr, malloc(SIZE_MAX)); in TEST()
75 TEST(malloc, calloc_std) { in TEST() argument
87 TEST(malloc, calloc_illegal) { in TEST() argument
94 TEST(malloc, calloc_overflow) { in TEST() argument
110 TEST(malloc, memalign_multiple) { in TEST() argument
125 TEST(malloc, memalign_overflow) { in TEST() argument
130 TEST(malloc, memalign_non_power2) { in TEST() argument
140 TEST(malloc, memalign_realloc) { in TEST() argument
176 TEST(malloc, malloc_realloc_larger) { in TEST() argument
178 char *ptr = (char *)malloc(100); in TEST()
192 TEST(malloc, malloc_realloc_smaller) { in TEST() argument
194 char *ptr = (char *)malloc(200); in TEST()
208 TEST(malloc, malloc_multiple_realloc) { in TEST() argument
210 char *ptr = (char *)malloc(200); in TEST()
246 TEST(malloc, calloc_realloc_larger) { in TEST() argument
261 TEST(malloc, calloc_realloc_smaller) { in TEST() argument
276 TEST(malloc, calloc_multiple_realloc) { in TEST() argument
313 TEST(malloc, realloc_overflow) { in TEST() argument
318 void* ptr = malloc(100); in TEST()
331 TEST(malloc, pvalloc_std) { in TEST() argument
344 TEST(malloc, pvalloc_overflow) { in TEST() argument
352 TEST(malloc, valloc_std) { in TEST() argument
364 TEST(malloc, valloc_overflow) { in TEST() argument
372 TEST(malloc, malloc_info) { in TEST() argument
439 TEST(malloc, malloc_info_matches_mallinfo) { in TEST() argument
507 TEST(malloc, calloc_usable_size) { in TEST() argument
509 void* pointer = malloc(size); in TEST()
526 TEST(malloc, malloc_0) { in TEST() argument
527 void* p = malloc(0); in TEST()
532 TEST(malloc, calloc_0_0) { in TEST() argument
538 TEST(malloc, calloc_0_1) { in TEST() argument
544 TEST(malloc, calloc_1_0) { in TEST() argument
550 TEST(malloc, realloc_nullptr_0) { in TEST() argument
557 TEST(malloc, realloc_0) { in TEST() argument
558 void* p = malloc(1024); in TEST()
568 TEST(malloc, verify_alignment) { in TEST() argument
577 filler[i] = malloc(1); in TEST()
580 values_32[i] = reinterpret_cast<uint32_t*>(malloc(sizeof(uint32_t))); in TEST()
591 filler[i] = malloc(1); in TEST()
594 values_64[i] = reinterpret_cast<uint64_t*>(malloc(sizeof(uint64_t))); in TEST()
605 filler[i] = malloc(1); in TEST()
608 values_ldouble[i] = reinterpret_cast<long double*>(malloc(sizeof(long double))); in TEST()
635 TEST(malloc, mallopt_smoke) { in TEST() argument
642 TEST(malloc, mallopt_decay) { in TEST() argument
655 TEST(malloc, mallopt_purge) { in TEST() argument
689 TEST(malloc, mallopt_scudo_only_options) { in TEST() argument
705 TEST(malloc, reallocarray_overflow) { in TEST() argument
723 TEST(malloc, reallocarray) { in TEST() argument
733 TEST(malloc, mallinfo) { in TEST() argument
752 ptrs[i] = malloc(size); in TEST()
809 types[i] = reinterpret_cast<Type*>(malloc(sizeof(Type))); in TestAllocateType()
835 ptrs[i] = malloc(alloc_size); in AndroidVerifyAlignment()
844 TEST(malloc, align_check) { in TEST() argument
892 TEST(malloc, DISABLED_alloc_after_fork) { in TEST() argument
908 void* ptr = malloc(size); in TEST()
926 void* ptr = malloc(size); in TEST()
1025 EXPECT_EXIT(CheckAllocationFunction([](size_t bytes) { return malloc(bytes) != nullptr; }), in TEST()
1039 void* p = malloc(1024 * 1024); in TEST()
1073 ptrs[i] = malloc(kAllocationSize); in GetMaxAllocations()
1089 ptrs[i] = malloc(kAllocationSize); in VerifyMaxPointers()
1094 ASSERT_TRUE(malloc(kAllocationSize) == nullptr); in VerifyMaxPointers()
1109 void* memory = malloc(10 * 1024 * 1024); in TEST()
1139 void* memory = malloc(80 * 1024 * 1024); in TEST()
1167 void* memory = malloc(60 * 1024 * 1024); in TEST()