/arkcompiler/runtime_core/compiler/optimizer/optimizations/ |
D | cleanup.h | 62 void MarkLiveRec(Marker live_mrk, Inst *inst); 65 void SetLiveRec(Inst *inst, Marker mrk, Marker live_mrk); 66 void LiveUserSearchRec(Inst *inst, Marker mrk, Marker live_mrk, Marker dead_mrk); 87 ArenaUnorderedMap<Inst *, uint32_t> map_; 89 Inst *fake_root_ {nullptr}; 94 inline uint32_t GetInstId(Inst *inst) const in GetInstId() 103 void SetIdom(Inst *inst, Inst *idom) in SetIdom() 107 Inst *GetIdom(Inst *inst) const in GetIdom() 115 void SetAncestor(Inst *inst, Inst *anc) in SetAncestor() 119 Inst *GetAncestor(Inst *inst) const in GetAncestor() [all …]
|
D | lowering.h | 53 static void VisitIfImm([[maybe_unused]] GraphVisitor *v, Inst *inst); 57 static bool ConstantFitsCompareImm(Inst *cst, uint32_t size, ConditionCode cc); 59 static bool BetterToSwapCompareInputs(Inst *cmp); 61 static void OptimizeIfInput(compiler::Inst *if_inst); 63 static void InPlaceLowerIfImm(IfImmInst *inst, Inst *input, Inst *cst, ConditionCode cc);
|
D | vn.h | 25 class Inst; variable 42 void Add(Inst *inst); 111 void FindEqualVnOrCreateNew(Inst *inst); 114 using InstVector = ArenaVector<Inst *>; 117 void SetInstValNum(Inst *inst); 119 bool TryToApplyCse(Inst *inst, InstVector *equiv_insts);
|
D | move_constants.cpp | 31 static Inst *SingleBlockNoPhiDominatingUser(Inst *inst); 52 void MoveConstants::MoveFromStartBlock(Inst *inst) in MoveFromStartBlock() 84 static Inst *SingleBlockNoPhiDominatingUser(Inst *inst) in SingleBlockNoPhiDominatingUser() 86 Inst *first_inst {}; in SingleBlockNoPhiDominatingUser() 106 void MoveConstants::GetUsersDominatingBlocks(const Inst *inst) in GetUsersDominatingBlocks()
|
D | lowering.cpp | 21 void Lowering::VisitIfImm([[maybe_unused]] GraphVisitor *v, Inst *inst) in VisitIfImm() 28 bool Lowering::ConstantFitsCompareImm(Inst *cst, uint32_t size, ConditionCode cc) in ConstantFitsCompareImm() 39 bool Lowering::BetterToSwapCompareInputs(Inst *cmp) in BetterToSwapCompareInputs() 61 void Lowering::OptimizeIfInput(compiler::Inst *if_inst) in OptimizeIfInput() 64 compiler::Inst *input_0 = if_inst->GetInput(0).GetInst(); in OptimizeIfInput() 65 compiler::Inst *input_1 = if_inst->GetInput(1).GetInst(); in OptimizeIfInput() 138 void Lowering::InPlaceLowerIfImm(IfImmInst *inst, Inst *input, Inst *cst, ConditionCode cc) in InPlaceLowerIfImm()
|
/arkcompiler/runtime_core/libark_defect_scan_aux/ |
D | graph.cpp | 28 bool Inst::operator==(const Inst &inst) const in operator ==() 33 bool Inst::operator!=(const Inst &inst) const in operator !=() 38 InstType Inst::GetType() const in GetType() 43 bool Inst::IsInstStLexVar() const in IsInstStLexVar() 49 bool Inst::IsInstLdLexVar() const in IsInstLdLexVar() 55 bool Inst::IsInstStGlobal() const in IsInstStGlobal() 62 bool Inst::IsInstLdGlobal() const in IsInstLdGlobal() 68 uint16_t Inst::GetArgIndex() const in GetArgIndex() 74 uint32_t Inst::GetPc() const in GetPc() 79 BasicBlock Inst::GetBasicBlock() const in GetBasicBlock() [all …]
|
/arkcompiler/runtime_core/compiler/optimizer/ir/ |
D | graph_checker.h | 62 void CheckPhiInputs(Inst *phi_inst); 69 bool CheckInstHasInput(Inst *inst, Inst *input); 70 bool CheckInstHasUser(Inst *inst, Inst *user); 72 void CheckSpillFillHolder(Inst *inst); 73 bool CheckInstRegUsageSaved(const Inst *inst, Register reg) const; 86 …void CheckObjectRec(const Inst *object, const Inst *user, const BasicBlock *block, Inst *start_fro… 88 void FindObjectInSaveState(const Inst *object, Inst *ss) const; 90 … void CheckSaveStateOsrRec(const Inst *inst, const Inst *user, BasicBlock *block, Marker visited); 115 static void VisitReturn([[maybe_unused]] GraphVisitor *v, Inst *inst); 116 static void VisitIf([[maybe_unused]] GraphVisitor *v, Inst *inst); [all …]
|
D | inst.cpp | 24 void Inst::ReserveInputs(size_t capacity) in ReserveInputs() 30 Inst *User::GetInst() in GetInst() 34 return *reinterpret_cast<Inst **>(this + GetIndex() + 1); in GetInst() 41 return reinterpret_cast<Inst *>(p); in GetInst() 44 void Inst::InsertBefore(Inst *inst) in InsertBefore() 50 void Inst::InsertAfter(Inst *inst) in InsertAfter() 64 auto size = new_capacity * (sizeof(User) + sizeof(Inst *)) + sizeof(Inst *); in Reallocate() 69 *reinterpret_cast<Inst **>(reinterpret_cast<User *>(new_stor) + new_capacity) = owner_inst; in Reallocate() 81 …Inst *old_input = old_inputs[i].GetInst(); // NOLINT(cppcoreguidelines-pro-bounds-pointer-arithme… in Reallocate() 101 unsigned DynamicOperands::Append(Inst *inst) in Append() [all …]
|
D | basicblock.h | 194 BasicBlock *SplitBlockAfterInstruction(Inst *inst, bool make_edge); 240 void AddInst(Inst *inst); 242 void PrependInst(Inst *inst) in PrependInst() 247 void AppendInst(Inst *inst) in AppendInst() 254 void AppendRangeInst(Inst *range_first, Inst *range_last); 256 void AppendPhi(Inst *inst); 258 void InsertAfter(Inst *inst, Inst *after); 260 void InsertBefore(Inst *inst, Inst *before); 264 void InsertRangeBefore(Inst *range_first, Inst *range_last, Inst *before); 266 void EraseInst(Inst *inst, [[maybe_unused]] bool will_be_moved = false); [all …]
|
D | inst.h | 39 class Inst; variable 46 using InstVector = ArenaVector<Inst *>; 341 explicit Input(Inst *inst) : inst_(inst) {} in Input() 343 Inst *GetInst() in GetInst() 347 const Inst *GetInst() const in GetInst() 358 Inst *inst_ {nullptr}; 381 Inst *GetInst(); 382 const Inst *GetInst() const in GetInst() 387 Inst *GetInput(); 388 const Inst *GetInput() const; [all …]
|
D | graph_visitor.h | 68 virtual void VisitInstruction(Inst *inst) = 0; 80 using VisitFunc = void (*)(GraphVisitor *, Inst *); 85 virtual void VisitDefault([[maybe_unused]] Inst *inst) {} in VisitDefault() 89 static void Visit##OPCODE(GraphVisitor *v, Inst *i) \
|
D | basicblock.cpp | 23 class Inst; 52 BasicBlock *BasicBlock::SplitBlockAfterInstruction(Inst *inst, bool make_edge) in SplitBlockAfterInstruction() 351 void BasicBlock::AppendPhi(Inst *inst) in AppendPhi() 366 Inst *prev = first_inst_->GetPrev(); in AppendPhi() 383 void BasicBlock::AddInst(Inst *inst) in AddInst() 416 void BasicBlock::AppendRangeInst(Inst *range_first, Inst *range_last) in AppendRangeInst() 448 void BasicBlock::InsertAfter(Inst *inst, Inst *after) in InsertAfter() 455 Inst *next = after->GetNext(); in InsertAfter() 467 void BasicBlock::InsertBefore(Inst *inst, Inst *before) in InsertBefore() 474 Inst *prev = before->GetPrev(); in InsertBefore() [all …]
|
D | graph_cloner.h | 27 class Inst; variable 46 using PhiInputsMap = ArenaUnorderedMap<Inst *, Inst *>; 177 void UpdateUsersForClonedLoopHeader(Inst *inst, BasicBlock *outer_block); 192 bool HasClone(Inst *inst) in HasClone() 197 Inst *GetClone(Inst *inst) in GetClone() 256 Inst *CloneInstruction(Inst *inst, size_t *inst_count, Graph *target_graph) in CloneInstruction() 269 inline bool IsInstLoopHeaderPhi(Inst *inst, Loop *loop); 277 void SetCloneInputs(Inst *inst, BasicBlock *block = nullptr) 326 void UpdateCaller(Inst *inst);
|
/arkcompiler/runtime_core/libark_defect_scan_aux/include/ |
D | graph.h | 30 class Inst { 32 explicit Inst(const compiler::Inst *inst) : inst_(inst) in Inst() function 36 ~Inst() = default; 38 bool operator==(const Inst &inst) const; 39 bool operator!=(const Inst &inst) const; 49 std::vector<Inst> GetInputInsts() const; 50 std::vector<Inst> GetUserInsts() const; 54 InstType GetInstType(const compiler::Inst *inst); 56 const compiler::Inst *inst_ {nullptr}; 71 std::vector<Inst> GetInstList() const; [all …]
|
D | abc_file.h | 47 using FuncInstPair = std::pair<const Function *, Inst>; 65 ssize_t GetLineNumberByInst(const Function *func, const Inst &inst) const; 77 std::string GetStringByInst(const Inst &inst) const; 106 ResolveResult ResolveInstCommon(const Function *func, Inst inst) const; 107 ResolveResult HandleLdObjByNameInstResolveResult(const Inst &ldobjbyname_inst, 110 Function *ResolveDefineFuncInstCommon(const Function *func, const Inst &def_func_inst) const; 111 …std::unique_ptr<Class> ResolveDefineClassWithBufferInst(Function *func, const Inst &define_class_i… 112 std::unique_ptr<CalleeInfo> ResolveCallInstCommon(Function *func, const Inst &call_inst, 114 std::unique_ptr<CalleeInfo> ResolveSuperCallInst(Function *func, const Inst &call_inst) const;
|
/arkcompiler/runtime_core/bytecode_optimizer/ |
D | reg_acc_alloc.cpp | 26 bool IsAccWriteBetween(compiler::Inst *src_inst, compiler::Inst *dst_inst) in IsAccWriteBetween() 31 compiler::Inst *inst = src_inst->GetNext(); in IsAccWriteBetween() 60 compiler::Inst *input = inst->GetInput(AccReadIndex(inst)).GetInst(); in IsAccWriteBetween() 77 inline bool RegAccAlloc::IsPhiOptimizable(compiler::Inst *phi) const in IsPhiOptimizable() 86 bool RegAccAlloc::IsAccRead(compiler::Inst *inst) const in IsAccRead() 94 bool RegAccAlloc::IsAccWrite(compiler::Inst *inst) const in IsAccWrite() 105 bool RegAccAlloc::CanUserReadAcc(compiler::Inst *inst, compiler::Inst *user) const in CanUserReadAcc() 120 compiler::Inst *uinput = input.GetInst(); in CanUserReadAcc() 145 bool RegAccAlloc::IsPhiAccReady(compiler::Inst *phi) const in IsPhiAccReady() 152 compiler::Inst *phi_input = input.GetInst(); in IsPhiAccReady() [all …]
|
D | codegen.h | 33 using compiler::Inst; 96 void AddLineNumber(const Inst *inst, const size_t idx); 97 void AddColumnNumber(const Inst *inst, const uint32_t idx); 103 static void VisitSpillFill(GraphVisitor *visitor, Inst *inst); 104 static void VisitConstant(GraphVisitor *visitor, Inst *inst); 105 static void VisitCatchPhi(GraphVisitor *visitor, Inst *inst); 107 static void VisitIf(GraphVisitor *v, Inst *inst_base); 108 static void VisitIfImm(GraphVisitor *v, Inst *inst_base); 109 static void IfImmZero(GraphVisitor *v, Inst *inst_base); 110 static void VisitIntrinsic(GraphVisitor *visitor, Inst *inst_base); [all …]
|
D | reg_acc_alloc.h | 46 bool IsPhiOptimizable(compiler::Inst *phi) const; 47 bool IsAccRead(compiler::Inst *inst) const; 48 bool IsAccWrite(compiler::Inst *inst) const; 50 bool CanUserReadAcc(compiler::Inst *inst, compiler::Inst *user) const; 51 bool IsPhiAccReady(compiler::Inst *phi) const; 52 void SetNeedLda(compiler::Inst *inst, bool need);
|
D | reg_encoder.h | 95 using panda::compiler::Inst; 116 void Check4Width(compiler::Inst *inst); 117 void Check8Width(compiler::Inst *inst); 124 static void VisitIntrinsic(GraphVisitor *visitor, Inst *inst); 130 void VisitDefault(Inst *inst) override {} in VisitDefault() 136 void CalculateNumNeededTempsForInst(compiler::Inst *inst); 140 void InsertSpillsForInst(compiler::Inst *inst); 141 void InsertSpillsForDynInputsInst(compiler::Inst *inst); 177 static void CallHelper(compiler::GraphVisitor *visitor, Inst *inst) in CallHelper()
|
/arkcompiler/runtime_core/compiler/optimizer/optimizations/regalloc/ |
D | reg_alloc_resolver.h | 39 void ResolveInputs(Inst *inst); 40 void ResolveOutput(Inst *inst); 47 void AddCatchPhiMoves(Inst *inst); 49 Inst *SqueezeCatchPhiInputs(CatchPhiInst *catch_phi); 51 bool CanStoreToAccumulator(const Inst *inst) const in CanStoreToAccumulator() 55 bool CanReadFromAccumulator(const Inst *inst, size_t input_number) const in CanReadFromAccumulator() 62 void FillSaveStateRootsMask(SaveStateInst *save_state, Inst *user, SaveStateInst *target_ss); 64 void AddMoveToFixedLocation(Inst *inst, Location input_location, size_t input_num);
|
D | reg_alloc_resolver.cpp | 47 void RegAllocResolver::AddCatchPhiMoves(Inst *inst) in AddCatchPhiMoves() 79 void RegAllocResolver::ResolveInputs(Inst *inst) in ResolveInputs() 123 void RegAllocResolver::AddMoveToFixedLocation(Inst *inst, Location input_location, size_t input_num) in AddMoveToFixedLocation() 144 Inst *GetFirstUserOrInst(Inst *inst) in GetFirstUserOrInst() 159 Inst *GetExplicitUser(Inst *inst) in GetExplicitUser() 168 Inst *user_inst {nullptr}; in GetExplicitUser() 189 void RegAllocResolver::FillSaveStateRootsMask(SaveStateInst *save_state, Inst *user, SaveStateInst … in FillSaveStateRootsMask() 221 void RegAllocResolver::ResolveOutput(Inst *inst) in ResolveOutput() 291 Inst *RegAllocResolver::SqueezeCatchPhiInputs(CatchPhiInst *catch_phi) in SqueezeCatchPhiInputs()
|
/arkcompiler/runtime_core/compiler/optimizer/analysis/ |
D | liveness_analyzer.h | 30 class Inst; variable 91 LifeIntervals(ArenaAllocator *allocator, Inst *inst) : LifeIntervals(allocator, inst, {}) {} in LifeIntervals() 93 LifeIntervals(ArenaAllocator *allocator, Inst *inst, LiveRange live_range) in LifeIntervals() 281 Inst *GetInst() const in GetInst() 395 Inst *inst_ {nullptr}; 468 LifeIntervals *GetInstLifeIntervals(const Inst *inst) const; 470 Inst *GetInstByLifeNumber(LifeNumber ln) const in GetInstByLifeNumber() 504 void EnumerateLiveIntervalsForInst(Inst *inst, Func func) in EnumerateLiveIntervalsForInst() 537 bool IsCallBlockingRegisters(Inst *inst) const; 565 void AdjustInputsLifetime(Inst *inst, LiveRange live_range, InstLiveSet *live_set); [all …]
|
/arkcompiler/runtime_core/compiler/tests/ |
D | iterators_test.cpp | 26 void Check(std::vector<Inst *> &tested_instructions) in Check() 33 std::vector<Inst *> result; in Check() 154 void InitExpectData(std::vector<Inst *> &instructions) in InitExpectData() 171 void PopulateBlock(BasicBlock *block, std::vector<Inst *> &instructions) in PopulateBlock() 183 std::vector<Inst *> expect_phis_; 184 std::vector<Inst *> expect_insts_; 185 std::vector<Inst *> expect_all_; 197 std::vector<Inst *> instructions; in TEST_F() 210 std::vector<Inst *> instructions(IteratorsTest::INST_COUNT); in TEST_F() 226 std::vector<Inst *> instructions(IteratorsTest::INST_COUNT); in TEST_F() [all …]
|
D | inst_generator.h | 30 Graph *GenerateGraph(Inst *inst); 60 Graph *GenerateOperation(Inst *inst, int32_t n); 61 Graph *GenerateCheckOperation(Inst *inst); 62 Graph *GenerateSSOperation(Inst *inst); 63 Graph *GenerateBoundaryCheckOperation(Inst *inst); 64 Graph *GenerateThrowOperation(Inst *inst); 65 Graph *GenerateMultiArrayOperation(Inst *inst); 66 Graph *GeneratePhiOperation(Inst *inst); 87 std::vector<Inst *> &Generate(Opcode OpCode); 115 std::vector<Inst *> &GenerateOperations(Opcode OpCode); [all …]
|
/arkcompiler/runtime_core/bytecode_optimizer/templates/ |
D | check_width.h.erb | 18 static void VisitIf([[maybe_unused]] GraphVisitor* v, Inst* inst_base); 19 static void VisitIfImm([[maybe_unused]] GraphVisitor* v, Inst* inst_base); 20 static void VisitCast([[maybe_unused]] GraphVisitor* v, Inst* inst_base); 24 static void Visit<%= visitor.ir_op %>([[maybe_unused]] GraphVisitor* v, Inst* inst_base);
|