[Mlir-commits] [mlir] [MLIR] Make `OneShotModuleBufferize` use `OpInterface` (PR #110322)

llvmlistbot at llvm.org llvmlistbot at llvm.org
Fri Sep 27 13:20:26 PDT 2024


================
@@ -255,6 +255,9 @@ static void equivalenceAnalysis(FunctionOpInterface funcOp,
                                 OneShotAnalysisState &state,
                                 FuncAnalysisState &funcState) {
   funcOp->walk([&](CallOpInterface callOp) {
+    if (isa<func::CallIndirectOp>(callOp))
+      return WalkResult::skip();
+
     FunctionOpInterface calledFunction = getCalledFunction(callOp);
     assert(calledFunction && "could not retrieved called FunctionOpInterface");
----------------
erick-xanadu wrote:

```suggestion
    FunctionOpInterface calledFunction = getCalledFunction(callOp);
    if (!calledFunction)
      return WalkResult::skip();
```

https://github.com/llvm/llvm-project/pull/110322


More information about the Mlir-commits mailing list