[flang-commits] [flang] [Flang OpenMP] Add semantics checks for cray pointer usage in DSA list (PR #121028)
Krzysztof Parzyszek via flang-commits
flang-commits at lists.llvm.org
Tue Mar 25 11:06:36 PDT 2025
================
@@ -4522,6 +4525,22 @@ void OmpStructureChecker::CheckProcedurePointer(
}
}
+void OmpStructureChecker::CheckCrayPointee(
+ const parser::OmpObjectList &objectList, llvm::StringRef clause) {
+ SymbolSourceMap symbols;
+ GetSymbolsInObjectList(objectList, symbols);
+ for (auto it{symbols.begin()}; it != symbols.end(); ++it) {
+ const auto *symbol{it->first};
+ const auto source{it->second};
+ if (symbol->test(Symbol::Flag::CrayPointee)) {
+ context_.Say(source,
+ "Cray Pointee '%s' may not appear in %s clause, use Cray Pointer '%s' instead"_err_en_US,
+ symbol->name(), clause.str(),
+ semantics::GetCrayPointer(*symbol).name());
----------------
kparzysz wrote:
> is the same as the pointer.
is the same as the _target_ of the pointer.
https://github.com/llvm/llvm-project/pull/121028
More information about the flang-commits
mailing list