• Home
  • Raw
  • Download

Lines Matching refs:Alloc

19   BumpPtrAllocator Alloc;  in TEST()  local
20 int *a = (int*)Alloc.Allocate(sizeof(int), 0); in TEST()
21 int *b = (int*)Alloc.Allocate(sizeof(int) * 10, 0); in TEST()
22 int *c = (int*)Alloc.Allocate(sizeof(int), 0); in TEST()
31 EXPECT_EQ(1U, Alloc.GetNumSlabs()); in TEST()
33 BumpPtrAllocator Alloc2 = std::move(Alloc); in TEST()
34 EXPECT_EQ(0U, Alloc.GetNumSlabs()); in TEST()
44 Alloc = std::move(Alloc2); in TEST()
46 EXPECT_EQ(1U, Alloc.GetNumSlabs()); in TEST()
51 BumpPtrAllocator Alloc; in TEST() local
52 Alloc.Allocate(3000, 0); in TEST()
53 EXPECT_EQ(1U, Alloc.GetNumSlabs()); in TEST()
54 Alloc.Allocate(3000, 0); in TEST()
55 EXPECT_EQ(2U, Alloc.GetNumSlabs()); in TEST()
56 Alloc.Allocate(3000, 0); in TEST()
57 EXPECT_EQ(3U, Alloc.GetNumSlabs()); in TEST()
63 BumpPtrAllocator Alloc; in TEST() local
64 Alloc.Allocate(3000, 0); in TEST()
65 EXPECT_EQ(1U, Alloc.GetNumSlabs()); in TEST()
66 Alloc.Allocate(3000, 0); in TEST()
67 EXPECT_EQ(2U, Alloc.GetNumSlabs()); in TEST()
68 Alloc.Reset(); in TEST()
69 EXPECT_EQ(1U, Alloc.GetNumSlabs()); in TEST()
70 Alloc.Allocate(3000, 0); in TEST()
71 EXPECT_EQ(1U, Alloc.GetNumSlabs()); in TEST()
72 Alloc.Allocate(3000, 0); in TEST()
73 EXPECT_EQ(2U, Alloc.GetNumSlabs()); in TEST()
78 BumpPtrAllocator Alloc; in TEST() local
80 a = (uintptr_t)Alloc.Allocate(1, 2); in TEST()
82 a = (uintptr_t)Alloc.Allocate(1, 4); in TEST()
84 a = (uintptr_t)Alloc.Allocate(1, 8); in TEST()
86 a = (uintptr_t)Alloc.Allocate(1, 16); in TEST()
88 a = (uintptr_t)Alloc.Allocate(1, 32); in TEST()
90 a = (uintptr_t)Alloc.Allocate(1, 64); in TEST()
92 a = (uintptr_t)Alloc.Allocate(1, 128); in TEST()
99 BumpPtrAllocator Alloc; in TEST() local
102 Alloc.Allocate(4096, 0); in TEST()
103 EXPECT_EQ(1U, Alloc.GetNumSlabs()); in TEST()
106 Alloc.Allocate(1, 0); in TEST()
107 EXPECT_EQ(2U, Alloc.GetNumSlabs()); in TEST()
112 BumpPtrAllocator Alloc; in TEST() local
114 Alloc.Allocate(8000, 0); in TEST()
115 EXPECT_EQ(2U, Alloc.GetNumSlabs()); in TEST()
155 BumpPtrAllocatorImpl<MockSlabAllocator> Alloc; in TEST() local
158 (void)Alloc.Allocate(1, 0); in TEST()
161 (void)Alloc.Allocate(3000, 2048); in TEST()