================
@@ -457,6 +533,31 @@ cir::FuncOp lookupCallee(Operation *callOp, SymbolTable
&symbolTable) {
return symbolTable.lookup<cir::FuncOp>(callee.getValue());
}
+/// The callee pointer of an indirect cir.call / cir.try_call, or nullptr for a
+/// direct call. Both ops spell this the same way, but they inherit it from a
+/// shared TableGen base rather than a common C++ type, so reaching it needs
+/// this dispatch.
+mlir::Value indirectCallee(Operation *callOp) {
----------------
adams381 wrote:
Oh, that is much better. I've made the move along with `isIndirect()`, since
`getIndirectCall()` asserts on a direct call and the pass needs both to ask the
question through the interface.
https://github.com/llvm/llvm-project/pull/213315
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits