[flang-commits] [flang] [flang][openmp] fix OMPFunctionFiltering pass after #87796 (PR #89776)
via flang-commits
flang-commits at lists.llvm.org
Wed Apr 24 06:24:12 PDT 2024
================
@@ -66,6 +67,12 @@ class OMPFunctionFilteringPass
SymbolTable::UseRange funcUses = *funcOp.getSymbolUses(op);
for (SymbolTable::SymbolUse use : funcUses) {
Operation *callOp = use.getUser();
+ if (mlir::isa<func::FuncOp>(callOp)) {
+ // Do not delete internal procedures holding the symbol of their
+ // Fortran host procedure as attribute.
+ callOp->removeAttr(fir::getHostSymbolAttrName());
----------------
jeanPerier wrote:
I updated to set the visibility to public, this is enough for MLIR not to remove it until the offload function is generated.
https://github.com/llvm/llvm-project/pull/89776
More information about the flang-commits
mailing list