• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 //===- OpenMPToLLVM.h - Utils to convert from the OpenMP dialect ----------===//
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 #ifndef MLIR_CONVERSION_OPENMPTOLLVM_OPENMPTOLLVM_H_
9 #define MLIR_CONVERSION_OPENMPTOLLVM_OPENMPTOLLVM_H_
10 
11 #include<memory>
12 
13 namespace mlir {
14 class LLVMTypeConverter;
15 class MLIRContext;
16 class ModuleOp;
17 template <typename T>
18 class OperationPass;
19 class OwningRewritePatternList;
20 
21 /// Populate the given list with patterns that convert from OpenMP to LLVM.
22 void populateOpenMPToLLVMConversionPatterns(MLIRContext *context,
23                                             LLVMTypeConverter &converter,
24                                             OwningRewritePatternList &patterns);
25 
26 /// Create a pass to convert OpenMP operations to the LLVMIR dialect.
27 std::unique_ptr<OperationPass<ModuleOp>> createConvertOpenMPToLLVMPass();
28 
29 } // namespace mlir
30 
31 #endif // MLIR_CONVERSION_OPENMPTOLLVM_OPENMPTOLLVM_H_
32