We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 32a051d commit 8ae0ffbCopy full SHA for 8ae0ffb
mlir/lib/Dialect/Tosa/Transforms/TosaInferShapes.cpp
@@ -41,8 +41,9 @@ namespace {
41
// When a non-replaceable use is encountered, the value is wrapped in a
42
// cast back to the original type after inference.
43
bool canBeRefined(Operation *user) {
44
- Dialect *tosaDialect = user->getContext()->getLoadedDialect<TosaDialect>();
45
- return user->getDialect() == tosaDialect ||
+ if (!user->getDialect())
+ return false;
46
+ return user->getDialect()->getTypeID() == TypeID::get<TosaDialect>() ||
47
isa<InferTypeOpInterface, InferShapedTypeOpInterface>(user);
48
}
49
0 commit comments