mirror of
https://github.com/intel/llvm.git
synced 2026-01-16 05:32:28 +08:00
[flang][openacc] Add parsing support for dim in gang clause
Add parsing supprot for dim in gang clause Depends on D151971 Reviewed By: razvanlupusoru, jeanPerier Differential Revision: https://reviews.llvm.org/D151972
This commit is contained in:
@@ -1908,9 +1908,19 @@ public:
|
||||
}
|
||||
}
|
||||
void Unparse(const AccClauseList &x) { Walk(" ", x.v, " "); }
|
||||
void Unparse(const AccGangArgument &x) {
|
||||
Walk("NUM:", std::get<std::optional<ScalarIntExpr>>(x.t));
|
||||
Walk(", STATIC:", std::get<std::optional<AccSizeExpr>>(x.t));
|
||||
void Unparse(const AccGangArgList &x) { Walk(x.v, ","); }
|
||||
void Before(const AccSizeExpr &x) {
|
||||
if (!x.v)
|
||||
Put("*");
|
||||
}
|
||||
void Before(const AccGangArg &x) {
|
||||
common::visit(common::visitors{
|
||||
[&](const AccGangArg::Num &) { Word("NUM:"); },
|
||||
[&](const AccGangArg::Dim &) { Word("DIM:"); },
|
||||
[&](const AccGangArg::Static &) { Word("STATIC:"); },
|
||||
[](const StatOrErrmsg &) {},
|
||||
},
|
||||
x.u);
|
||||
}
|
||||
void Unparse(const AccCollapseArg &x) {
|
||||
const auto &force{std::get<bool>(x.t)};
|
||||
|
||||
Reference in New Issue
Block a user