diff --git a/mlir/include/mlir/Dialect/Bufferization/IR/BufferizableOpInterface.td b/mlir/include/mlir/Dialect/Bufferization/IR/BufferizableOpInterface.td --- a/mlir/include/mlir/Dialect/Bufferization/IR/BufferizableOpInterface.td +++ b/mlir/include/mlir/Dialect/Bufferization/IR/BufferizableOpInterface.td @@ -146,7 +146,7 @@ /*defaultImplementation=*/[{ assert(opResult.getDefiningOp() == $_op.getOperation() && "invalid OpResult"); - return bufferization::detail::defaultResultBufferizesToMemoryWrite( + return ::mlir::bufferization::detail::defaultResultBufferizesToMemoryWrite( opResult, state); }] >, @@ -167,7 +167,7 @@ "const ::mlir::bufferization::AnalysisState &":$state), /*methodBody=*/"", /*defaultImplementation=*/[{ - return opOperand.get().getType().isa(); + return opOperand.get().getType().isa<::mlir::UnrankedTensorType>(); }] >, InterfaceMethod< @@ -234,7 +234,7 @@ /*methodBody=*/"", /*defaultImplementation=*/[{ // Does not have to be implemented for ops without tensor OpOperands. - assert(opOperand.get().getType().isa() && + assert(opOperand.get().getType().isa<::mlir::TensorType>() && "expected OpOperand with tensor type"); llvm_unreachable("getAliasingOpResults not implemented"); }] @@ -305,7 +305,7 @@ "const ::mlir::bufferization::AnalysisState &":$state), /*methodBody=*/"", /*defaultImplementation=*/[{ - assert(opResult.getType().isa() && + assert(opResult.getType().isa<::mlir::TensorType>() && "expected OpResult with tensor type"); return ::mlir::bufferization::detail::defaultGetAliasingOpOperands( opResult, state); @@ -332,7 +332,7 @@ /*methodBody=*/"", /*defaultImplementation=*/[{ auto bufferizableOp = - cast($_op.getOperation()); + ::llvm::cast($_op.getOperation()); return bufferizableOp.resolveTensorOpOperandConflicts( rewriter, state); }] @@ -370,7 +370,7 @@ /*methodBody=*/"", /*defaultImplementation=*/[{ llvm_unreachable("bufferize not implemented"); - return failure(); + return ::mlir::failure(); }] >, InterfaceMethod< @@ -395,7 +395,7 @@ "const ::mlir::bufferization::AnalysisState &":$state), /*methodBody=*/"", /*defaultImplementation=*/[{ - return value.isa(); + return value.isa<::mlir::OpResult>(); }] >, InterfaceMethod< @@ -435,7 +435,7 @@ /*args=*/(ins "const ::mlir::bufferization::AnalysisState &":$state), /*methodBody=*/"", /*defaultImplementation=*/[{ - return success(); + return ::mlir::success(); }] >, InterfaceMethod< @@ -456,7 +456,7 @@ /*defaultImplementation=*/[{ assert(getOwnerOfValue(value) == $_op.getOperation() && "expected that value belongs to this op"); - return bufferization::detail::defaultGetBufferType( + return ::mlir::bufferization::detail::defaultGetBufferType( value, options, fixedTypes); }] >, @@ -480,7 +480,7 @@ /*methodBody=*/"", /*defaultImplementation=*/[{ return ::mlir::bufferization::detail::defaultIsRepetitiveRegion( - cast($_op.getOperation()), index); + ::llvm::cast($_op.getOperation()), index); }] > ]; @@ -502,7 +502,7 @@ ::mlir::OpOperand &opOperand, const ::mlir::bufferization::AnalysisState &state) { auto bufferizableOp = - cast<::mlir::bufferization::BufferizableOpInterface>(getOperation()); + ::llvm::cast<::mlir::bufferization::BufferizableOpInterface>(getOperation()); return !bufferizableOp.bufferizesToMemoryRead(opOperand, state) && !bufferizableOp.bufferizesToMemoryWrite(opOperand, state) && bufferizableOp.getAliasingOpResults(opOperand, state) diff --git a/mlir/include/mlir/Interfaces/SideEffectInterfaceBase.td b/mlir/include/mlir/Interfaces/SideEffectInterfaceBase.td --- a/mlir/include/mlir/Interfaces/SideEffectInterfaceBase.td +++ b/mlir/include/mlir/Interfaces/SideEffectInterfaceBase.td @@ -85,7 +85,7 @@ }] # baseEffect # [{>, 4> effects; getEffects(effects); return !effects.empty() && ::llvm::all_of(effects, [](const auto &it) { - return isa(it.getEffect()); + return ::llvm::isa(it.getEffect()); }); } @@ -115,7 +115,7 @@ }] # baseEffect # [{>, 4> effects; getEffects(effects); auto it = ::llvm::find_if(effects, [&](auto &it) { - return isa(it.getEffect()) && it.getValue() == value; + return ::llvm::isa(it.getEffect()) && it.getValue() == value; }); if (it == effects.end()) return std::nullopt;