Lines Matching refs:nullptr

38   SpaceTest() : byte_array_class_(nullptr) {  in SpaceTest()
52 auto null_loader(hs.NewHandle<mirror::ClassLoader>(nullptr)); in GetByteArrayClass()
53 if (byte_array_class_ == nullptr) { in GetByteArrayClass()
56 EXPECT_TRUE(byte_array_class != nullptr); in GetByteArrayClass()
58 EXPECT_TRUE(byte_array_class_ != nullptr); in GetByteArrayClass()
69 if (obj != nullptr) { in Alloc()
81 if (obj != nullptr) { in AllocWithGrowth()
91 EXPECT_TRUE(byte_array_class != nullptr); in InstallClass()
132 std::unique_ptr<Space> space(create_space("test", 16 * MB, 32 * MB, 32 * MB, nullptr)); in InitTestBody()
133 EXPECT_TRUE(space.get() != nullptr); in InitTestBody()
137 std::unique_ptr<Space> space(create_space("test", 16 * MB, 16 * MB, 16 * MB, nullptr)); in InitTestBody()
138 EXPECT_TRUE(space.get() != nullptr); in InitTestBody()
142 std::unique_ptr<Space> space(create_space("test", 32 * MB, 16 * MB, 16 * MB, nullptr)); in InitTestBody()
143 EXPECT_TRUE(space.get() == nullptr); in InitTestBody()
147 std::unique_ptr<Space> space(create_space("test", 16 * MB, 16 * MB, 32 * MB, nullptr)); in InitTestBody()
148 EXPECT_TRUE(space.get() != nullptr); in InitTestBody()
152 std::unique_ptr<Space> space(create_space("test", 16 * MB, 8 * MB, 32 * MB, nullptr)); in InitTestBody()
153 EXPECT_TRUE(space.get() == nullptr); in InitTestBody()
157 std::unique_ptr<Space> space(create_space("test", 8 * MB, 16 * MB, 32 * MB, nullptr)); in InitTestBody()
158 EXPECT_TRUE(space.get() != nullptr); in InitTestBody()
162 std::unique_ptr<Space> space(create_space("test", 8 * MB, 32 * MB, 16 * MB, nullptr)); in InitTestBody()
163 EXPECT_TRUE(space.get() == nullptr); in InitTestBody()
173 MallocSpace* space(create_space("test", 4 * MB, 16 * MB, 16 * MB, nullptr)); in ZygoteSpaceTestBody()
174 ASSERT_TRUE(space != nullptr); in ZygoteSpaceTestBody()
186 EXPECT_TRUE(ptr1.Get() != nullptr); in ZygoteSpaceTestBody()
192 mirror::Object* ptr2 = Alloc(space, self, 8 * MB, &dummy, nullptr); in ZygoteSpaceTestBody()
193 EXPECT_TRUE(ptr2 == nullptr); in ZygoteSpaceTestBody()
199 EXPECT_TRUE(ptr3.Get() != nullptr); in ZygoteSpaceTestBody()
205 mirror::Object* ptr4 = space->Alloc(self, 8 * MB, &dummy, nullptr); in ZygoteSpaceTestBody()
206 EXPECT_TRUE(ptr4 == nullptr); in ZygoteSpaceTestBody()
209 mirror::Object* ptr5 = space->AllocWithGrowth(self, 8 * MB, &dummy, nullptr); in ZygoteSpaceTestBody()
210 EXPECT_TRUE(ptr5 == nullptr); in ZygoteSpaceTestBody()
213 size_t free3 = space->AllocationSize(ptr3.Get(), nullptr); in ZygoteSpaceTestBody()
215 EXPECT_EQ(free3, space->Free(self, ptr3.Assign(nullptr))); in ZygoteSpaceTestBody()
222 EXPECT_TRUE(ptr6.Get() != nullptr); in ZygoteSpaceTestBody()
228 size_t free1 = space->AllocationSize(ptr1.Get(), nullptr); in ZygoteSpaceTestBody()
229 space->Free(self, ptr1.Assign(nullptr)); in ZygoteSpaceTestBody()
233 EXPECT_TRUE(space->Alloc(self, 1U * MB, &dummy, nullptr) != nullptr); in ZygoteSpaceTestBody()
251 EXPECT_TRUE(ptr1.Get() != nullptr); in ZygoteSpaceTestBody()
257 ptr2 = Alloc(space, self, 8 * MB, &dummy, nullptr); in ZygoteSpaceTestBody()
258 EXPECT_TRUE(ptr2 == nullptr); in ZygoteSpaceTestBody()
262 EXPECT_TRUE(ptr3.Get() != nullptr); in ZygoteSpaceTestBody()
266 space->Free(self, ptr3.Assign(nullptr)); in ZygoteSpaceTestBody()
269 free1 = space->AllocationSize(ptr1.Get(), nullptr); in ZygoteSpaceTestBody()
270 space->Free(self, ptr1.Assign(nullptr)); in ZygoteSpaceTestBody()
276 MallocSpace* space(create_space("test", 4 * MB, 16 * MB, 16 * MB, nullptr)); in AllocAndFreeTestBody()
277 ASSERT_TRUE(space != nullptr); in AllocAndFreeTestBody()
289 EXPECT_TRUE(ptr1.Get() != nullptr); in AllocAndFreeTestBody()
295 mirror::Object* ptr2 = Alloc(space, self, 8 * MB, &dummy, nullptr); in AllocAndFreeTestBody()
296 EXPECT_TRUE(ptr2 == nullptr); in AllocAndFreeTestBody()
302 EXPECT_TRUE(ptr3.Get() != nullptr); in AllocAndFreeTestBody()
308 mirror::Object* ptr4 = Alloc(space, self, 8 * MB, &dummy, nullptr); in AllocAndFreeTestBody()
309 EXPECT_TRUE(ptr4 == nullptr); in AllocAndFreeTestBody()
312 mirror::Object* ptr5 = AllocWithGrowth(space, self, 8 * MB, &dummy, nullptr); in AllocAndFreeTestBody()
313 EXPECT_TRUE(ptr5 == nullptr); in AllocAndFreeTestBody()
316 size_t free3 = space->AllocationSize(ptr3.Get(), nullptr); in AllocAndFreeTestBody()
318 space->Free(self, ptr3.Assign(nullptr)); in AllocAndFreeTestBody()
325 EXPECT_TRUE(ptr6.Get() != nullptr); in AllocAndFreeTestBody()
331 size_t free1 = space->AllocationSize(ptr1.Get(), nullptr); in AllocAndFreeTestBody()
332 space->Free(self, ptr1.Assign(nullptr)); in AllocAndFreeTestBody()
337 MallocSpace* space(create_space("test", 4 * MB, 16 * MB, 16 * MB, nullptr)); in AllocAndFreeListTestBody()
338 ASSERT_TRUE(space != nullptr); in AllocAndFreeListTestBody()
352 EXPECT_TRUE(lots_of_objects[i] != nullptr); in AllocAndFreeListTestBody()
365 EXPECT_TRUE(lots_of_objects[i] != nullptr); in AllocAndFreeListTestBody()
423 auto object(hs.NewHandle<mirror::Object>(nullptr)); in SizeFootPrintGrowthLimitAndTrimBody()
426 object.Assign(Alloc(space, self, alloc_size, &bytes_allocated, nullptr)); in SizeFootPrintGrowthLimitAndTrimBody()
428 object.Assign(AllocWithGrowth(space, self, alloc_size, &bytes_allocated, nullptr)); in SizeFootPrintGrowthLimitAndTrimBody()
432 if (object.Get() != nullptr) { // allocation succeeded in SizeFootPrintGrowthLimitAndTrimBody()
434 size_t allocation_size = space->AllocationSize(object.Get(), nullptr); in SizeFootPrintGrowthLimitAndTrimBody()
486 if (object == nullptr) { in SizeFootPrintGrowthLimitAndTrimBody()
489 size_t allocation_size = space->AllocationSize(object, nullptr); in SizeFootPrintGrowthLimitAndTrimBody()
496 lots_of_objects.get()[i] = nullptr; in SizeFootPrintGrowthLimitAndTrimBody()
515 auto large_object(hs.NewHandle<mirror::Object>(nullptr)); in SizeFootPrintGrowthLimitAndTrimBody()
519 large_object.Assign(Alloc(space, self, three_quarters_space, &bytes_allocated, nullptr)); in SizeFootPrintGrowthLimitAndTrimBody()
522 nullptr)); in SizeFootPrintGrowthLimitAndTrimBody()
524 EXPECT_TRUE(large_object.Get() != nullptr); in SizeFootPrintGrowthLimitAndTrimBody()
533 space->Free(self, large_object.Assign(nullptr)); in SizeFootPrintGrowthLimitAndTrimBody()
550 MallocSpace* space(create_space("test", initial_size, growth_limit, capacity, nullptr)); in SizeFootPrintGrowthLimitAndTrimDriver()
551 ASSERT_TRUE(space != nullptr); in SizeFootPrintGrowthLimitAndTrimDriver()