FLANG
include
flang
Support
OpenMP-utils.h
1
//===-- include/flang/Support/OpenMP-utils.h --------------------*- C++ -*-===//
2
//
3
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4
// See https://llvm.org/LICENSE.txt for license information.
5
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6
//
7
//===----------------------------------------------------------------------===//
8
9
#ifndef FORTRAN_SUPPORT_OPENMP_UTILS_H_
10
#define FORTRAN_SUPPORT_OPENMP_UTILS_H_
11
12
#include "mlir/IR/Builders.h"
13
#include "mlir/IR/Value.h"
14
15
#include "llvm/ADT/ArrayRef.h"
16
#include "llvm/ADT/STLExtras.h"
17
18
namespace
Fortran::common::openmp {
21
struct
EntryBlockArgs
{
22
llvm::ArrayRef<mlir::Value>
hasDeviceAddrVars;
23
llvm::ArrayRef<mlir::Value>
hostEvalVars;
24
llvm::ArrayRef<mlir::Value>
inReductionVars;
25
llvm::ArrayRef<mlir::Value>
linearVars;
26
llvm::ArrayRef<mlir::Value>
mapVars;
27
llvm::ArrayRef<mlir::Value>
privVars;
28
llvm::ArrayRef<mlir::Value>
reductionVars;
29
llvm::ArrayRef<mlir::Value>
taskReductionVars;
30
llvm::ArrayRef<mlir::Value>
useDeviceAddrVars;
31
llvm::ArrayRef<mlir::Value>
useDevicePtrVars;
32
33
auto
getVars()
const
{
34
return
llvm::concat<const mlir::Value>(hasDeviceAddrVars, hostEvalVars,
35
inReductionVars, linearVars, mapVars, privVars, reductionVars,
36
taskReductionVars, useDeviceAddrVars, useDevicePtrVars);
37
}
38
};
39
47
mlir::Block *genEntryBlock(
48
mlir::OpBuilder &builder,
const
EntryBlockArgs
&args, mlir::Region ®ion);
49
}
// namespace Fortran::common::openmp
50
51
#endif
// FORTRAN_SUPPORT_OPENMP_UTILS_H_
llvm::ArrayRef
Definition
FIRType.h:106
Fortran::common::openmp::EntryBlockArgs
Definition
OpenMP-utils.h:21
Generated on
for FLANG by
1.14.0