Home
last modified time | relevance | path

Searched refs:graph (Results 1 – 25 of 120) sorted by relevance

12345

/art/tools/ahat/src/test/com/android/ahat/
DDominatorsTest.java75 Graph graph = new Graph(); in singleNode() local
76 graph.node("n"); in singleNode()
77 new Dominators(graph).computeDominators("n"); in singleNode()
84 Graph graph = new Graph(); in parentWithChild() local
85 graph.node("parent", "child"); in parentWithChild()
86 graph.node("child"); in parentWithChild()
87 new Dominators(graph).computeDominators("parent"); in parentWithChild()
89 assertEquals("parent", graph.dom("child")); in parentWithChild()
98 Graph graph = new Graph(); in reachableTwoWays() local
99 graph.node("parent", "left", "right"); in reachableTwoWays()
[all …]
/art/compiler/optimizing/
Dfind_loops_test.cc38 HGraph* graph = CreateCFG(data); in TEST_F() local
39 for (HBasicBlock* block : graph->GetBlocks()) { in TEST_F()
49 HGraph* graph = CreateCFG(data); in TEST_F() local
50 for (HBasicBlock* block : graph->GetBlocks()) { in TEST_F()
63 HGraph* graph = CreateCFG(data); in TEST_F() local
64 for (HBasicBlock* block : graph->GetBlocks()) { in TEST_F()
78 HGraph* graph = CreateCFG(data); in TEST_F() local
79 for (HBasicBlock* block : graph->GetBlocks()) { in TEST_F()
91 HGraph* graph = CreateCFG(data); in TEST_F() local
92 for (HBasicBlock* block : graph->GetBlocks()) { in TEST_F()
[all …]
Dgvn_test.cc30 HGraph* graph = CreateGraph(); in TEST_F() local
31 HBasicBlock* entry = new (GetAllocator()) HBasicBlock(graph); in TEST_F()
32 graph->AddBlock(entry); in TEST_F()
33 graph->SetEntryBlock(entry); in TEST_F()
34 HInstruction* parameter = new (GetAllocator()) HParameterValue(graph->GetDexFile(), in TEST_F()
40 HBasicBlock* block = new (GetAllocator()) HBasicBlock(graph); in TEST_F()
41 graph->AddBlock(block); in TEST_F()
51 graph->GetDexFile(), in TEST_F()
60 graph->GetDexFile(), in TEST_F()
70 graph->GetDexFile(), in TEST_F()
[all …]
Dgraph_test.cc29 HBasicBlock* CreateIfBlock(HGraph* graph);
30 HBasicBlock* CreateGotoBlock(HGraph* graph);
31 HBasicBlock* CreateEntryBlock(HGraph* graph);
32 HBasicBlock* CreateReturnBlock(HGraph* graph);
33 HBasicBlock* CreateExitBlock(HGraph* graph);
36 HBasicBlock* GraphTest::CreateIfBlock(HGraph* graph) { in CreateIfBlock() argument
37 HBasicBlock* if_block = new (GetAllocator()) HBasicBlock(graph); in CreateIfBlock()
38 graph->AddBlock(if_block); in CreateIfBlock()
39 HInstruction* instr = graph->GetIntConstant(4); in CreateIfBlock()
47 HBasicBlock* GraphTest::CreateGotoBlock(HGraph* graph) { in CreateGotoBlock() argument
[all …]
Dnodes_test.cc33 HGraph* graph = CreateGraph(); in TEST_F() local
34 HBasicBlock* entry = new (GetAllocator()) HBasicBlock(graph); in TEST_F()
35 graph->AddBlock(entry); in TEST_F()
36 graph->SetEntryBlock(entry); in TEST_F()
38 graph->GetDexFile(), dex::TypeIndex(0), 0, DataType::Type::kReference); in TEST_F()
42 HBasicBlock* first_block = new (GetAllocator()) HBasicBlock(graph); in TEST_F()
43 graph->AddBlock(first_block); in TEST_F()
49 HBasicBlock* exit_block = new (GetAllocator()) HBasicBlock(graph); in TEST_F()
50 graph->AddBlock(exit_block); in TEST_F()
55 GetAllocator(), 1, graph->GetArtMethod(), 0, null_check); in TEST_F()
[all …]
Dgraph_checker_test.cc37 HGraph* graph = CreateGraph(); in CreateSimpleCFG() local
38 HBasicBlock* entry_block = new (GetAllocator()) HBasicBlock(graph); in CreateSimpleCFG()
40 graph->AddBlock(entry_block); in CreateSimpleCFG()
41 graph->SetEntryBlock(entry_block); in CreateSimpleCFG()
42 HBasicBlock* exit_block = new (GetAllocator()) HBasicBlock(graph); in CreateSimpleCFG()
44 graph->AddBlock(exit_block); in CreateSimpleCFG()
45 graph->SetExitBlock(exit_block); in CreateSimpleCFG()
47 graph->BuildDominatorTree(); in CreateSimpleCFG()
48 return graph; in CreateSimpleCFG()
52 HGraph* graph = CreateCFG(data); in TestCode() local
[all …]
Dregister_allocator_test.cc91 HGraph* graph = CreateCFG(data); in Check() local
92 x86::CodeGeneratorX86 codegen(graph, *compiler_options_); in Check()
93 SsaLivenessAnalysis liveness(graph, &codegen, GetScopedAllocator()); in Check()
106 HGraph* graph = CreateGraph(); in TEST_F() local
107 x86::CodeGeneratorX86 codegen(graph, *compiler_options_); in TEST_F()
330 HGraph* graph = CreateCFG(data); in Loop3() local
331 x86::CodeGeneratorX86 codegen(graph, *compiler_options_); in Loop3()
332 SsaLivenessAnalysis liveness(graph, &codegen, GetScopedAllocator()); in Loop3()
339 HBasicBlock* loop_header = graph->GetBlocks()[2]; in Loop3()
348 HBasicBlock* return_block = graph->GetBlocks()[3]; in Loop3()
[all …]
Dcodegen_test_utils.h56 CodeGenerator* CreateCodeGenerator(HGraph* graph, const CompilerOptions& compiler_options) { in CreateCodeGenerator() argument
57 return create_codegen_(graph, compiler_options); in CreateCodeGenerator()
88 TestCodeGeneratorARMVIXL(HGraph* graph, const CompilerOptions& compiler_options) in TestCodeGeneratorARMVIXL() argument
89 : arm::CodeGeneratorARMVIXL(graph, compiler_options) { in TestCodeGeneratorARMVIXL()
130 TestCodeGeneratorARM64(HGraph* graph, const CompilerOptions& compiler_options) in TestCodeGeneratorARM64() argument
131 : arm64::CodeGeneratorARM64(graph, compiler_options) {} in TestCodeGeneratorARM64()
148 TestCodeGeneratorX86(HGraph* graph, const CompilerOptions& compiler_options) in TestCodeGeneratorX86() argument
149 : x86::CodeGeneratorX86(graph, compiler_options) { in TestCodeGeneratorX86()
261 static void ValidateGraph(HGraph* graph) { in ValidateGraph() argument
262 GraphChecker graph_checker(graph); in ValidateGraph()
[all …]
Dcodegen_test.cc81 HGraph* graph = CreateCFG(data); in TestCode() local
83 RemoveSuspendChecks(graph); in TestCode()
86 RunCode(target_config, *compiler_options, graph, [](HGraph*) {}, has_result, expected); in TestCode()
94 HGraph* graph = CreateCFG(data, DataType::Type::kInt64); in TestCodeLong() local
96 RemoveSuspendChecks(graph); in TestCodeLong()
99 RunCode(target_config, *compiler_options, graph, [](HGraph*) {}, has_result, expected); in TestCodeLong()
415 HGraph* graph = CreateGraph(); in TEST_F() local
417 HBasicBlock* entry = new (GetAllocator()) HBasicBlock(graph); in TEST_F()
418 graph->AddBlock(entry); in TEST_F()
419 graph->SetEntryBlock(entry); in TEST_F()
[all …]
Dside_effects_analysis.h28 explicit SideEffectsAnalysis(HGraph* graph, const char* pass_name = kSideEffectsAnalysisPassName)
29 : HOptimization(graph, pass_name), in HOptimization() argument
30 graph_(graph), in HOptimization()
31 block_effects_(graph->GetBlocks().size(), in HOptimization()
32 graph->GetAllocator()->Adapter(kArenaAllocSideEffectsAnalysis)), in HOptimization()
33 loop_effects_(graph->GetBlocks().size(), in HOptimization()
34 graph->GetAllocator()->Adapter(kArenaAllocSideEffectsAnalysis)) {} in HOptimization()
Doptimization.cc164 HGraph* graph, in ConstructOptimizations() argument
190 opt = most_recent_side_effects = new (allocator) SideEffectsAnalysis(graph, pass_name); in ConstructOptimizations()
193 opt = most_recent_induction = new (allocator) HInductionVarAnalysis(graph, pass_name); in ConstructOptimizations()
200 opt = new (allocator) GVNOptimization(graph, *most_recent_side_effects, pass_name); in ConstructOptimizations()
204 opt = new (allocator) LICM(graph, *most_recent_side_effects, stats, pass_name); in ConstructOptimizations()
209 graph, *codegen, most_recent_induction, stats, pass_name); in ConstructOptimizations()
214 graph, *most_recent_side_effects, most_recent_induction, pass_name); in ConstructOptimizations()
219 graph, *most_recent_side_effects, stats, pass_name); in ConstructOptimizations()
225 opt = new (allocator) HConstantFolding(graph, pass_name); in ConstructOptimizations()
228 opt = new (allocator) HDeadCodeElimination(graph, stats, pass_name); in ConstructOptimizations()
[all …]
Dlive_ranges_test.cc38 HGraph* graph = CreateCFG(data); in BuildGraph() local
42 RemoveSuspendChecks(graph); in BuildGraph()
44 PrepareForRegisterAllocation(graph, *compiler_options_).Run(); in BuildGraph()
45 return graph; in BuildGraph()
65 HGraph* graph = BuildGraph(data); in TEST_F() local
67 std::unique_ptr<CodeGenerator> codegen = CodeGenerator::Create(graph, *compiler_options_); in TEST_F()
68 SsaLivenessAnalysis liveness(graph, codegen.get(), GetScopedAllocator()); in TEST_F()
76 HBasicBlock* block = graph->GetBlocks()[1]; in TEST_F()
110 HGraph* graph = BuildGraph(data); in TEST_F() local
111 std::unique_ptr<CodeGenerator> codegen = CodeGenerator::Create(graph, *compiler_options_); in TEST_F()
[all …]
Dlinear_order.cc58 static bool IsLinearOrderWellFormed(const HGraph* graph, ArrayRef<HBasicBlock*> linear_order) { in IsLinearOrderWellFormed() argument
59 for (HBasicBlock* header : graph->GetBlocks()) { in IsLinearOrderWellFormed()
86 void LinearizeGraphInternal(const HGraph* graph, ArrayRef<HBasicBlock*> linear_order) { in LinearizeGraphInternal() argument
87 DCHECK_EQ(linear_order.size(), graph->GetReversePostOrder().size()); in LinearizeGraphInternal()
97 ScopedArenaAllocator allocator(graph->GetArenaStack()); in LinearizeGraphInternal()
98 ScopedArenaVector<uint32_t> forward_predecessors(graph->GetBlocks().size(), in LinearizeGraphInternal()
100 for (HBasicBlock* block : graph->GetReversePostOrder()) { in LinearizeGraphInternal()
112 worklist.push_back(graph->GetEntryBlock()); in LinearizeGraphInternal()
130 DCHECK(graph->HasIrreducibleLoops() || IsLinearOrderWellFormed(graph, linear_order)); in LinearizeGraphInternal()
Dlinear_order.h26 void LinearizeGraphInternal(const HGraph* graph, ArrayRef<HBasicBlock*> linear_order);
40 void LinearizeGraph(const HGraph* graph, Vector* linear_order) { in LinearizeGraph() argument
45 linear_order->resize(graph->GetReversePostOrder().size()); in LinearizeGraph()
46 LinearizeGraphInternal(graph, ArrayRef<HBasicBlock*>(*linear_order)); in LinearizeGraph()
Dssa_phi_elimination.h31 explicit SsaDeadPhiElimination(HGraph* graph) in SsaDeadPhiElimination() argument
32 : HOptimization(graph, kSsaDeadPhiEliminationPassName) {} in SsaDeadPhiElimination()
53 explicit SsaRedundantPhiElimination(HGraph* graph) in SsaRedundantPhiElimination() argument
54 : HOptimization(graph, kSsaRedundantPhiEliminationPassName) {} in SsaRedundantPhiElimination()
Dinduction_var_range.cc232 HGraph* graph, in GenerateRange() argument
242 graph, in GenerateRange()
255 HGraph* graph, in GenerateTakenTest() argument
264 graph, in GenerateTakenTest()
297 HGraph* graph, in GenerateLastValue() argument
306 graph, in GenerateLastValue()
346 HGraph* graph, in IsUnitStride() argument
358 *offset = graph->GetConstant(info->op_b->type, off_value); in IsUnitStride()
372 HGraph* graph, in GenerateTripCount() argument
380 if (!GenerateCode(trip->op_b, nullptr, graph, block, &taken_test, false, false)) { in GenerateTripCount()
[all …]
Ddead_code_elimination_test.cc38 HGraph* graph = CreateCFG(data); in TestCode() local
39 ASSERT_NE(graph, nullptr); in TestCode()
41 StringPrettyPrinter printer_before(graph); in TestCode()
46 HDeadCodeElimination(graph, /* stats= */ nullptr, "dead_code_elimination").Run(); in TestCode()
47 GraphChecker graph_checker(graph); in TestCode()
51 StringPrettyPrinter printer_after(graph); in TestCode()
Doptimizing_unit_test.h76 inline void RemoveSuspendChecks(HGraph* graph) { in RemoveSuspendChecks() argument
77 for (HBasicBlock* block : graph->GetBlocks()) { in RemoveSuspendChecks()
158 HGraph* graph = CreateGraph(handles); variable
169 new (graph->GetAllocator()) DexCompilationUnit(
172 graph->GetDexFile(),
179 CodeItemDebugInfoAccessor accessor(graph->GetDexFile(), code_item, /*dex_method_idx*/ 0u);
180 HGraphBuilder builder(graph, dex_compilation_unit, accessor, return_type);
182 return graph_built ? graph : nullptr;
216 bool CheckGraph(HGraph* graph) { in CheckGraph() argument
217 return CheckGraph(graph, /*check_ref_type_info=*/true); in CheckGraph()
[all …]
Dx86_memory_gen.cc29 MemoryOperandVisitor(HGraph* graph, bool do_implicit_null_checks) in MemoryOperandVisitor() argument
30 : HGraphVisitor(graph), in MemoryOperandVisitor()
72 X86MemoryOperandGeneration::X86MemoryOperandGeneration(HGraph* graph, in X86MemoryOperandGeneration() argument
75 : HOptimization(graph, kX86MemoryOperandGenerationPassName, stats), in X86MemoryOperandGeneration()
Dbounds_check_elimination_test.cc358 static HInstruction* BuildSSAGraph1(HGraph* graph, in BuildSSAGraph1() argument
363 HBasicBlock* entry = new (allocator) HBasicBlock(graph); in BuildSSAGraph1()
364 graph->AddBlock(entry); in BuildSSAGraph1()
365 graph->SetEntryBlock(entry); in BuildSSAGraph1()
367 graph->GetDexFile(), dex::TypeIndex(0), 0, DataType::Type::kReference); in BuildSSAGraph1()
370 HInstruction* constant_initial = graph->GetIntConstant(initial); in BuildSSAGraph1()
371 HInstruction* constant_increment = graph->GetIntConstant(increment); in BuildSSAGraph1()
372 HInstruction* constant_10 = graph->GetIntConstant(10); in BuildSSAGraph1()
374 HBasicBlock* block = new (allocator) HBasicBlock(graph); in BuildSSAGraph1()
375 graph->AddBlock(block); in BuildSSAGraph1()
[all …]
Dconstant_folding_test.cc124 auto check_after_cf = [](HGraph* graph) { in TEST_F() argument
125 HInstruction* inst = graph->GetBlocks()[1]->GetFirstInstruction()->InputAt(0); in TEST_F()
185 auto check_after_cf = [](HGraph* graph) { in TEST_F() argument
186 HInstruction* inst = graph->GetBlocks()[1]->GetFirstInstruction()->InputAt(0); in TEST_F()
246 auto check_after_cf = [](HGraph* graph) { in TEST_F() argument
247 HInstruction* inst = graph->GetBlocks()[1]->GetFirstInstruction()->InputAt(0); in TEST_F()
325 auto check_after_cf = [](HGraph* graph) { in TEST_F() argument
326 HInstruction* inst1 = graph->GetBlocks()[1]->GetFirstInstruction()->InputAt(0); in TEST_F()
396 auto check_after_cf = [](HGraph* graph) { in TEST_F() argument
397 HInstruction* inst = graph->GetBlocks()[1]->GetFirstInstruction()->InputAt(0); in TEST_F()
[all …]
Dinduction_var_range.h102 HGraph* graph,
113 HInstruction* GenerateTakenTest(HInstruction* context, HGraph* graph, HBasicBlock* block);
127 HInstruction* GenerateLastValue(HInstruction* instruction, HGraph* graph, HBasicBlock* block);
182 HGraph* graph,
190 HInstruction* GenerateTripCount(HLoopInformation* loop, HGraph* graph, HBasicBlock* block);
292 HGraph* graph,
303 HGraph* graph,
309 HGraph* graph,
315 HGraph* graph,
321 HGraph* graph,
[all …]
Dconstant_folding.h42 HConstantFolding(HGraph* graph, const char* name) : HOptimization(graph, name) {} in HConstantFolding() argument
Doptimizing_compiler.cc106 PassObserver(HGraph* graph, in PassObserver() argument
111 : graph_(graph), in PassObserver()
116 disasm_info_(graph->GetAllocator()), in PassObserver()
120 visualizer_(&visualizer_oss_, graph, *codegen), in PassObserver()
307 bool RunOptimizations(HGraph* graph, in RunOptimizations() argument
317 graph->GetAllocator(), in RunOptimizations()
318 graph, in RunOptimizations()
348 HGraph* graph, in RunOptimizations() argument
354 graph, codegen, dex_compilation_unit, pass_observer, definitions, length); in RunOptimizations()
357 void RunOptimizations(HGraph* graph,
[all …]
/art/tools/ahat/src/main/com/android/ahat/dominators/
DDominators.java33 private final Graph<Node> graph; field in Dominators
109 public Dominators(Graph graph) { in Dominators() argument
110 this.graph = graph; in Dominators()
295 graph.setDominatorsComputationState(root, rootS); in computeDominators()
299 for (Node child : graph.getReferencesForDominators(root)) { in computeDominators()
320 NodeS dstS = (NodeS)graph.getDominatorsComputationState(link.dst); in computeDominators()
325 graph.setDominatorsComputationState(link.dst, dstS); in computeDominators()
336 for (Node child : graph.getReferencesForDominators(link.dst)) { in computeDominators()
453 graph.setDominatorsComputationState((Node)nodeS.node, null); in computeDominators()
456 graph.setDominator((Node)xS.node, (Node)nodeS.node); in computeDominators()

12345