14 #ifndef CIRCT_CONVERSION_HWTOLLVM_HWTOLLVM_H
15 #define CIRCT_CONVERSION_HWTOLLVM_HWTOLLVM_H
22 class LLVMTypeConverter;
30 #define GEN_PASS_DECL_CONVERTHWTOLLVM
31 #include "circt/Conversion/Passes.h.inc"
50 mlir::LLVMTypeConverter &converter, RewritePatternSet &
patterns,
52 DenseMap<std::pair<Type, ArrayAttr>, mlir::LLVM::GlobalOp>
53 &constAggregateGlobalsMap);
A namespace that is used to store existing names and generate new names in some scope within the IR.
The InstanceGraph op interface, see InstanceGraphInterface.td for more details.
void populateHWToLLVMConversionPatterns(mlir::LLVMTypeConverter &converter, RewritePatternSet &patterns, Namespace &globals, DenseMap< std::pair< Type, ArrayAttr >, mlir::LLVM::GlobalOp > &constAggregateGlobalsMap)
Get the HW to LLVM conversion patterns.
std::unique_ptr< OperationPass< ModuleOp > > createConvertHWToLLVMPass()
Create an HW to LLVM conversion pass.
void populateHWToLLVMTypeConversions(mlir::LLVMTypeConverter &converter)
Get the HW to LLVM type conversions.
static uint32_t convertToLLVMEndianess(Type type, uint32_t index)
Convert an index into a HW ArrayType or StructType to LLVM Endianess.
static uint32_t llvmIndexOfStructField(hw::StructType type, StringRef fieldName)
Get the index of a specific StructType field in the LLVM lowering of the StructType.