• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /freebsd-12-stable/contrib/llvm-project/llvm/utils/TableGen/

Lines Matching refs:Rule

329 StringRef makeNameForAnonInstr(CombineRule &Rule) {
331 format("__anon%" PRIu64 "_%u", Rule.getID(), Rule.allocUID())));
334 StringRef makeDebugName(CombineRule &Rule, StringRef Name) {
335 return insertStrTab(Name.empty() ? makeNameForAnonInstr(Rule) : StringRef(Name));
338 StringRef makeNameForAnonPredicate(CombineRule &Rule) {
340 format("__anonpred%" PRIu64 "_%u", Rule.getID(), Rule.allocUID())));
349 NamedRegionTimer T("parseDefs", "Time spent parsing the defs", "Rule Parsing",
492 "Rule Parsing", "Time spent on rule parsing", TimeRegions);
659 std::unique_ptr<CombineRule> Rule =
662 if (!Rule->parseDefs())
664 if (!Rule->parseMatcher(Target))
667 Rule->reorientToRoots();
670 dbgs() << "Parsed rule defs/match for '" << Rule->getName() << "'\n";
671 Rule->getMatchDag().dump();
672 Rule->getMatchDag().writeDOTGraph(dbgs(), Rule->getName());
675 return Rule;
680 for (const auto &E : Rule->getMatchDag().edges()) {
698 if (Rule->getNumRoots() > 1) {
702 return Rule;
711 std::unique_ptr<CombineRule> Rule = makeCombineRule(*R);
712 if (Rule == nullptr) {
716 ActiveRules.emplace_back(std::move(Rule));
741 const CombineRule *Rule = Leaf.getTargetData<CombineRule>();
742 const Record &RuleDef = Rule->getDef();
744 OS << Indent << "// Rule: " << RuleDef.getName() << "\n"
745 << Indent << "if (!isRuleDisabled(" << Rule->getID() << ")) {\n";
758 Rule->declareExpansions(Expansions);
792 if (Rule->getMatchingFixupCode() &&
793 !Rule->getMatchingFixupCode()->getValue().empty()) {
803 << CodeExpander(Rule->getMatchingFixupCode()->getValue(), Expansions,
804 Rule->getMatchingFixupCode()->getLoc(), ShowExpansions)
831 (!Rule->getMatchingFixupCode() ||
832 Rule->getMatchingFixupCode()->getValue().empty())) {
861 for (const auto &Rule : Rules) {
863 for (const auto &Root : enumerate(Rule->getMatchDag().roots())) {
864 TreeBuilder.addLeaf(Rule->getName(), Root.index(), Rule->getMatchDag(),
865 Rule.get());
869 PrintFatalError(Rule->getDef().getLoc(), "All rules must have a root");
969 for (const auto &Rule : Rules)
970 for (const auto &I : Rule->matchdata_decls())