| 1 | //===- MathToEmitC.h - Math to EmitC Patterns -------------------*- 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 MLIR_CONVERSION_MATHTOEMITC_MATHTOEMITC_H |
| 10 | #define MLIR_CONVERSION_MATHTOEMITC_MATHTOEMITC_H |
| 11 | namespace mlir { |
| 12 | class DialectRegistry; |
| 13 | class RewritePatternSet; |
| 14 | namespace emitc { |
| 15 | |
| 16 | /// Enum to specify the language target for EmitC code generation. |
| 17 | enum class LanguageTarget { c99, cpp11 }; |
| 18 | |
| 19 | } // namespace emitc |
| 20 | |
| 21 | void populateConvertMathToEmitCPatterns(RewritePatternSet &patterns, |
| 22 | emitc::LanguageTarget languageTarget); |
| 23 | |
| 24 | void registerConvertMathToEmitCInterface(DialectRegistry ®istry); |
| 25 | } // namespace mlir |
| 26 | |
| 27 | #endif // MLIR_CONVERSION_MATHTOEMITC_MATHTOEMITC_H |
| 28 | |