[flang-commits] [flang] [flang][OpenMP] Fix construct privatization in default clause (PR #72510)

Leandro Lupori via flang-commits flang-commits at lists.llvm.org
Fri Nov 24 07:14:17 PST 2023


================
@@ -426,14 +425,10 @@ void DataSharingProcessor::collectSymbols(
                              /*collectSymbols=*/true,
                              /*collectHostAssociatedSymbols=*/true);
   for (Fortran::lower::pft::Evaluation &e : eval.getNestedEvaluations()) {
-    if (e.hasNestedEvaluations())
+    if (e.hasNestedEvaluations() && !e.isConstruct())
       converter.collectSymbolSet(e, symbolsInNestedRegions, flag,
                                  /*collectSymbols=*/true,
                                  /*collectHostAssociatedSymbols=*/false);
-    else
-      converter.collectSymbolSet(e, symbolsInParentRegions, flag,
-                                 /*collectSymbols=*/false,
-                                 /*collectHostAssociatedSymbols=*/true);
----------------
luporl wrote:

I guess not, because it's an `if (collectSymbol && oriSymbol.test(flag)`. Sorry for the noise.

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


More information about the flang-commits mailing list