Home
last modified time | relevance | path

Searched refs:NodeAddr (Results 1 – 25 of 31) sorted by relevance

12

/external/llvm/lib/Target/Hexagon/
DRDFGraph.h294 template <typename T> struct NodeAddr { struct
295 NodeAddr() : Addr(nullptr), Id(0) {} in NodeAddr() argument
296 NodeAddr(T A, NodeId I) : Addr(A), Id(I) {} in NodeAddr() argument
297 NodeAddr(const NodeAddr&) = default;
298 NodeAddr &operator= (const NodeAddr&) = default; argument
300 bool operator== (const NodeAddr<T> &NA) const {
304 bool operator!= (const NodeAddr<T> &NA) const {
309 template <typename S> NodeAddr(const NodeAddr<S> &NA) in NodeAddr() function
349 NodeAddr<NodeBase*> New();
427 void append(NodeAddr<NodeBase*> NA);
[all …]
DRDFGraph.cpp87 void printRefHeader(raw_ostream &OS, const NodeAddr<RefNode*> RA, in printRefHeader()
97 raw_ostream &operator<< (raw_ostream &OS, const Print<NodeAddr<DefNode*>> &P) { in operator <<()
115 raw_ostream &operator<< (raw_ostream &OS, const Print<NodeAddr<UseNode*>> &P) { in operator <<()
128 const Print<NodeAddr<PhiUseNode*>> &P) { in operator <<()
143 raw_ostream &operator<< (raw_ostream &OS, const Print<NodeAddr<RefNode*>> &P) { in operator <<()
192 for (NodeAddr<T> A : P.List) { in operator <<()
202 raw_ostream &operator<< (raw_ostream &OS, const Print<NodeAddr<PhiNode*>> &P) { in operator <<()
210 const Print<NodeAddr<StmtNode*>> &P) { in operator <<()
219 const Print<NodeAddr<InstrNode*>> &P) { in operator <<()
236 const Print<NodeAddr<BlockNode*>> &P) { in operator <<()
[all …]
DRDFDeadCode.cpp71 void DeadCodeElimination::scanInstr(NodeAddr<InstrNode*> IA, in scanInstr()
75 if (!isLiveInstr(NodeAddr<StmtNode*>(IA).Addr->getCode())) in scanInstr()
77 for (NodeAddr<RefNode*> RA : IA.Addr->members(DFG)) { in scanInstr()
83 void DeadCodeElimination::processDef(NodeAddr<DefNode*> DA, in processDef()
85 NodeAddr<InstrNode*> IA = DA.Addr->getOwner(DFG); in processDef()
86 for (NodeAddr<UseNode*> UA : IA.Addr->members_if(DFG.IsUse, DFG)) { in processDef()
90 for (NodeAddr<DefNode*> TA : DFG.getRelatedRefs(IA, DA)) in processDef()
94 void DeadCodeElimination::processUse(NodeAddr<UseNode*> UA, in processUse()
96 for (NodeAddr<DefNode*> DA : LV.getAllReachingDefs(UA)) { in processUse()
117 for (NodeAddr<BlockNode*> BA : DFG.getFunc().Addr->members(DFG)) in collect()
[all …]
DHexagonOptAddrMode.cpp77 bool processBlock(NodeAddr<BlockNode *> BA);
79 NodeAddr<UseNode *> UseN, unsigned UseMOnum);
83 bool canRemoveAddasl(NodeAddr<StmtNode *> AddAslSN, MachineInstr *MI,
85 void getAllRealUses(NodeAddr<StmtNode *> SN, NodeList &UNodeList);
86 bool allValidCandidates(NodeAddr<StmtNode *> SA, NodeList &UNodeList);
88 void updateMap(NodeAddr<InstrNode *> IA);
93 bool changeAddAsl(NodeAddr<UseNode *> AddAslUN, MachineInstr *AddAslMI,
139 bool HexagonOptAddrMode::canRemoveAddasl(NodeAddr<StmtNode *> AddAslSN, in canRemoveAddasl()
150 for (NodeAddr<UseNode *> UA : AddAslSN.Addr->members_if(DFG->IsUse, *DFG)) { in canRemoveAddasl()
159 NodeAddr<UseNode *> UA = *I; in canRemoveAddasl()
[all …]
DRDFLiveness.cpp88 NodeAddr<RefNode*> RefA, bool FullChain, const RegisterSet &DefRRs) { in getAllReachingDefs()
120 if (auto RD = NodeAddr<RefNode*>(S).Addr->getReachingDef()) in getAllReachingDefs()
137 auto Block = [this] (NodeAddr<InstrNode*> IA) -> MachineBasicBlock* { in getAllReachingDefs()
139 return NodeAddr<StmtNode*>(IA).Addr->getCode()->getParent(); in getAllReachingDefs()
141 NodeAddr<PhiNode*> PA = IA; in getAllReachingDefs()
142 NodeAddr<BlockNode*> BA = PA.Addr->getOwner(DFG); in getAllReachingDefs()
159 auto CA = NodeAddr<StmtNode*>(OA).Addr->getCode(); in getAllReachingDefs()
160 auto CB = NodeAddr<StmtNode*>(OB).Addr->getCode(); in getAllReachingDefs()
195 auto DefInSet = [&Defs] (NodeAddr<RefNode*> TA) -> bool { in getAllReachingDefs()
205 for (NodeAddr<DefNode*> DA : TA.Addr->members_if(DefInSet, DFG)) { in getAllReachingDefs()
[all …]
DRDFLiveness.h40 NodeList getAllReachingDefs(RegisterRef RefRR, NodeAddr<RefNode*> RefA,
42 NodeList getAllReachingDefs(NodeAddr<RefNode*> RefA);
43 NodeSet getAllReachingDefsRec(RegisterRef RefRR, NodeAddr<RefNode*> RefA,
45 NodeSet getAllReachedUses(RegisterRef RefRR, NodeAddr<DefNode*> DefA,
99 bool isRestricted(NodeAddr<InstrNode*> IA, NodeAddr<RefNode*> RA,
101 RegisterRef getRestrictedRegRef(NodeAddr<RefNode*> RA) const;
DHexagonRDFOpt.cpp89 bool rewrite(NodeAddr<InstrNode*> IA, SetVector<NodeId> &Remove);
90 void removeOperand(NodeAddr<InstrNode*> IA, unsigned OpNum);
147 for (NodeAddr<BlockNode*> BA : DFG.getFunc().Addr->members(DFG)) { in run()
149 NodeAddr<StmtNode*> SA = TA; in run()
150 for (NodeAddr<RefNode*> RA : SA.Addr->members(DFG)) { in run()
175 void HexagonDCE::removeOperand(NodeAddr<InstrNode*> IA, unsigned OpNum) { in removeOperand()
176 MachineInstr *MI = NodeAddr<StmtNode*>(IA).Addr->getCode(); in removeOperand()
186 for (NodeAddr<RefNode*> RA : Refs) in removeOperand()
191 for (NodeAddr<RefNode*> RA : Refs) { in removeOperand()
201 bool HexagonDCE::rewrite(NodeAddr<InstrNode*> IA, SetVector<NodeId> &Remove) { in rewrite()
[all …]
DRDFCopy.cpp77 void CopyPropagation::recordCopy(NodeAddr<StmtNode*> SA, EqualityMap &EM) { in recordCopy()
92 void CopyPropagation::updateMap(NodeAddr<InstrNode*> IA) { in updateMap()
94 for (NodeAddr<RefNode*> RA : IA.Addr->members(DFG)) in updateMap()
122 for (NodeAddr<InstrNode*> IA : BA.Addr->members(DFG)) { in scanBlock()
124 NodeAddr<StmtNode*> SA = IA; in scanBlock()
182 for (NodeAddr<DefNode*> DA : SA.Addr->members_if(DFG.IsDef, DFG)) { in run()
203 NodeAddr<InstrNode*> IA = UA.Addr->getOwner(DFG); in run()
214 << *NodeAddr<StmtNode*>(IA).Addr->getCode(); in run()
DRDFDeadCode.h60 void scanInstr(NodeAddr<InstrNode*> IA, SetQueue<NodeId> &WorkQ);
61 void processDef(NodeAddr<DefNode*> DA, SetQueue<NodeId> &WorkQ);
62 void processUse(NodeAddr<UseNode*> UA, SetQueue<NodeId> &WorkQ);
/external/swiftshader/third_party/llvm-10.0/llvm/lib/Target/Hexagon/
DRDFGraph.h334 template <typename T> struct NodeAddr { struct
335 NodeAddr() = default;
336 NodeAddr(T A, NodeId I) : Addr(A), Id(I) {} in NodeAddr() function
340 template <typename S> NodeAddr(const NodeAddr<S> &NA) in NodeAddr() function
343 bool operator== (const NodeAddr<T> &NA) const {
347 bool operator!= (const NodeAddr<T> &NA) const {
391 NodeAddr<NodeBase*> New();
464 void append(NodeAddr<NodeBase*> NA);
512 using NodeList = SmallVector<NodeAddr<NodeBase *>, 4>;
553 NodeAddr<RefNode*> getNextRef(RegisterRef RR, Predicate P, bool NextOnly,
[all …]
DRDFGraph.cpp108 static void printRefHeader(raw_ostream &OS, const NodeAddr<RefNode*> RA, in printRefHeader()
116 raw_ostream &operator<< (raw_ostream &OS, const Print<NodeAddr<DefNode*>> &P) { in operator <<()
133 raw_ostream &operator<< (raw_ostream &OS, const Print<NodeAddr<UseNode*>> &P) { in operator <<()
145 const Print<NodeAddr<PhiUseNode*>> &P) { in operator <<()
159 raw_ostream &operator<< (raw_ostream &OS, const Print<NodeAddr<RefNode*>> &P) { in operator <<()
208 for (NodeAddr<T> A : P.List) { in operator <<()
218 raw_ostream &operator<< (raw_ostream &OS, const Print<NodeAddr<PhiNode*>> &P) { in operator <<()
224 raw_ostream &operator<<(raw_ostream &OS, const Print<NodeAddr<StmtNode *>> &P) { in operator <<()
250 const Print<NodeAddr<InstrNode*>> &P) { in operator <<()
266 const Print<NodeAddr<BlockNode*>> &P) { in operator <<()
[all …]
DRDFDeadCode.cpp82 void DeadCodeElimination::scanInstr(NodeAddr<InstrNode*> IA, in scanInstr()
86 if (!isLiveInstr(NodeAddr<StmtNode*>(IA).Addr->getCode())) in scanInstr()
88 for (NodeAddr<RefNode*> RA : IA.Addr->members(DFG)) { in scanInstr()
94 void DeadCodeElimination::processDef(NodeAddr<DefNode*> DA, in processDef()
96 NodeAddr<InstrNode*> IA = DA.Addr->getOwner(DFG); in processDef()
97 for (NodeAddr<UseNode*> UA : IA.Addr->members_if(DFG.IsUse, DFG)) { in processDef()
101 for (NodeAddr<DefNode*> TA : DFG.getRelatedRefs(IA, DA)) in processDef()
105 void DeadCodeElimination::processUse(NodeAddr<UseNode*> UA, in processUse()
107 for (NodeAddr<DefNode*> DA : LV.getAllReachingDefs(UA)) { in processUse()
128 for (NodeAddr<BlockNode*> BA : DFG.getFunc().Addr->members(DFG)) in collect()
[all …]
DHexagonOptAddrMode.cpp91 bool processBlock(NodeAddr<BlockNode *> BA);
93 NodeAddr<UseNode *> UseN, unsigned UseMOnum);
94 bool processAddUses(NodeAddr<StmtNode *> AddSN, MachineInstr *AddMI,
100 bool canRemoveAddasl(NodeAddr<StmtNode *> AddAslSN, MachineInstr &MI,
102 bool isSafeToExtLR(NodeAddr<StmtNode *> SN, MachineInstr *MI,
104 void getAllRealUses(NodeAddr<StmtNode *> SN, NodeList &UNodeList);
105 bool allValidCandidates(NodeAddr<StmtNode *> SA, NodeList &UNodeList);
110 bool changeAddAsl(NodeAddr<UseNode *> AddAslUN, MachineInstr *AddAslMI,
158 bool HexagonOptAddrMode::canRemoveAddasl(NodeAddr<StmtNode *> AddAslSN, in canRemoveAddasl()
169 for (NodeAddr<UseNode *> UA : AddAslSN.Addr->members_if(DFG->IsUse, *DFG)) { in canRemoveAddasl()
[all …]
DRDFLiveness.cpp107 NodeAddr<RefNode*> RefA, bool TopShadows, bool FullChain, in getAllReachingDefs()
130 if (NodeId RD = NodeAddr<RefNode*>(S).Addr->getReachingDef()) in getAllReachingDefs()
152 if (NodeId RD = NodeAddr<RefNode*>(S).Addr->getReachingDef()) in getAllReachingDefs()
169 auto Block = [this] (NodeAddr<InstrNode*> IA) -> MachineBasicBlock* { in getAllReachingDefs()
171 return NodeAddr<StmtNode*>(IA).Addr->getCode()->getParent(); in getAllReachingDefs()
173 NodeAddr<PhiNode*> PA = IA; in getAllReachingDefs()
174 NodeAddr<BlockNode*> BA = PA.Addr->getOwner(DFG); in getAllReachingDefs()
191 MachineInstr *CA = NodeAddr<StmtNode*>(OA).Addr->getCode(); in getAllReachingDefs()
192 MachineInstr *CB = NodeAddr<StmtNode*>(OB).Addr->getCode(); in getAllReachingDefs()
226 auto DefInSet = [&Defs] (NodeAddr<RefNode*> TA) -> bool { in getAllReachingDefs()
[all …]
DRDFLiveness.h58 NodeList getAllReachingDefs(RegisterRef RefRR, NodeAddr<RefNode*> RefA,
61 NodeList getAllReachingDefs(NodeAddr<RefNode*> RefA) { in getAllReachingDefs()
66 NodeList getAllReachingDefs(RegisterRef RefRR, NodeAddr<RefNode*> RefA) { in getAllReachingDefs()
70 NodeSet getAllReachedUses(RegisterRef RefRR, NodeAddr<DefNode*> DefA,
73 NodeSet getAllReachedUses(RegisterRef RefRR, NodeAddr<DefNode*> DefA) { in getAllReachedUses()
78 NodeAddr<RefNode*> RefA, NodeSet &Visited, const NodeSet &Defs);
80 NodeAddr<RefNode*> getNearestAliasedRef(RegisterRef RefRR,
81 NodeAddr<InstrNode*> IA);
141 NodeAddr<RefNode*> RefA, NodeSet &Visited, const NodeSet &Defs,
DHexagonRDFOpt.cpp95 bool rewrite(NodeAddr<InstrNode*> IA, SetVector<NodeId> &Remove);
96 void removeOperand(NodeAddr<InstrNode*> IA, unsigned OpNum);
163 for (NodeAddr<BlockNode*> BA : DFG.getFunc().Addr->members(DFG)) { in run()
165 NodeAddr<StmtNode*> SA = TA; in run()
166 for (NodeAddr<RefNode*> RA : SA.Addr->members(DFG)) { in run()
189 void HexagonDCE::removeOperand(NodeAddr<InstrNode*> IA, unsigned OpNum) { in removeOperand()
190 MachineInstr *MI = NodeAddr<StmtNode*>(IA).Addr->getCode(); in removeOperand()
201 for (NodeAddr<RefNode*> RA : Refs) in removeOperand()
206 for (NodeAddr<RefNode*> RA : Refs) { in removeOperand()
215 bool HexagonDCE::rewrite(NodeAddr<InstrNode*> IA, SetVector<NodeId> &Remove) { in rewrite()
[all …]
DRDFCopy.cpp63 void CopyPropagation::recordCopy(NodeAddr<StmtNode*> SA, EqualityMap &EM) { in recordCopy()
70 NodeAddr<BlockNode*> BA = DFG.findBlock(B); in scanBlock()
72 for (NodeAddr<InstrNode*> IA : BA.Addr->members(DFG)) { in scanBlock()
74 NodeAddr<StmtNode*> SA = IA; in scanBlock()
89 NodeAddr<InstrNode*> IA) { in getLocalReachingDef()
90 NodeAddr<RefNode*> RA = L.getNearestAliasedRef(RefRR, IA); in getLocalReachingDef()
144 for (NodeAddr<DefNode*> DA : SA.Addr->members_if(DFG.IsDef, DFG)) { in run()
164 NodeAddr<InstrNode*> IA = UA.Addr->getOwner(DFG); in run()
176 << *NodeAddr<StmtNode*>(IA).Addr->getCode(); in run()
/external/llvm-project/llvm/include/llvm/CodeGen/
DRDFGraph.h334 template <typename T> struct NodeAddr { struct
335 NodeAddr() = default;
336 NodeAddr(T A, NodeId I) : Addr(A), Id(I) {} in NodeAddr() argument
340 template <typename S> NodeAddr(const NodeAddr<S> &NA) in NodeAddr() argument
343 bool operator== (const NodeAddr<T> &NA) const {
347 bool operator!= (const NodeAddr<T> &NA) const {
391 NodeAddr<NodeBase*> New();
464 void append(NodeAddr<NodeBase*> NA);
512 using NodeList = SmallVector<NodeAddr<NodeBase *>, 4>;
553 NodeAddr<RefNode*> getNextRef(RegisterRef RR, Predicate P, bool NextOnly,
[all …]
DRDFLiveness.h83 NodeList getAllReachingDefs(RegisterRef RefRR, NodeAddr<RefNode*> RefA,
86 NodeList getAllReachingDefs(NodeAddr<RefNode*> RefA) {
91 NodeList getAllReachingDefs(RegisterRef RefRR, NodeAddr<RefNode*> RefA) {
95 NodeSet getAllReachedUses(RegisterRef RefRR, NodeAddr<DefNode*> DefA,
98 NodeSet getAllReachedUses(RegisterRef RefRR, NodeAddr<DefNode*> DefA) {
103 NodeAddr<RefNode*> RefA, NodeSet &Visited, const NodeSet &Defs);
105 NodeAddr<RefNode*> getNearestAliasedRef(RegisterRef RefRR,
106 NodeAddr<InstrNode*> IA);
165 NodeAddr<RefNode*> RefA, NodeSet &Visited, const NodeSet &Defs,
/external/llvm-project/llvm/lib/CodeGen/
DRDFGraph.cpp108 static void printRefHeader(raw_ostream &OS, const NodeAddr<RefNode*> RA, in printRefHeader()
116 raw_ostream &operator<< (raw_ostream &OS, const Print<NodeAddr<DefNode*>> &P) { in operator <<()
133 raw_ostream &operator<< (raw_ostream &OS, const Print<NodeAddr<UseNode*>> &P) { in operator <<()
145 const Print<NodeAddr<PhiUseNode*>> &P) { in operator <<()
159 raw_ostream &operator<< (raw_ostream &OS, const Print<NodeAddr<RefNode*>> &P) { in operator <<()
208 for (NodeAddr<T> A : P.List) { in operator <<()
218 raw_ostream &operator<< (raw_ostream &OS, const Print<NodeAddr<PhiNode*>> &P) { in operator <<()
224 raw_ostream &operator<<(raw_ostream &OS, const Print<NodeAddr<StmtNode *>> &P) { in operator <<()
250 const Print<NodeAddr<InstrNode*>> &P) { in operator <<()
266 const Print<NodeAddr<BlockNode*>> &P) { in operator <<()
[all …]
DRDFLiveness.cpp110 NodeAddr<RefNode*> RefA, bool TopShadows, bool FullChain, in getAllReachingDefs()
133 if (NodeId RD = NodeAddr<RefNode*>(S).Addr->getReachingDef()) in getAllReachingDefs()
155 if (NodeId RD = NodeAddr<RefNode*>(S).Addr->getReachingDef()) in getAllReachingDefs()
163 auto Block = [this] (NodeAddr<InstrNode*> IA) -> MachineBasicBlock* { in getAllReachingDefs()
165 return NodeAddr<StmtNode*>(IA).Addr->getCode()->getParent(); in getAllReachingDefs()
167 NodeAddr<PhiNode*> PA = IA; in getAllReachingDefs()
168 NodeAddr<BlockNode*> BA = PA.Addr->getOwner(DFG); in getAllReachingDefs()
176 std::map<NodeId, NodeAddr<InstrNode*>> Owners; in getAllReachingDefs()
184 NodeAddr<InstrNode*> IA = TA.Addr->getOwner(DFG); in getAllReachingDefs()
192 NodeAddr<InstrNode*> OA = DFG.addr<InstrNode*>(A); in getAllReachingDefs()
[all …]
/external/llvm-project/llvm/lib/Target/Hexagon/
DRDFDeadCode.cpp82 void DeadCodeElimination::scanInstr(NodeAddr<InstrNode*> IA, in scanInstr()
86 if (!isLiveInstr(NodeAddr<StmtNode*>(IA).Addr->getCode())) in scanInstr()
88 for (NodeAddr<RefNode*> RA : IA.Addr->members(DFG)) { in scanInstr()
94 void DeadCodeElimination::processDef(NodeAddr<DefNode*> DA, in processDef()
96 NodeAddr<InstrNode*> IA = DA.Addr->getOwner(DFG); in processDef()
97 for (NodeAddr<UseNode*> UA : IA.Addr->members_if(DFG.IsUse, DFG)) { in processDef()
101 for (NodeAddr<DefNode*> TA : DFG.getRelatedRefs(IA, DA)) in processDef()
105 void DeadCodeElimination::processUse(NodeAddr<UseNode*> UA, in processUse()
107 for (NodeAddr<DefNode*> DA : LV.getAllReachingDefs(UA)) { in processUse()
128 for (NodeAddr<BlockNode*> BA : DFG.getFunc().Addr->members(DFG)) in collect()
[all …]
DHexagonOptAddrMode.cpp91 bool processBlock(NodeAddr<BlockNode *> BA);
93 NodeAddr<UseNode *> UseN, unsigned UseMOnum);
94 bool processAddUses(NodeAddr<StmtNode *> AddSN, MachineInstr *AddMI,
100 bool canRemoveAddasl(NodeAddr<StmtNode *> AddAslSN, MachineInstr &MI,
102 bool isSafeToExtLR(NodeAddr<StmtNode *> SN, MachineInstr *MI,
104 void getAllRealUses(NodeAddr<StmtNode *> SN, NodeList &UNodeList);
105 bool allValidCandidates(NodeAddr<StmtNode *> SA, NodeList &UNodeList);
110 bool changeAddAsl(NodeAddr<UseNode *> AddAslUN, MachineInstr *AddAslMI,
158 bool HexagonOptAddrMode::canRemoveAddasl(NodeAddr<StmtNode *> AddAslSN, in canRemoveAddasl()
169 for (NodeAddr<UseNode *> UA : AddAslSN.Addr->members_if(DFG->IsUse, *DFG)) { in canRemoveAddasl()
[all …]
DHexagonRDFOpt.cpp95 bool rewrite(NodeAddr<InstrNode*> IA, SetVector<NodeId> &Remove);
96 void removeOperand(NodeAddr<InstrNode*> IA, unsigned OpNum);
163 for (NodeAddr<BlockNode*> BA : DFG.getFunc().Addr->members(DFG)) { in run()
165 NodeAddr<StmtNode*> SA = TA; in run()
166 for (NodeAddr<RefNode*> RA : SA.Addr->members(DFG)) { in run()
189 void HexagonDCE::removeOperand(NodeAddr<InstrNode*> IA, unsigned OpNum) { in removeOperand()
190 MachineInstr *MI = NodeAddr<StmtNode*>(IA).Addr->getCode(); in removeOperand()
201 for (NodeAddr<RefNode*> RA : Refs) in removeOperand()
206 for (NodeAddr<RefNode*> RA : Refs) { in removeOperand()
215 bool HexagonDCE::rewrite(NodeAddr<InstrNode*> IA, SetVector<NodeId> &Remove) { in rewrite()
[all …]
DRDFCopy.cpp63 void CopyPropagation::recordCopy(NodeAddr<StmtNode*> SA, EqualityMap &EM) { in recordCopy()
70 NodeAddr<BlockNode*> BA = DFG.findBlock(B); in scanBlock()
72 for (NodeAddr<InstrNode*> IA : BA.Addr->members(DFG)) { in scanBlock()
74 NodeAddr<StmtNode*> SA = IA; in scanBlock()
89 NodeAddr<InstrNode*> IA) { in getLocalReachingDef()
90 NodeAddr<RefNode*> RA = L.getNearestAliasedRef(RefRR, IA); in getLocalReachingDef()
144 for (NodeAddr<DefNode*> DA : SA.Addr->members_if(DFG.IsDef, DFG)) { in run()
164 NodeAddr<InstrNode*> IA = UA.Addr->getOwner(DFG); in run()
176 << *NodeAddr<StmtNode*>(IA).Addr->getCode(); in run()

12