Home
last modified time | relevance | path

Searched refs:addSubst (Results 1 – 10 of 10) sorted by relevance

/llvm-project-15.0.7/mlir/unittests/TableGen/
H A DFormatTest.cpp128 ctx.addSubst("m", ""); in TEST()
136 ctx.addSubst("m", "0 "); in TEST()
137 ctx.addSubst("m1", "1 "); in TEST()
138 ctx.addSubst("m2C", "2 "); in TEST()
139 ctx.addSubst("M_3", "3 "); in TEST()
/llvm-project-15.0.7/mlir/tools/mlir-tblgen/
H A DOpInterfacesGen.cpp119 nonStaticMethodFmt.addSubst("_attr", castCode).withSelf(castCode); in AttrInterfaceGenerator()
120 traitMethodFmt.addSubst("_attr", in AttrInterfaceGenerator()
122 extraDeclsFmt.addSubst("_attr", "(*this)"); in AttrInterfaceGenerator()
133 nonStaticMethodFmt.addSubst("_this", "impl") in OpInterfaceGenerator()
149 nonStaticMethodFmt.addSubst("_type", castCode).withSelf(castCode); in TypeInterfaceGenerator()
150 traitMethodFmt.addSubst("_type", in TypeInterfaceGenerator()
152 extraDeclsFmt.addSubst("_type", "(*this)"); in TypeInterfaceGenerator()
H A DAttrOrTypeDefGen.cpp221 FmtContext ctx = FmtContext().addSubst("cppClass", def.getCppClassName()); in formatExtraDefinitions()
375 ctx.addSubst("_get", "Base::get"); in emitCustomBuilder()
377 ctx.addSubst("_ctxt", "context"); in emitCustomBuilder()
408 ctx.addSubst("_ctxt", "context"); in emitCheckedCustomBuilder()
471 ctx.addSubst(strfmt("_{0}", param.getName()), param.getName()); in emitStorageConstructor()
536 FmtContext ctx = FmtContext().addSubst("_allocator", "allocator"); in emitConstruct()
539 ctx.withSelf(param.getName()).addSubst("_dst", param.getName()); in emitConstruct()
H A DAttrOrTypeFormatGen.cpp67 ctx.addSubst("_lhs", self).addSubst("_rhs", valueStr); in genPrintGuard()
251 ctx.addSubst("_parser", "odsParser"); in genParser()
252 ctx.addSubst("_ctxt", "odsParser.getContext()"); in genParser()
255 ctx.addSubst("_type", "odsType"); in genParser()
272 ctx.addSubst("_loc", "odsLoc"); in genParser()
676 ctx.addSubst("_printer", "odsPrinter"); in genPrinter()
677 ctx.addSubst("_ctxt", "getContext()"); in genPrinter()
H A DOpDefinitionsGen.cpp581 ctx.addSubst(namedAttr.name, emitHelper.getAttr(namedAttr.name).str()); in populateSubstitutions()
587 ctx.addSubst(value.name, emitHelper.getOperand(i).str()); in populateSubstitutions()
594 ctx.addSubst(value.name, emitHelper.getResult(i).str()); in populateSubstitutions()
799 FmtContext ctx = FmtContext().addSubst("cppClass", op.getCppClassName()); in formatExtraDefinitions()
811 verifyCtx.addSubst("_ctxt", "this->getOperation()->getContext()"); in OpEmitter()
1078 .addSubst("_ctxt", "ctx")) in genAttrGetters()
1818 fctx.addSubst("_state", builderOpState); in genBuilder()
H A DSPIRVUtilsGen.cpp1247 fctx.addSubst("overall", "tblgen_overall"); in emitAvailabilityImpl()
1295 &fctx.addSubst("instance", avail.getMergeInstance()))) in emitAvailabilityImpl()
1347 &fctx.addSubst("instance", "*tblgen_instance"))) in emitAvailabilityImpl()
H A DRewriterGen.cpp490 tgfmt(fmt, &fmtCtx.addSubst("_loc", locToUse).withSelf(opName.str()), in emitNativeCodeMatch()
1273 std::string symbol = tgfmt(fmt, &fmtCtx.addSubst("_loc", locToUse), in handleReplaceWithNativeCodeCall()
H A DOpFormatGen.cpp1384 fmtContext.addSubst("_ctxt", "parser.getContext()"); in genParserTypeResolution()
/llvm-project-15.0.7/mlir/lib/TableGen/
H A DFormat.cpp28 addSubst(sub.first, sub.second); in FmtContext()
31 FmtContext &FmtContext::addSubst(StringRef placeholder, const Twine &subst) { in addSubst() function in FmtContext
/llvm-project-15.0.7/mlir/include/mlir/TableGen/
H A DFormat.h57 FmtContext &addSubst(StringRef placeholder, const Twine &subst);