MLIR
22.0.0git
|
Classes | |
struct | SourceLocation |
struct | SourceRange |
struct | ArgTypeTraits |
struct | ArgTypeTraits< const T & > |
struct | ArgTypeTraits< llvm::StringRef > |
struct | ArgTypeTraits< int64_t > |
struct | ArgTypeTraits< bool > |
struct | ArgTypeTraits< DynMatcher > |
class | MatcherDescriptor |
class | FixedArgCountMatcherDescriptor |
class | VariadicOperatorMatcherDescriptor |
class | Diagnostics |
class | Parser |
Functions | |
void | addError (Diagnostics *error, SourceRange range, ErrorType errorType, std::initializer_list< llvm::Twine > errorTexts) |
bool | checkArgCount (SourceRange nameRange, size_t expectedArgCount, llvm::ArrayRef< ParserValue > args, Diagnostics *error) |
template<typename ArgType , size_t Index> | |
bool | checkArgTypeAtIndex (llvm::StringRef matcherName, llvm::ArrayRef< ParserValue > args, Diagnostics *error) |
template<typename ReturnType , typename... ArgTypes, size_t... Is> | |
static VariantMatcher | matcherMarshallFixedImpl (void(*matcherFunc)(), llvm::StringRef matcherName, SourceRange nameRange, llvm::ArrayRef< ParserValue > args, Diagnostics *error, std::index_sequence< Is... >) |
template<typename ReturnType , typename... ArgTypes> | |
static VariantMatcher | matcherMarshallFixed (void(*matcherFunc)(), llvm::StringRef matcherName, SourceRange nameRange, llvm::ArrayRef< ParserValue > args, Diagnostics *error) |
template<typename ReturnType , typename... ArgTypes> | |
std::unique_ptr< MatcherDescriptor > | makeMatcherAutoMarshall (ReturnType(*matcherFunc)(ArgTypes...), llvm::StringRef matcherName) |
template<unsigned MinCount, unsigned MaxCount> | |
std::unique_ptr< MatcherDescriptor > | makeMatcherAutoMarshall (VariadicOperatorMatcherFunc< MinCount, MaxCount > func, StringRef matcherName) |
bool | allOfVariadicOperator (Operation *op, SetVector< Operation * > *matchedOps, ArrayRef< DynMatcher > innerMatchers) |
bool | anyOfVariadicOperator (Operation *op, SetVector< Operation * > *matchedOps, ArrayRef< DynMatcher > innerMatchers) |
static llvm::StringRef | errorTypeToFormatString (ErrorType type) |
static void | formatErrorString (llvm::StringRef formatString, llvm::ArrayRef< std::string > args, llvm::raw_ostream &os) |
static void | maybeAddLineAndColumn (SourceRange range, llvm::raw_ostream &os) |
Variables | |
const VariadicOperatorMatcherFunc< 1, std::numeric_limits< unsigned >::max()> | anyOf = {DynMatcher::AnyOf} |
const VariadicOperatorMatcherFunc< 1, std::numeric_limits< unsigned >::max()> | allOf = {DynMatcher::AllOf} |
|
strong |
Definition at line 36 of file ErrorBuilder.h.
void mlir::query::matcher::internal::addError | ( | Diagnostics * | error, |
SourceRange | range, | ||
ErrorType | errorType, | ||
std::initializer_list< llvm::Twine > | errorTexts | ||
) |
Definition at line 16 of file ErrorBuilder.cpp.
References mlir::query::matcher::internal::Diagnostics::addError().
Referenced by checkArgCount(), checkArgTypeAtIndex(), and mlir::query::matcher::internal::VariadicOperatorMatcherDescriptor::create().
bool mlir::query::matcher::internal::allOfVariadicOperator | ( | Operation * | op, |
SetVector< Operation * > * | matchedOps, | ||
ArrayRef< DynMatcher > | innerMatchers | ||
) |
Definition at line 15 of file MatchersInternal.cpp.
References mlir::query::matcher::DynMatcher::match().
bool mlir::query::matcher::internal::anyOfVariadicOperator | ( | Operation * | op, |
SetVector< Operation * > * | matchedOps, | ||
ArrayRef< DynMatcher > | innerMatchers | ||
) |
Definition at line 23 of file MatchersInternal.cpp.
References mlir::query::matcher::DynMatcher::match().
|
inline |
Definition at line 210 of file Marshallers.h.
References addError(), and RegistryWrongArgCount.
Referenced by matcherMarshallFixedImpl().
|
inline |
Definition at line 223 of file Marshallers.h.
References addError(), and RegistryWrongArgType.
|
static |
Definition at line 31 of file Diagnostics.cpp.
References None, ParserChainedExprInvalidArg, ParserChainedExprNoCloseParen, ParserChainedExprNoOpenParen, ParserFailedToBuildMatcher, ParserInvalidToken, ParserMalformedChainedExpr, ParserNoCloseParen, ParserNoCode, ParserNoComma, ParserNoOpenParen, ParserNotAMatcher, ParserOverloadedType, ParserStringError, ParserTrailingCode, RegistryMatcherNotFound, RegistryNotBindable, RegistryValueNotFound, RegistryWrongArgCount, and RegistryWrongArgType.
|
static |
Definition at line 79 of file Diagnostics.cpp.
std::unique_ptr<MatcherDescriptor> mlir::query::matcher::internal::makeMatcherAutoMarshall | ( | ReturnType(*)(ArgTypes...) | matcherFunc, |
llvm::StringRef | matcherName | ||
) |
Definition at line 271 of file Marshallers.h.
Referenced by mlir::query::matcher::Registry::registerMatcher().
std::unique_ptr<MatcherDescriptor> mlir::query::matcher::internal::makeMatcherAutoMarshall | ( | VariadicOperatorMatcherFunc< MinCount, MaxCount > | func, |
StringRef | matcherName | ||
) |
Definition at line 283 of file Marshallers.h.
References mlir::query::matcher::VariadicOperatorMatcherFunc< MinCount, MaxCount >::varOp.
|
static |
Definition at line 260 of file Marshallers.h.
References matcherMarshallFixedImpl().
|
static |
Definition at line 237 of file Marshallers.h.
References checkArgCount(), mlir::query::matcher::DynMatcher::constructDynMatcherFromMatcherFn(), and mlir::query::matcher::VariantMatcher::SingleMatcher().
Referenced by matcherMarshallFixed().
|
static |
Definition at line 102 of file Diagnostics.cpp.
References mlir::query::matcher::internal::SourceLocation::column, mlir::query::matcher::internal::SourceLocation::line, and mlir::query::matcher::internal::SourceRange::start.
const VariadicOperatorMatcherFunc<1, std::numeric_limits<unsigned>::max()> mlir::query::matcher::internal::allOf = {DynMatcher::AllOf} |
Definition at line 222 of file MatchersInternal.h.
const VariadicOperatorMatcherFunc<1, std::numeric_limits<unsigned>::max()> mlir::query::matcher::internal::anyOf = {DynMatcher::AnyOf} |
Definition at line 220 of file MatchersInternal.h.