Home
last modified time | relevance | path

Searched refs:allocator (Results 1 – 25 of 183) sorted by relevance

12345678

/art/libartbase/base/
Darena_allocator_test.cc28 size_t NumberOfArenas(ArenaAllocator* allocator) { in NumberOfArenas() argument
30 for (Arena* a = allocator->arena_head_; a != nullptr; a = a->next_) { in NumberOfArenas()
39 ArenaAllocator allocator(&pool); in TEST_F() local
40 ArenaBitVector bv(&allocator, 10, true); in TEST_F()
55 ArenaAllocator allocator(&pool); in TEST_F() local
56 small_array = allocator.AllocArray<uint32_t>(kSmallArraySize); in TEST_F()
61 ArenaAllocator allocator(&pool); in TEST_F() local
62 uint32_t* large_array = allocator.AllocArray<uint32_t>(kLargeArraySize); in TEST_F()
77 ArenaAllocator allocator(&pool); in TEST_F() local
79 void* alloc1 = allocator.Alloc(arena_allocator::kArenaDefaultSize * 5 / 8); in TEST_F()
[all …]
Darena_object.h33 void* operator new(size_t size, ArenaAllocator* allocator) {
34 return allocator->Alloc(size, kAllocKind);
37 static void* operator new(size_t size, ScopedArenaAllocator* allocator) {
38 return allocator->Alloc(size, kAllocKind);
57 void* operator new(size_t size, ArenaAllocator* allocator) {
58 return allocator->Alloc(size, kAllocKind);
61 static void* operator new(size_t size, ScopedArenaAllocator* allocator) {
62 return allocator->Alloc(size, kAllocKind);
Darena_bit_vector.cc55 static ArenaBitVectorAllocator* Create(ArenaAlloc* allocator, ArenaAllocKind kind) { in Create() argument
56 void* storage = allocator->template Alloc<ArenaBitVectorAllocator>(kind); in Create()
57 return new (storage) ArenaBitVectorAllocator(allocator, kind); in Create()
72 ArenaBitVectorAllocator(ArenaAlloc* allocator, ArenaAllocKind kind) in ArenaBitVectorAllocator() argument
73 : ArenaBitVectorAllocatorKind(kind), allocator_(allocator) { } in ArenaBitVectorAllocator()
80 ArenaBitVector::ArenaBitVector(ArenaAllocator* allocator, in ArenaBitVector() argument
86 ArenaBitVectorAllocator<ArenaAllocator>::Create(allocator, kind)) { in ArenaBitVector()
89 ArenaBitVector::ArenaBitVector(ScopedArenaAllocator* allocator, in ArenaBitVector() argument
95 ArenaBitVectorAllocator<ScopedArenaAllocator>::Create(allocator, kind)) { in ArenaBitVector()
Darena_bit_vector.h35 static ArenaBitVector* Create(Allocator* allocator,
39 void* storage = allocator->template Alloc<ArenaBitVector>(kind);
40 return new (storage) ArenaBitVector(allocator, start_bits, expandable, kind);
43 ArenaBitVector(ArenaAllocator* allocator,
47 ArenaBitVector(ScopedArenaAllocator* allocator,
71 ArenaBitVectorArray(ArenaAllocator* allocator,
77 data_(ArenaBitVector(allocator, in BaseBitVectorArray()
82 ArenaBitVectorArray(ScopedArenaAllocator* allocator,
88 data_(ArenaBitVector(allocator, in BaseBitVectorArray()
Dbit_table_test.cc32 ScopedArenaAllocator allocator(&arena_stack); in TEST() local
36 BitTableBuilderBase<1> builder(&allocator); in TEST()
48 ScopedArenaAllocator allocator(&arena_stack); in TEST() local
53 BitTableBuilderBase<1> builder(&allocator); in TEST()
74 ScopedArenaAllocator allocator(&arena_stack); in TEST() local
79 BitTableBuilderBase<1> builder(&allocator); in TEST()
94 ScopedArenaAllocator allocator(&arena_stack); in TEST() local
99 BitTableBuilderBase<4> builder(&allocator); in TEST()
125 ScopedArenaAllocator allocator(&arena_stack); in TEST() local
127 BitTableBuilderBase<2> builder(&allocator); in TEST()
[all …]
Dallocator.h106 class TrackingAllocatorImpl : public std::allocator<T> {
108 using value_type = typename std::allocator<T>::value_type;
109 using size_type = typename std::allocator<T>::size_type;
110 using difference_type = typename std::allocator<T>::difference_type;
111 using pointer = typename std::allocator<T>::pointer;
112 using const_pointer = typename std::allocator<T>::const_pointer;
113 using reference = typename std::allocator<T>::reference;
114 using const_reference = typename std::allocator<T>::const_reference;
154 std::allocator<T>>;
/art/compiler/utils/
Djni_macro_assembler.cc44 ArenaAllocator* allocator, in Create() argument
54 return MacroAsm32UniquePtr(new (allocator) arm::ArmVIXLJNIMacroAssembler(allocator)); in Create()
58 return MacroAsm32UniquePtr(new (allocator) x86::X86JNIMacroAssembler(allocator)); in Create()
61 UNUSED(allocator); in Create()
71 ArenaAllocator* allocator, in Create() argument
80 return MacroAsm64UniquePtr(new (allocator) arm64::Arm64JNIMacroAssembler(allocator)); in Create()
84 return MacroAsm64UniquePtr(new (allocator) x86_64::X86_64JNIMacroAssembler(allocator)); in Create()
87 UNUSED(allocator); in Create()
/art/compiler/optimizing/
Dparallel_move_test.cc57 explicit TestParallelMoveResolverWithSwap(ArenaAllocator* allocator) in TestParallelMoveResolverWithSwap() argument
58 : ParallelMoveResolverWithSwap(allocator) {} in TestParallelMoveResolverWithSwap()
100 explicit TestParallelMoveResolverNoSwap(ArenaAllocator* allocator) in TestParallelMoveResolverNoSwap() argument
101 : ParallelMoveResolverNoSwap(allocator), scratch_index_(kScratchRegisterStartIndexForTest) {} in TestParallelMoveResolverNoSwap()
155 static HParallelMove* BuildParallelMove(ArenaAllocator* allocator, in BuildParallelMove() argument
158 HParallelMove* moves = new (allocator) HParallelMove(allocator); in BuildParallelMove()
186 ArenaAllocator allocator(&pool); in TYPED_TEST() local
189 TypeParam resolver(&allocator); in TYPED_TEST()
191 resolver.EmitNativeCode(BuildParallelMove(&allocator, moves, arraysize(moves))); in TYPED_TEST()
200 TypeParam resolver(&allocator); in TYPED_TEST()
[all …]
Dlive_interval_test.cc28 ScopedArenaAllocator* allocator = pool.GetScopedAllocator(); in TEST() local
32 LiveInterval* interval = BuildInterval(ranges, arraysize(ranges), allocator); in TEST()
38 LiveInterval* interval = BuildInterval(ranges, arraysize(ranges), allocator); in TEST()
45 ScopedArenaAllocator* allocator = pool.GetScopedAllocator(); in TEST() local
49 LiveInterval* interval = BuildInterval(ranges, arraysize(ranges), allocator); in TEST()
59 LiveInterval* interval = BuildInterval(ranges, arraysize(ranges), allocator); in TEST()
73 ScopedArenaAllocator* allocator = pool.GetScopedAllocator(); in TEST() local
77 LiveInterval* interval = BuildInterval(ranges, arraysize(ranges), allocator); in TEST()
87 LiveInterval* interval = BuildInterval(ranges, arraysize(ranges), allocator); in TEST()
101 ScopedArenaAllocator* allocator = pool.GetScopedAllocator(); in TEST() local
[all …]
Dstack_map_stream.h42 explicit StackMapStream(ScopedArenaAllocator* allocator, InstructionSet instruction_set) in StackMapStream() argument
43 : allocator_(allocator), in StackMapStream()
45 stack_maps_(allocator), in StackMapStream()
46 register_masks_(allocator), in StackMapStream()
47 stack_masks_(allocator), in StackMapStream()
48 inline_infos_(allocator), in StackMapStream()
49 method_infos_(allocator), in StackMapStream()
50 dex_register_masks_(allocator), in StackMapStream()
51 dex_register_maps_(allocator), in StackMapStream()
52 dex_register_catalog_(allocator), in StackMapStream()
[all …]
Doptimization.cc171 ArenaAllocator* allocator, in ConstructOptimizations() argument
176 ArenaVector<HOptimization*> optimizations(allocator->Adapter()); in ConstructOptimizations()
198 opt = most_recent_side_effects = new (allocator) SideEffectsAnalysis(graph, pass_name); in ConstructOptimizations()
202 new (allocator) HInductionVarAnalysis(graph, stats, pass_name); in ConstructOptimizations()
209 opt = new (allocator) GVNOptimization(graph, *most_recent_side_effects, pass_name); in ConstructOptimizations()
213 opt = new (allocator) LICM(graph, *most_recent_side_effects, stats, pass_name); in ConstructOptimizations()
217 opt = new (allocator) HLoopOptimization( in ConstructOptimizations()
222 opt = new (allocator) BoundsCheckElimination( in ConstructOptimizations()
229 opt = new (allocator) HConstantFolding(graph, stats, pass_name); in ConstructOptimizations()
232 opt = new (allocator) in ConstructOptimizations()
[all …]
Dnodes_vector.h75 ArenaAllocator* allocator, in HVecOperation() argument
85 allocator, in HVecOperation()
269 ArenaAllocator* allocator, in HVecUnaryOperation() argument
275 allocator, in HVecUnaryOperation()
296 ArenaAllocator* allocator, in HVecBinaryOperation() argument
303 allocator, in HVecBinaryOperation()
327 ArenaAllocator* allocator, in HVecMemoryOperation() argument
334 allocator, in HVecMemoryOperation()
388 HVecReplicateScalar(ArenaAllocator* allocator, in HVecReplicateScalar() argument
394 kVecReplicateScalar, allocator, scalar, packed_type, vector_length, dex_pc) { in HVecReplicateScalar()
[all …]
Dbounds_check_elimination_test.cc360 ArenaAllocator* allocator, in BuildSSAGraph1() argument
364 HBasicBlock* entry = new (allocator) HBasicBlock(graph); in BuildSSAGraph1()
367 HInstruction* parameter = new (allocator) HParameterValue( in BuildSSAGraph1()
375 HBasicBlock* block = new (allocator) HBasicBlock(graph); in BuildSSAGraph1()
378 block->AddInstruction(new (allocator) HGoto()); in BuildSSAGraph1()
380 HBasicBlock* loop_header = new (allocator) HBasicBlock(graph); in BuildSSAGraph1()
381 HBasicBlock* loop_body = new (allocator) HBasicBlock(graph); in BuildSSAGraph1()
382 HBasicBlock* exit = new (allocator) HBasicBlock(graph); in BuildSSAGraph1()
392 HPhi* phi = new (allocator) HPhi(allocator, 0, 0, DataType::Type::kInt32); in BuildSSAGraph1()
393 HInstruction* null_check = new (allocator) HNullCheck(parameter, 0); in BuildSSAGraph1()
[all …]
Dparallel_move_resolver.h35 explicit ParallelMoveResolver(ArenaAllocator* allocator) in ParallelMoveResolver() argument
36 : moves_(allocator->Adapter(kArenaAllocParallelMoveResolver)) { in ParallelMoveResolver()
57 explicit ParallelMoveResolverWithSwap(ArenaAllocator* allocator) in ParallelMoveResolverWithSwap() argument
58 : ParallelMoveResolver(allocator) {} in ParallelMoveResolverWithSwap()
126 explicit ParallelMoveResolverNoSwap(ArenaAllocator* allocator) in ParallelMoveResolverNoSwap() argument
127 : ParallelMoveResolver(allocator), in ParallelMoveResolverNoSwap()
128 scratches_(allocator->Adapter(kArenaAllocParallelMoveResolver)), in ParallelMoveResolverNoSwap()
129 pending_moves_(allocator->Adapter(kArenaAllocParallelMoveResolver)), in ParallelMoveResolverNoSwap()
130 allocator_(allocator) { in ParallelMoveResolverNoSwap()
Dregister_allocator.cc32 RegisterAllocator::RegisterAllocator(ScopedArenaAllocator* allocator, in RegisterAllocator() argument
35 : allocator_(allocator), in RegisterAllocator()
39 std::unique_ptr<RegisterAllocator> RegisterAllocator::Create(ScopedArenaAllocator* allocator, in Create() argument
46 new (allocator) RegisterAllocatorLinearScan(allocator, codegen, analysis)); in Create()
49 new (allocator) RegisterAllocatorGraphColor(allocator, codegen, analysis)); in Create()
107 ScopedArenaAllocator allocator(codegen.GetGraph()->GetArenaStack()); in ValidateIntervals() local
109 allocator.Adapter(kArenaAllocRegisterAllocatorValidate)); in ValidateIntervals()
123 ArenaBitVector::Create(&allocator, max_end, false, kArenaAllocRegisterAllocatorValidate)); in ValidateIntervals()
Dinstruction_simplifier_shared.cc78 ArenaAllocator* allocator = mul->GetBlock()->GetGraph()->GetAllocator(); in TrySimpleMultiplyAccumulatePatterns() local
79 HMultiplyAccumulate* mulacc = new (allocator) HMultiplyAccumulate( in TrySimpleMultiplyAccumulatePatterns()
108 ArenaAllocator* allocator = mul->GetBlock()->GetGraph()->GetAllocator(); in TryCombineMultiplyAccumulate() local
140 new (allocator) HMultiplyAccumulate(type, in TryCombineMultiplyAccumulate()
153 new (allocator) HMultiplyAccumulate(type, in TryCombineMultiplyAccumulate()
258 ArenaAllocator* allocator = graph->GetAllocator(); in TryExtractArrayAccessAddress() local
261 HIntermediateAddress* address = new (allocator) HIntermediateAddress(array, offset, kNoDexPc); in TryExtractArrayAccessAddress()
292 ArenaAllocator* allocator = graph->GetAllocator(); in TryExtractVecArrayAccessAddress() local
331 new (allocator) HIntermediateAddressIndex(index, offset, shift, kNoDexPc); in TryExtractVecArrayAccessAddress()
342 ArenaAllocator* allocator = basic_block->GetGraph()->GetAllocator(); in TryReplaceSubSubWithSubAdd() local
[all …]
Dssa_phi_elimination.cc34 ScopedArenaAllocator allocator(graph_->GetArenaStack()); in MarkDeadPhis() local
37 ScopedArenaVector<HPhi*> worklist(allocator.Adapter(kArenaAllocSsaPhiElimination)); in MarkDeadPhis()
43 ScopedArenaSet<HPhi*> initially_live(allocator.Adapter(kArenaAllocSsaPhiElimination)); in MarkDeadPhis()
128 ScopedArenaAllocator allocator(graph_->GetArenaStack()); in Run() local
131 ScopedArenaVector<HPhi*> worklist(allocator.Adapter(kArenaAllocSsaPhiElimination)); in Run()
142 ArenaBitVector visited_phis_in_cycle(&allocator, in Run()
147 ScopedArenaVector<HPhi*> cycle_worklist(allocator.Adapter(kArenaAllocSsaPhiElimination)); in Run()
/art/tools/cpp-define-generator/
Drosalloc.def18 #include "gc/allocator/rosalloc.h"
22 art::gc::allocator::RosAlloc::kThreadLocalBracketQuantumSize - 1)
24 ~static_cast<uint32_t>(art::gc::allocator::RosAlloc::kThreadLocalBracketQuantumSize - 1))
26 ~static_cast<uint64_t>(art::gc::allocator::RosAlloc::kThreadLocalBracketQuantumSize - 1))
28 art::gc::allocator::RosAlloc::kThreadLocalBracketQuantumSizeShift)
30 art::gc::allocator::RosAlloc::kMaxThreadLocalBracketSize)
32 art::gc::allocator::RosAlloc::RunFreeListHeadOffset())
34 art::gc::allocator::RosAlloc::RunFreeListOffset())
36 art::gc::allocator::RosAlloc::RunFreeListSizeOffset())
38 art::gc::allocator::RosAlloc::RunSlotNextOffset())
/art/test/404-optimizing-allocator/
DAndroid.bp3 // Build rules for ART run-test `404-optimizing-allocator`.
16 name: "art-run-test-404-optimizing-allocator",
21 ":art-run-test-404-optimizing-allocator-expected-stdout",
22 ":art-run-test-404-optimizing-allocator-expected-stderr",
28 name: "art-run-test-404-optimizing-allocator-expected-stdout",
29 out: ["art-run-test-404-optimizing-allocator-expected-stdout.txt"],
36 name: "art-run-test-404-optimizing-allocator-expected-stderr",
37 out: ["art-run-test-404-optimizing-allocator-expected-stderr.txt"],
/art/test/405-optimizing-long-allocator/
DAndroid.bp3 // Build rules for ART run-test `405-optimizing-long-allocator`.
16 name: "art-run-test-405-optimizing-long-allocator",
21 ":art-run-test-405-optimizing-long-allocator-expected-stdout",
22 ":art-run-test-405-optimizing-long-allocator-expected-stderr",
28 name: "art-run-test-405-optimizing-long-allocator-expected-stdout",
29 out: ["art-run-test-405-optimizing-long-allocator-expected-stdout.txt"],
36 name: "art-run-test-405-optimizing-long-allocator-expected-stderr",
37 out: ["art-run-test-405-optimizing-long-allocator-expected-stderr.txt"],
/art/compiler/trampolines/
Dtrampoline_compiler.cc53 ArenaAllocator* allocator, EntryPointCallingConvention abi, ThreadOffset32 offset) { in CreateTrampoline() argument
57 ArmVIXLAssembler assembler(allocator); in CreateTrampoline()
94 ArenaAllocator* allocator, EntryPointCallingConvention abi, ThreadOffset64 offset) { in CreateTrampoline() argument
95 Arm64Assembler assembler(allocator); in CreateTrampoline()
132 static std::unique_ptr<const std::vector<uint8_t>> CreateTrampoline(ArenaAllocator* allocator, in CreateTrampoline() argument
134 X86Assembler assembler(allocator); in CreateTrampoline()
153 static std::unique_ptr<const std::vector<uint8_t>> CreateTrampoline(ArenaAllocator* allocator, in CreateTrampoline() argument
155 x86_64::X86_64Assembler assembler(allocator); in CreateTrampoline()
176 ArenaAllocator allocator(&pool); in CreateTrampoline64() local
180 return arm64::CreateTrampoline(&allocator, abi, offset); in CreateTrampoline64()
[all …]
/art/compiler/jni/quick/
Dcalling_convention.cc45 ArenaAllocator* allocator, in Create() argument
55 new (allocator) arm::ArmManagedRuntimeCallingConvention( in Create()
61 new (allocator) arm64::Arm64ManagedRuntimeCallingConvention( in Create()
67 new (allocator) x86::X86ManagedRuntimeCallingConvention( in Create()
73 new (allocator) x86_64::X86_64ManagedRuntimeCallingConvention( in Create()
77 UNUSED(allocator); in Create()
138 std::unique_ptr<JniCallingConvention> JniCallingConvention::Create(ArenaAllocator* allocator, in Create() argument
150 new (allocator) arm::ArmJniCallingConvention( in Create()
156 new (allocator) arm64::Arm64JniCallingConvention( in Create()
162 new (allocator) x86::X86JniCallingConvention( in Create()
[all …]
/art/test/130-hprof/src/
DMain.java48 Class<?> allocator = loader.loadClass("Allocator"); in allocInDifferentLoader() local
49 return allocator.getDeclaredMethod("allocObject", null).invoke(null); in allocInDifferentLoader()
135 Allocator allocator = new Allocator(); in testGcAndDump() local
136 Dumper dumper = new Dumper(allocator); in testGcAndDump()
137 allocator.start(); in testGcAndDump()
140 allocator.join(); in testGcAndDump()
164 Dumper(Allocator allocator) { in Dumper() argument
165 this.allocator = allocator; in Dumper()
167 Allocator allocator; field in Main.Dumper
173 allocator.running = false; in run()
/art/runtime/gc/
Dallocator_type.h42 inline constexpr bool IsTLABAllocator(AllocatorType allocator) { in IsTLABAllocator() argument
43 return allocator == kAllocatorTypeTLAB || allocator == kAllocatorTypeRegionTLAB; in IsTLABAllocator()
/art/runtime/gc/space/
Drosalloc_space.cc50 art::gc::allocator::RosAlloc* rosalloc, in RosAllocSpace()
83 allocator::RosAlloc* rosalloc = CreateRosAlloc(mem_map.Begin(), in CreateFromMemMap()
179 allocator::RosAlloc* RosAllocSpace::CreateRosAlloc(void* begin, size_t morecore_start, in CreateRosAlloc()
188 allocator::RosAlloc* rosalloc = new art::gc::allocator::RosAlloc( in CreateRosAlloc()
191 art::gc::allocator::RosAlloc::kPageReleaseModeAll : in CreateRosAlloc()
192 art::gc::allocator::RosAlloc::kPageReleaseModeSizeAndEnd, in CreateRosAlloc()
226 void* allocator, in CreateInstance() argument
237 reinterpret_cast<allocator::RosAlloc*>(allocator), in CreateInstance()
249 reinterpret_cast<allocator::RosAlloc*>(allocator), in CreateInstance()
360 InspectAllRosAlloc(art::gc::allocator::RosAlloc::BytesAllocatedCallback, &bytes_allocated, false); in GetBytesAllocated()
[all …]

12345678