Lines Matching refs:Rule
95 static bool hasNoSimpleLoops(const LegalizeRule &Rule, const LegalityQuery &Q, in hasNoSimpleLoops() argument
97 switch (Rule.getAction()) { in hasNoSimpleLoops()
112 static bool mutationIsSane(const LegalizeRule &Rule, in mutationIsSane() argument
117 if (Rule.getAction() == Custom || Rule.getAction() == Legal) in mutationIsSane()
128 switch (Rule.getAction()) { in mutationIsSane()
138 if (Rule.getAction() == FewerElements) { in mutationIsSane()
147 } else if (Rule.getAction() == MoreElements) in mutationIsSane()
166 if (Rule.getAction() == NarrowScalar) { in mutationIsSane()
194 for (const LegalizeRule &Rule : Rules) { in apply() local
195 if (Rule.match(Query)) { in apply()
197 std::pair<unsigned, LLT> Mutation = Rule.determineMutation(Query); in apply()
198 LLVM_DEBUG(dbgs() << ".. .. " << Rule.getAction() << ", " in apply()
200 assert(mutationIsSane(Rule, Query, Mutation) && in apply()
202 assert(hasNoSimpleLoops(Rule, Query, Mutation) && "Simple loop detected"); in apply()
203 return {Rule.getAction(), Mutation.first, Mutation.second}; in apply()