Lines Matching refs:opName
76 void emitMatchLogic(DagNode tree, StringRef opName);
92 void emitStaticVerifierCall(StringRef funcName, StringRef opName,
100 void emitOpMatch(DagNode tree, StringRef opName, int depth);
105 void emitOperandMatch(DagNode tree, StringRef opName, StringRef operandName,
112 StringRef opName, int argIndex, int &operandIndex,
117 void emitAttributeMatch(DagNode tree, StringRef opName, int argIndex,
122 void emitMatchCheck(StringRef opName, const FmtObjectBase &matchFmt,
127 void emitMatchCheck(StringRef opName, const std::string &matchStr,
392 void PatternEmitter::emitStaticMatchCall(DagNode tree, StringRef opName) { in emitStaticMatchCall() argument
395 opName); in emitStaticMatchCall()
424 StringRef opName, StringRef arg, in emitStaticVerifierCall() argument
427 funcName, opName, arg, failureStr); in emitStaticVerifierCall()
433 void PatternEmitter::emitNativeCodeMatch(DagNode tree, StringRef opName, in emitNativeCodeMatch() argument
446 emitStaticMatchCall(tree, opName); in emitNativeCodeMatch()
490 tgfmt(fmt, &fmtCtx.addSubst("_loc", locToUse).withSelf(opName.str()), in emitNativeCodeMatch()
493 emitMatchCheck(opName, formatv("!::mlir::failed({0})", nativeCodeCall), in emitNativeCodeMatch()
529 verifier, opName, self, in emitNativeCodeMatch()
542 void PatternEmitter::emitOpMatch(DagNode tree, StringRef opName, int depth) { in emitOpMatch() argument
559 emitStaticMatchCall(tree, opName); in emitOpMatch()
565 opName, op.getQualCppClassName(), getCastedName()); in emitOpMatch()
572 castedName, opName, op.getQualCppClassName()); in emitOpMatch()
576 emitMatchCheck(opName, /*matchStr=*/castedName, in emitOpMatch()
634 emitAttributeMatch(tree, opName, i, depth); in emitOpMatch()
644 void PatternEmitter::emitOperandMatch(DagNode tree, StringRef opName, in emitOperandMatch() argument
672 verifier, opName, self.str(), in emitOperandMatch()
690 StringRef opName, int argIndex, in emitEitherOperandMatch() argument
718 opName, /*matchStr=*/argName, in emitEitherOperandMatch()
720 operandIndex++, opName)); in emitEitherOperandMatch()
727 emitOperandMatch(tree, opName, /*operandName=*/formatv("v{0}", i).str(), in emitEitherOperandMatch()
743 os << formatv("auto eitherOperand0 = {0}.getODSOperands({1});\n", opName, in emitEitherOperandMatch()
745 os << formatv("auto eitherOperand1 = {0}.getODSOperands({1});\n", opName, in emitEitherOperandMatch()
757 void PatternEmitter::emitAttributeMatch(DagNode tree, StringRef opName, in emitAttributeMatch() argument
766 opName, attr.getStorageType(), namedAttr->name); in emitAttributeMatch()
779 emitMatchCheck(opName, tgfmt("tblgen_attr", &fmtCtx), in emitAttributeMatch()
810 verifier, opName, "tblgen_attr", in emitAttributeMatch()
829 StringRef opName, const FmtObjectBase &matchFmt, in emitMatchCheck() argument
831 emitMatchCheck(opName, matchFmt.str(), failureFmt.str()); in emitMatchCheck()
834 void PatternEmitter::emitMatchCheck(StringRef opName, in emitMatchCheck() argument
839 os.scope("{\n", "\n}\n").os << "return rewriter.notifyMatchFailure(" << opName in emitMatchCheck()
844 void PatternEmitter::emitMatchLogic(DagNode tree, StringRef opName) { in emitMatchLogic() argument
847 emitMatch(tree, opName, depth); in emitMatchLogic()
861 opName, tgfmt(condition, &fmtCtx.withSelf(self.str())), in emitMatchLogic()
883 emitMatchCheck(opName, in emitMatchLogic()
907 opName, in emitMatchLogic()