Skip to content

Commit 065b54c

Browse files
committed
clang-format
1 parent de93771 commit 065b54c

File tree

1 file changed

+43
-49
lines changed

1 file changed

+43
-49
lines changed

flang/lib/Lower/OpenMP/OpenMP.cpp

Lines changed: 43 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -1022,22 +1022,23 @@ static OpTy genOpWithBody(OpWithBodyGenInfo &info, Args &&...args) {
10221022
// Code generation functions for clauses
10231023
//===----------------------------------------------------------------------===//
10241024

1025-
static void genCriticalDeclareClauses(
1026-
Fortran::lower::AbstractConverter &converter,
1027-
Fortran::semantics::SemanticsContext &semaCtx,
1028-
const List<Clause> &clauses, mlir::Location loc,
1029-
mlir::omp::CriticalClauseOps &clauseOps, llvm::StringRef name) {
1025+
static void
1026+
genCriticalDeclareClauses(Fortran::lower::AbstractConverter &converter,
1027+
Fortran::semantics::SemanticsContext &semaCtx,
1028+
const List<Clause> &clauses, mlir::Location loc,
1029+
mlir::omp::CriticalClauseOps &clauseOps,
1030+
llvm::StringRef name) {
10301031
ClauseProcessor cp(converter, semaCtx, clauses);
10311032
cp.processHint(clauseOps);
10321033
clauseOps.nameAttr =
10331034
mlir::StringAttr::get(converter.getFirOpBuilder().getContext(), name);
10341035
}
10351036

1036-
static void genFlushClauses(
1037-
Fortran::lower::AbstractConverter &converter,
1038-
Fortran::semantics::SemanticsContext &semaCtx,
1039-
const ObjectList &objects, const List<Clause> &clauses,
1040-
mlir::Location loc, llvm::SmallVectorImpl<mlir::Value> &operandRange) {
1037+
static void genFlushClauses(Fortran::lower::AbstractConverter &converter,
1038+
Fortran::semantics::SemanticsContext &semaCtx,
1039+
const ObjectList &objects,
1040+
const List<Clause> &clauses, mlir::Location loc,
1041+
llvm::SmallVectorImpl<mlir::Value> &operandRange) {
10411042
if (!objects.empty())
10421043
genObjectList(objects, converter, operandRange);
10431044

@@ -1048,9 +1049,8 @@ static void genFlushClauses(
10481049
static void genLoopNestClauses(
10491050
Fortran::lower::AbstractConverter &converter,
10501051
Fortran::semantics::SemanticsContext &semaCtx,
1051-
Fortran::lower::pft::Evaluation &eval,
1052-
const List<Clause> &clauses, mlir::Location loc,
1053-
mlir::omp::LoopNestClauseOps &clauseOps,
1052+
Fortran::lower::pft::Evaluation &eval, const List<Clause> &clauses,
1053+
mlir::Location loc, mlir::omp::LoopNestClauseOps &clauseOps,
10541054
llvm::SmallVectorImpl<const Fortran::semantics::Symbol *> &iv) {
10551055
ClauseProcessor cp(converter, semaCtx, clauses);
10561056
cp.processCollapse(loc, eval, clauseOps, iv);
@@ -1069,9 +1069,9 @@ genOrderedRegionClauses(Fortran::lower::AbstractConverter &converter,
10691069
static void genParallelClauses(
10701070
Fortran::lower::AbstractConverter &converter,
10711071
Fortran::semantics::SemanticsContext &semaCtx,
1072-
Fortran::lower::StatementContext &stmtCtx,
1073-
const List<Clause> &clauses, mlir::Location loc,
1074-
bool processReduction, mlir::omp::ParallelClauseOps &clauseOps,
1072+
Fortran::lower::StatementContext &stmtCtx, const List<Clause> &clauses,
1073+
mlir::Location loc, bool processReduction,
1074+
mlir::omp::ParallelClauseOps &clauseOps,
10751075
llvm::SmallVectorImpl<mlir::Type> &reductionTypes,
10761076
llvm::SmallVectorImpl<const Fortran::semantics::Symbol *> &reductionSyms) {
10771077
ClauseProcessor cp(converter, semaCtx, clauses);
@@ -1136,9 +1136,8 @@ static void genSingleClauses(Fortran::lower::AbstractConverter &converter,
11361136
static void genTargetClauses(
11371137
Fortran::lower::AbstractConverter &converter,
11381138
Fortran::semantics::SemanticsContext &semaCtx,
1139-
Fortran::lower::StatementContext &stmtCtx,
1140-
const List<Clause> &clauses, mlir::Location loc,
1141-
bool processHostOnlyClauses, bool processReduction,
1139+
Fortran::lower::StatementContext &stmtCtx, const List<Clause> &clauses,
1140+
mlir::Location loc, bool processHostOnlyClauses, bool processReduction,
11421141
mlir::omp::TargetClauseOps &clauseOps,
11431142
llvm::SmallVectorImpl<const Fortran::semantics::Symbol *> &mapSyms,
11441143
llvm::SmallVectorImpl<mlir::Location> &mapLocs,
@@ -1708,10 +1707,11 @@ genTargetDataOp(Fortran::lower::AbstractConverter &converter,
17081707
}
17091708

17101709
template <typename OpTy>
1711-
static OpTy genTargetEnterExitUpdateDataOp(
1712-
Fortran::lower::AbstractConverter &converter,
1713-
Fortran::semantics::SemanticsContext &semaCtx, mlir::Location loc,
1714-
const List<Clause> &clauses) {
1710+
static OpTy
1711+
genTargetEnterExitUpdateDataOp(Fortran::lower::AbstractConverter &converter,
1712+
Fortran::semantics::SemanticsContext &semaCtx,
1713+
mlir::Location loc,
1714+
const List<Clause> &clauses) {
17151715
fir::FirOpBuilder &firOpBuilder = converter.getFirOpBuilder();
17161716
Fortran::lower::StatementContext stmtCtx;
17171717

@@ -1852,37 +1852,34 @@ genWsloopOp(Fortran::lower::AbstractConverter &converter,
18521852
static void genCompositeDistributeParallelDo(
18531853
Fortran::lower::AbstractConverter &converter,
18541854
Fortran::semantics::SemanticsContext &semaCtx,
1855-
Fortran::lower::pft::Evaluation &eval,
1856-
const List<Clause> &beginClauses,
1855+
Fortran::lower::pft::Evaluation &eval, const List<Clause> &beginClauses,
18571856
const List<Clause> &endClauses, mlir::Location loc) {
18581857
TODO(loc, "Composite DISTRIBUTE PARALLEL DO");
18591858
}
18601859

18611860
static void genCompositeDistributeParallelDoSimd(
18621861
Fortran::lower::AbstractConverter &converter,
18631862
Fortran::semantics::SemanticsContext &semaCtx,
1864-
Fortran::lower::pft::Evaluation &eval,
1865-
const List<Clause> &beginClauses,
1863+
Fortran::lower::pft::Evaluation &eval, const List<Clause> &beginClauses,
18661864
const List<Clause> &endClauses, mlir::Location loc) {
18671865
TODO(loc, "Composite DISTRIBUTE PARALLEL DO SIMD");
18681866
}
18691867

1870-
static void genCompositeDistributeSimd(
1871-
Fortran::lower::AbstractConverter &converter,
1872-
Fortran::semantics::SemanticsContext &semaCtx,
1873-
Fortran::lower::pft::Evaluation &eval,
1874-
const List<Clause> &beginClauses,
1875-
const List<Clause> &endClauses, mlir::Location loc) {
1868+
static void
1869+
genCompositeDistributeSimd(Fortran::lower::AbstractConverter &converter,
1870+
Fortran::semantics::SemanticsContext &semaCtx,
1871+
Fortran::lower::pft::Evaluation &eval,
1872+
const List<Clause> &beginClauses,
1873+
const List<Clause> &endClauses, mlir::Location loc) {
18761874
TODO(loc, "Composite DISTRIBUTE SIMD");
18771875
}
18781876

1879-
static void
1880-
genCompositeDoSimd(Fortran::lower::AbstractConverter &converter,
1881-
Fortran::semantics::SemanticsContext &semaCtx,
1882-
Fortran::lower::pft::Evaluation &eval,
1883-
const List<Clause> &beginClauses,
1884-
const List<Clause> &endClauses,
1885-
mlir::Location loc) {
1877+
static void genCompositeDoSimd(Fortran::lower::AbstractConverter &converter,
1878+
Fortran::semantics::SemanticsContext &semaCtx,
1879+
Fortran::lower::pft::Evaluation &eval,
1880+
const List<Clause> &beginClauses,
1881+
const List<Clause> &endClauses,
1882+
mlir::Location loc) {
18861883
ClauseProcessor cp(converter, semaCtx, beginClauses);
18871884
cp.processTODO<clause::Aligned, clause::Allocate, clause::Linear,
18881885
clause::Order, clause::Safelen, clause::Simdlen>(
@@ -1903,8 +1900,7 @@ genCompositeTaskloopSimd(Fortran::lower::AbstractConverter &converter,
19031900
Fortran::semantics::SemanticsContext &semaCtx,
19041901
Fortran::lower::pft::Evaluation &eval,
19051902
const List<Clause> &beginClauses,
1906-
const List<Clause> &endClauses,
1907-
mlir::Location loc) {
1903+
const List<Clause> &endClauses, mlir::Location loc) {
19081904
TODO(loc, "Composite TASKLOOP SIMD");
19091905
}
19101906

@@ -2351,9 +2347,8 @@ static void genOMP(Fortran::lower::AbstractConverter &converter,
23512347
switch (leafDir) {
23522348
case llvm::omp::Directive::OMPD_distribute_parallel_do:
23532349
// 2.9.4.3 DISTRIBUTE PARALLEL Worksharing-Loop construct.
2354-
genCompositeDistributeParallelDo(converter, semaCtx, eval,
2355-
beginClauses, endClauses,
2356-
currentLocation);
2350+
genCompositeDistributeParallelDo(converter, semaCtx, eval, beginClauses,
2351+
endClauses, currentLocation);
23572352
break;
23582353
case llvm::omp::Directive::OMPD_distribute_parallel_do_simd:
23592354
// 2.9.4.4 DISTRIBUTE PARALLEL Worksharing-Loop SIMD construct.
@@ -2368,8 +2363,8 @@ static void genOMP(Fortran::lower::AbstractConverter &converter,
23682363
break;
23692364
case llvm::omp::Directive::OMPD_do_simd:
23702365
// 2.9.3.2 Worksharing-Loop SIMD construct.
2371-
genCompositeDoSimd(converter, semaCtx, eval, beginClauses,
2372-
endClauses, currentLocation);
2366+
genCompositeDoSimd(converter, semaCtx, eval, beginClauses, endClauses,
2367+
currentLocation);
23732368
break;
23742369
case llvm::omp::Directive::OMPD_taskloop_simd:
23752370
// 2.10.3 TASKLOOP SIMD construct.
@@ -2413,8 +2408,7 @@ static void genOMP(Fortran::lower::AbstractConverter &converter,
24132408
break;
24142409
case llvm::omp::Directive::OMPD_taskloop:
24152410
// 2.10.2 TASKLOOP construct.
2416-
genTaskloopOp(converter, semaCtx, eval, currentLocation,
2417-
beginClauses);
2411+
genTaskloopOp(converter, semaCtx, eval, currentLocation, beginClauses);
24182412
break;
24192413
case llvm::omp::Directive::OMPD_teams:
24202414
// 2.7 TEAMS construct.

0 commit comments

Comments
 (0)