| /arkcompiler/runtime_core/compiler/tests/ |
| D | memory_coalescing_test.cpp | 29 GetGraph()->SetLowLevelInstructionsEnabled(); in MemoryCoalescingTest() 37 if (GetGraph()->GetArch() != Arch::AARCH64) { in TEST_F() 40 GRAPH(GetGraph()) in TEST_F() 77 ASSERT_TRUE(GetGraph()->RunPass<MemoryCoalescing>()); in TEST_F() 78 GraphChecker(GetGraph()).Check(); in TEST_F() 79 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), opt_graph)); in TEST_F() 85 if (GetGraph()->GetArch() != Arch::AARCH64) { in TEST_F() 88 GRAPH(GetGraph()) in TEST_F() 142 ASSERT_TRUE(GetGraph()->RunPass<MemoryCoalescing>()); in TEST_F() 143 GraphChecker(GetGraph()).Check(); in TEST_F() [all …]
|
| D | rpo_test.cpp | 26 for (auto block : GetGraph()->GetBlocksRPO()) { in Check_Subsequence() 39 auto block = GetGraph()->CreateStartBlock(); in TEST_F() 81 GRAPH(GetGraph()) in TEST_F() 107 auto exit = GetGraph()->GetEndBlock(); in TEST_F() 113 auto M = GetGraph()->CreateEmptyBlock(); in TEST_F() 114 auto N = GetGraph()->CreateEmptyBlock(); in TEST_F() 115 auto ret1 = GetGraph()->CreateInstReturnVoid(); in TEST_F() 117 auto K = GetGraph()->CreateEmptyBlock(); in TEST_F() 118 auto ret2 = GetGraph()->CreateInstReturnVoid(); in TEST_F() 124 auto cmp = GetGraph()->CreateInstCompare(); in TEST_F() [all …]
|
| D | deoptimize_elimination_test.cpp | 27 Graph *GetGraph() in GetGraph() function in panda::compiler::DeoptimizeEliminationTest 38 GRAPH(GetGraph()) in TEST_F() 62 ASSERT_TRUE(GetGraph()->RunPass<DeoptimizeElimination>()); in TEST_F() 63 ASSERT_TRUE(GetGraph()->RunPass<Cleanup>()); in TEST_F() 78 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), graph)); in TEST_F() 83 GRAPH(GetGraph()) in TEST_F() 99 ASSERT_TRUE(GetGraph()->RunPass<DeoptimizeElimination>()); in TEST_F() 117 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), graph)); in TEST_F() 123 GRAPH(GetGraph()) in TEST_F() 141 …auto clone = GraphCloner(GetGraph(), GetGraph()->GetAllocator(), GetGraph()->GetLocalAllocator()).… in TEST_F() [all …]
|
| D | alias_analysis_test.cpp | 37 GRAPH(GetGraph()) in TEST_F() 71 GetGraph()->RunPass<AliasAnalysis>(); in TEST_F() 72 EXPECT_TRUE(GetGraph()->IsAnalysisValid<AliasAnalysis>()); in TEST_F() 73 GraphChecker(GetGraph()).Check(); in TEST_F() 75 AliasAnalysis &alias = GetGraph()->GetAnalysis<AliasAnalysis>(); in TEST_F() 104 GRAPH(GetGraph()) in TEST_F() 154 GetGraph()->RunPass<AliasAnalysis>(); in TEST_F() 155 EXPECT_TRUE(GetGraph()->IsAnalysisValid<AliasAnalysis>()); in TEST_F() 156 GraphChecker(GetGraph()).Check(); in TEST_F() 158 AliasAnalysis &alias = GetGraph()->GetAnalysis<AliasAnalysis>(); in TEST_F() [all …]
|
| D | live_registers_test.cpp | 27 auto intervals = ArenaVector<LifeIntervals *>(GetGraph()->GetAllocator()->Adapter()); in TEST_F() 28 ASSERT_EQ(LifeIntervalsTree::BuildIntervalsTree(intervals, GetGraph()), nullptr); in TEST_F() 33 auto alloc = GetGraph()->GetAllocator(); in TEST_F() 35 …intervals.push_back(alloc->New<LifeIntervals>(alloc, GetGraph()->CreateInstAdd(), LiveRange(0, 42)… in TEST_F() 36 ASSERT_EQ(LifeIntervalsTree::BuildIntervalsTree(intervals, GetGraph()), nullptr); in TEST_F() 41 auto alloc = GetGraph()->GetAllocator(); in TEST_F() 43 …intervals.push_back(alloc->New<LifeIntervals>(alloc, GetGraph()->CreateInstAdd(), LiveRange(0, 10)… in TEST_F() 44 …intervals.push_back(alloc->New<LifeIntervals>(alloc, GetGraph()->CreateInstAdd(), LiveRange(0, 2))… in TEST_F() 45 …intervals.push_back(alloc->New<LifeIntervals>(alloc, GetGraph()->CreateInstAdd(), LiveRange(2, 3))… in TEST_F() 46 …intervals.push_back(alloc->New<LifeIntervals>(alloc, GetGraph()->CreateInstAdd(), LiveRange(5, 6))… in TEST_F() [all …]
|
| D | code_sink_test.cpp | 26 GRAPH(GetGraph()) in TEST_F() 70 ASSERT_TRUE(GetGraph()->RunPass<CodeSink>()); in TEST_F() 71 GraphChecker(GetGraph()).Check(); in TEST_F() 72 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), sunk_graph)); in TEST_F() 82 GRAPH(GetGraph()) in TEST_F() 132 ASSERT_TRUE(GetGraph()->RunPass<CodeSink>()); in TEST_F() 133 GraphChecker(GetGraph()).Check(); in TEST_F() 134 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), sunk_graph)); in TEST_F() 142 std::vector<Graph *> equal_graphs = {GetGraph(), CreateEmptyGraph()}; in TEST_F() 176 std::vector<Graph *> equal_graphs = {GetGraph(), CreateEmptyGraph()}; in TEST_F() [all …]
|
| D | dom_tree_test.cpp | 53 GRAPH(GetGraph()) in TEST_F() 61 auto block = GetGraph()->GetStartBlock(); in TEST_F() 62 GetGraph()->RunPass<DominatorsTree>(); in TEST_F() 64 EXPECT_TRUE(GetGraph()->IsAnalysisValid<DominatorsTree>()); in TEST_F() 105 GRAPH(GetGraph()) in TEST_F() 134 auto entry = GetGraph()->GetStartBlock(); in TEST_F() 141 auto exit = GetGraph()->GetEndBlock(); in TEST_F() 144 GetGraph()->RunPass<DominatorsTree>(); in TEST_F() 145 EXPECT_TRUE(GetGraph()->IsAnalysisValid<DominatorsTree>()); in TEST_F() 148 auto G = GetGraph()->CreateEmptyBlock(); in TEST_F() [all …]
|
| D | method_properties_test.cpp | 25 GRAPH(GetGraph()) in CheckCall() 37 MethodProperties props(GetGraph()); in CheckCall() 48 GetGraph()->CreateStartBlock(); in TEST_F() 49 MethodProperties props(GetGraph()); in TEST_F() 59 GRAPH(GetGraph()) in TEST_F() 69 MethodProperties props(GetGraph()); in TEST_F() 79 GRAPH(GetGraph()) in TEST_F() 90 MethodProperties props(GetGraph()); in TEST_F() 115 GRAPH(GetGraph()) in TEST_F() 124 MethodProperties props(GetGraph()); in TEST_F() [all …]
|
| D | move_constants_test.cpp | 26 GRAPH(GetGraph()) in TEST_F() 88 bool result = GetGraph()->RunPass<MoveConstants>(); in TEST_F() 91 GraphChecker(GetGraph()).Check(); in TEST_F() 92 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), graph_et)); in TEST_F() 97 GRAPH(GetGraph()) in TEST_F() 163 bool result = GetGraph()->RunPass<MoveConstants>(); in TEST_F() 166 GraphChecker(GetGraph()).Check(); in TEST_F() 167 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), graph_et)); in TEST_F() 172 GRAPH(GetGraph()) in TEST_F() 260 bool result = GetGraph()->RunPass<MoveConstants>(); in TEST_F() [all …]
|
| D | reg_alloc_graph_coloring_test.cpp | 33 … auto param_liveness = GetGraph()->GetAnalysis<LivenessAnalyzer>().GetInstLifeIntervals(param); in GetParameterSpillFilll() 43 if (GetGraph()->GetArch() == Arch::AARCH32) { in TEST_F() 47 GRAPH(GetGraph()) in TEST_F() 71 auto result = GetGraph()->RunPass<RegAllocGraphColoring>(); in TEST_F() 73 GraphChecker(GetGraph()).Check(); in TEST_F() 78 auto arch = GetGraph()->GetArch(); in TEST_F() 91 if (GetGraph()->GetArch() == Arch::AARCH32) { in TEST_F() 95 GRAPH(GetGraph()) in TEST_F() 141 auto result = GetGraph()->RunPass<RegAllocGraphColoring>(); in TEST_F() 143 GraphChecker(GetGraph()).Check(); in TEST_F() [all …]
|
| D | cleanup_test.cpp | 26 GRAPH(GetGraph()) in TEST_F() 35 ASSERT_TRUE(GetGraph()->RunPass<Cleanup>()); in TEST_F() 45 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), graph)); in TEST_F() 50 GRAPH(GetGraph()) in TEST_F() 77 ASSERT_TRUE(GetGraph()->RunPass<Cleanup>()); in TEST_F() 102 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), graph)); in TEST_F() 107 GRAPH(GetGraph()) in TEST_F() 129 ASSERT_TRUE(GetGraph()->RunPass<Cleanup>()); in TEST_F() 150 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), graph)); in TEST_F() 155 GRAPH(GetGraph()) in TEST_F() [all …]
|
| D | vn_test.cpp | 26 Graph *GetGraph() override in GetGraph() function in panda::compiler::VNTest 38 GRAPH(GetGraph()) in TEST_F() 88 GetGraph()->RunPass<ValNum>(); in TEST_F() 89 GraphChecker(GetGraph()).Check(); in TEST_F() 90 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), graph_et)); in TEST_F() 96 GRAPH(GetGraph()) in TEST_F() 186 GetGraph()->RunPass<ValNum>(); in TEST_F() 187 GraphChecker(GetGraph()).Check(); in TEST_F() 188 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), graph_et)); in TEST_F() 194 GRAPH(GetGraph()) in TEST_F() [all …]
|
| D | inst_test.cpp | 49 GRAPH(GetGraph()) in TEST_F() 124 GraphChecker(GetGraph()).Check(); in TEST_F() 130 // GetGraph()->DisconnectBlock(&BB(7)) in TEST_F() 134 GraphChecker(GetGraph()).Check(); in TEST_F() 145 GRAPH(GetGraph()) in TEST_F() 161 GRAPH(GetGraph()) in TEST_F() 183 GRAPH(GetGraph()) in TEST_F() 190 auto start = GetGraph()->GetStartBlock(); in TEST_F() 193 auto const1 = GetGraph()->FindOrCreateConstant(val); in TEST_F() 197 auto const2 = GetGraph()->FindOrCreateConstant(val1); in TEST_F() [all …]
|
| D | iterators_test.cpp | 190 GRAPH(GetGraph()) in TEST_F() 203 GRAPH(GetGraph()) in TEST_F() 212 inst = GetGraph()->CreateInst(Opcode::Phi); in TEST_F() 219 GRAPH(GetGraph()) in TEST_F() 228 inst = GetGraph()->CreateInst(Opcode::Add); in TEST_F() 235 GRAPH(GetGraph()) in TEST_F() 248 inst = GetGraph()->CreateInst(Opcode::Phi); in TEST_F() 250 inst = GetGraph()->CreateInst(Opcode::Add); in TEST_F() 258 inst = GetGraph()->CreateInst(Opcode::Phi); in TEST_F() 260 inst = GetGraph()->CreateInst(Opcode::Add); in TEST_F() [all …]
|
| D | if_conversion_test.cpp | 26 GetGraph()->SetLowLevelInstructionsEnabled(); in IfConversionTest() 45 GRAPH(GetGraph()) in TEST_F() 66 GetGraph()->RunPass<IfConversion>(); in TEST_F() 82 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), graph)); in TEST_F() 87 GRAPH(GetGraph()) in TEST_F() 107 GetGraph()->RunPass<IfConversion>(); in TEST_F() 122 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), graph)); in TEST_F() 139 GRAPH(GetGraph()) in TEST_F() 160 GetGraph()->RunPass<IfConversion>(); in TEST_F() 176 ASSERT_TRUE(GraphComparator().Compare(GetGraph(), graph)); in TEST_F() [all …]
|
| D | basicblock_test.cpp | 85 GRAPH(GetGraph()) in TEST_F() 146 GetGraph()->DisconnectBlock(&BB(7)); in TEST_F() 154 GetGraph()->InvalidateAnalysis<LoopAnalyzer>(); in TEST_F() 155 GetGraph()->RunPass<LoopAnalyzer>(); in TEST_F() 156 GraphChecker(GetGraph()).Check(); in TEST_F() 170 GRAPH(GetGraph()) in TEST_F() 190 GetGraph()->RemoveEmptyBlockWithPhis(&BB(3)); in TEST_F() 201 GRAPH(GetGraph()) in TEST_F() 233 GRAPH(GetGraph()) in TEST_F() 268 if (GetGraph()->GetCallingConvention() == nullptr) { in TEST_F() [all …]
|
| D | codegen_test.cpp | 87 CodegenTest() : exec_module_(GetAllocator(), GetGraph()->GetRuntime()) in CodegenTest() 91 GetGraph()->SetLowLevelInstructionsEnabled(); in CodegenTest() 159 GRAPH(GetGraph()) in TEST_F() 192 RegAlloc(GetGraph()); in TEST_F() 195 EXPECT_TRUE(RunCodegen(GetGraph())); in TEST_F() 196 auto entry = reinterpret_cast<char *>(GetGraph()->GetData().Data()); in TEST_F() 197 auto exit = entry + GetGraph()->GetData().Size(); in TEST_F() 208 while (auto current = GetGraph()->GetFirstConstInst()) { in TEST_F() 209 GetGraph()->RemoveConstFromList(current); in TEST_F() 582 auto insts_per_byte = GetGraph()->GetEncoder()->MaxArchInstPerEncoded(); in CheckBounds() [all …]
|
| /arkcompiler/runtime_core/compiler/optimizer/optimizations/regalloc/ |
| D | reg_alloc_base.cpp | 75 RegAllocStat st(GetGraph()->GetAnalysis<LivenessAnalyzer>().GetLifeIntervals()); in RunImpl() 88 if (auto rzero = GetGraph()->GetZeroReg(); rzero != INVALID_REG) { in Prepare() 93 GetGraph()->InitUsedRegs<DataType::INT64>(&GetRegMask().GetVector()); in Prepare() 94 GetGraph()->InitUsedRegs<DataType::FLOAT64>(&GetVRegMask().GetVector()); in Prepare() 96 GetGraph()->RunPass<DominatorsTree>(); in Prepare() 101 bool res = GetGraph()->RunPass<LivenessAnalyzer>(); in Prepare() 102 if (GetGraph()->IsBytecodeOptimizer()) { in Prepare() 103 GetGraph()->InitDefaultLocations(); in Prepare() 116 GetGraph()->GetPassManager()->DumpLifeIntervals(GetPassName()); in Resolve() 120 GetGraph()->SetStackSlotsCount(GetTotalSlotsCount()); in Resolve() [all …]
|
| /arkcompiler/runtime_core/compiler/optimizer/ir_builder/ |
| D | ir_builder.cpp | 33 … << GetGraph()->GetRuntime()->GetClassNameFromMethod(GetMethod()) << "." in RunImpl() 34 << GetGraph()->GetRuntime()->GetMethodName(GetMethod()) in RunImpl() 35 … << "(args=" << GetGraph()->GetRuntime()->GetMethodTotalArgumentsCount(GetMethod()) in RunImpl() 36 … << ", regs=" << GetGraph()->GetRuntime()->GetMethodRegistersCount(GetMethod()) in RunImpl() 39 auto instructions_buf = GetGraph()->GetRuntime()->GetMethodCode(GetMethod()); in RunImpl() 40 …BytecodeInstructions pbc_instructions(instructions_buf, GetGraph()->GetRuntime()->GetMethodCodeSiz… in RunImpl() 41 size_t vregs_count = GetGraph()->GetRuntime()->GetMethodRegistersCount(GetMethod()) + in RunImpl() 42 GetGraph()->GetRuntime()->GetMethodTotalArgumentsCount(GetMethod()) + 1; in RunImpl() 46 GetGraph()->SetVRegsCount(vregs_count); in RunImpl() 48 GetGraph()->RunPass<DominatorsTree>(); in RunImpl() [all …]
|
| D | inst_builder.h | 41 instructions_buf_(GetGraph()->GetRuntime()->GetMethodCode(GetGraph()->GetMethod())), in InstBuilder() 45 no_type_marker_ = GetGraph()->NewMarker(); 46 visited_block_marker_ = GetGraph()->NewMarker(); 56 auto catch_phi = GetGraph()->CreateInstCatchPhi(); 72 GetGraph()->EraseMarker(no_type_marker_); in ~InstBuilder() 73 GetGraph()->EraseMarker(visited_block_marker_); in ~InstBuilder() 132 ASSERT(GetGraph()->IsBytecodeOptimizer()); in TryFillInstIdTypePair() 133 ASSERT(GetGraph()->IsDynamicMethod()); in TryFillInstIdTypePair() 134 GetGraph()->GetRuntime()->FillInstIdTypePairByPc(id, pc); in TryFillInstIdTypePair() 206 auto inst = GetGraph()->FindOrCreateConstant<uint32_t>(value); in FindOrCreate32BitConstant() [all …]
|
| /arkcompiler/runtime_core/compiler/optimizer/analysis/ |
| D | loop_analyzer.cpp | 25 GetGraph()->RunPass<DominatorsTree>(); in RunImpl() 30 for (auto loop : GetGraph()->GetRootLoop()->GetInnerLoops()) { in RunImpl() 33 SearchInfiniteLoops(GetGraph()->GetRootLoop()); in RunImpl() 39 for (auto block : GetGraph()->GetVectorBlocks()) { in ResetLoopInfo() 44 GetGraph()->SetRootLoop(nullptr); in ResetLoopInfo() 45 GetGraph()->SetHasIrreducibleLoop(false); in ResetLoopInfo() 46 GetGraph()->SetHasInfiniteLoop(false); in ResetLoopInfo() 52 …auto loop = GetGraph()->GetAllocator()->New<Loop>(GetGraph()->GetAllocator(), loop_header, loop_co… in CreateNewLoop() 59 ASSERT(GetGraph()->GetRootLoop() == nullptr); in CreateRootLoop() 60 …auto root_loop = GetGraph()->GetAllocator()->New<Loop>(GetGraph()->GetAllocator(), nullptr, loop_c… in CreateRootLoop() [all …]
|
| /arkcompiler/runtime_core/compiler/optimizer/code_generator/ |
| D | codegen_native.cpp | 24 auto frame = GetGraph()->GetLocalAllocator()->New<FrameInfo>( in CreateFrameInfo() 39 ASSERT(!GetGraph()->GetMethodProperties().GetRequireFrameSetup()); in CreateFrameInfo() 43 frame->SetSaveFrameAndLinkRegs(!GetGraph()->GetMethodProperties().IsLeaf()); in CreateFrameInfo() 49 …frame->SetAdjustSpReg(!GetGraph()->GetMethodProperties().IsLeaf() || GetGraph()->GetStackSlotsCoun… in CreateFrameInfo() 50 GetGraph()->GetMethodProperties().GetHasParamsOnStack()); in CreateFrameInfo() 60 if (GetGraph()->IsDynamicMethod()) { in GeneratePrologue() 65 if (GetGraph()->IsAotMode()) { in GeneratePrologue() 73 Imm(reinterpret_cast<size_t>(GetGraph()->GetMethod())), in GeneratePrologue() 81 ASSERT(GetGraph()->GetMethodProperties().IsLeaf()); in GenerateEpilogue() 84 if (GetGraph()->IsDynamicMethod()) { in GenerateEpilogue() [all …]
|
| /arkcompiler/runtime_core/compiler/optimizer/optimizations/ |
| D | deoptimize_elimination.cpp | 49 auto block = GetGraph()->GetStartBlock(); in RemoveSafePoints() 56 … block->GetGraph()->GetEventWriter().EventDeoptimizeElimination(GetOpcodeString(sp->GetOpcode()), in RemoveSafePoints() 101 …inst->GetBasicBlock()->GetGraph()->GetEventWriter().EventDeoptimizeElimination(GetOpcodeString(ins… in VisitDefault() 120 …ss->GetBasicBlock()->GetGraph()->GetEventWriter().EventDeoptimizeElimination(GetOpcodeString(ss->G… in VisitSaveState() 137 auto graph = block->GetGraph(); in VisitDeoptimizeIf() 166 block->ReplaceInst(inst, block->GetGraph()->CreateInstNOP()); in TryToRemoveRedundantSaveState() 170 … block->GetGraph()->GetEventWriter().EventDeoptimizeElimination(GetOpcodeString(inst->GetOpcode()), in TryToRemoveRedundantSaveState() 190 auto mrk = guard_block->GetGraph()->NewMarker(); in CanRemoveGuard() 191 auto remove_mrk = guard_block->GetGraph()->NewMarker(); in CanRemoveGuard() 205 guard_block->GetGraph()->EraseMarker(mrk); in CanRemoveGuard() [all …]
|
| /arkcompiler/runtime_core/compiler/tests/aarch64/ |
| D | codegen_test.cpp | 201 GRAPH(GetGraph()) in TEST_F() 237 GraphChecker(GetGraph()).Check(); in TEST_F() 238 RegAlloc(GetGraph()); in TEST_F() 239 ASSERT_TRUE(GetGraph()->RunPass<Codegen>()); in TEST_F() 241 auto code_entry = reinterpret_cast<vixl::aarch64::Instruction *>(GetGraph()->GetData().Data()); in TEST_F() 242 auto code_exit = code_entry + GetGraph()->GetData().Size(); in TEST_F() 266 GRAPH(GetGraph()) in CheckSpillFillCoalescingForEvenRegsNumber() 289 GraphChecker(GetGraph()).Check(); in CheckSpillFillCoalescingForEvenRegsNumber() 290 GetGraph()->SetStackSlotsCount(8U + alignment_offset); in CheckSpillFillCoalescingForEvenRegsNumber() 291 RegAlloc(GetGraph()); in CheckSpillFillCoalescingForEvenRegsNumber() [all …]
|
| /arkcompiler/runtime_core/compiler/optimizer/ir/ |
| D | dump.cpp | 94 auto allocator = inst->GetBasicBlock()->GetGraph()->GetLocalAllocator(); in DumpUsers() 95 auto arch = inst->GetBasicBlock()->GetGraph()->GetArch(); in DumpUsers() 202 const auto &allocator = GetBasicBlock()->GetGraph()->GetLocalAllocator(); in DumpInputs() 203 auto arch = GetBasicBlock()->GetGraph()->GetArch(); in DumpInputs() 218 const auto &allocator = GetBasicBlock()->GetGraph()->GetLocalAllocator(); in DumpInputs() 283 const auto &allocator = GetBasicBlock()->GetGraph()->GetLocalAllocator(); in DumpInputs() 334 (*out) << sf_data::ToString(spill_fill, GetBasicBlock()->GetGraph()->GetArch()); in DumpInputs() 341 … (*out) << "arg " << IdToString(GetArgNumber(), GetBasicBlock()->GetGraph()->GetLocalAllocator()); in DumpInputs() 347 auto allocator = GetBasicBlock()->GetGraph()->GetLocalAllocator(); in DumpOpcode() 360 auto allocator = mixin_inst->GetBasicBlock()->GetGraph()->GetLocalAllocator(); in DumpOpcodeAnyTypeMixin() [all …]
|