13 #ifndef CIRCT_CONVERSION_IMPORTVERILOG_H
14 #define CIRCT_CONVERSION_IMPORTVERILOG_H
143 mlir::TimingScope &ts, mlir::ModuleOp module,
150 mlir::TimingScope &ts, llvm::raw_ostream &os,
The InstanceGraph op interface, see InstanceGraphInterface.td for more details.
std::string getSlangVersion()
Return a human-readable string describing the slang frontend version linked into CIRCT.
mlir::LogicalResult importVerilog(llvm::SourceMgr &sourceMgr, mlir::MLIRContext *context, mlir::TimingScope &ts, mlir::ModuleOp module, const ImportVerilogOptions *options=nullptr)
Parse files in a source manager as Verilog source code and populate the given MLIR module with corres...
mlir::LogicalResult preprocessVerilog(llvm::SourceMgr &sourceMgr, mlir::MLIRContext *context, mlir::TimingScope &ts, llvm::raw_ostream &os, const ImportVerilogOptions *options=nullptr)
Run the files in a source manager through Slang's Verilog preprocessor and emit the result to the giv...
void registerFromVerilogTranslation()
Register the import-verilog MLIR translation.
Options that control how Verilog input files are parsed and processed.
std::vector< std::string > libraryFiles
A list of library files to include in the compilation.
std::optional< bool > allowUseBeforeDeclare
If true, allow various to be referenced before they are declared.
std::optional< uint32_t > maxIncludeDepth
The maximum depth of included files before an error is issued.
std::vector< std::string > warningOptions
A list of warning options that will be passed to the DiagnosticEngine.
std::vector< std::string > ignoreDirectives
A list of preprocessor directives to be ignored.
std::vector< std::string > libExts
A list of extensions that will be used to search for library files.
std::optional< bool > librariesInheritMacros
If true, library files will inherit macro definitions from primary source files.
std::vector< std::string > defines
A list of macros that should be defined in each compilation unit.
std::optional< bool > singleUnit
If set to true, all source files will be treated as part of a single compilation unit,...
std::vector< std::string > libDirs
A list of library directories in which to search for missing modules.
std::vector< std::string > suppressWarningsPaths
A list of paths in which to suppress warnings.
std::vector< std::string > includeSystemDirs
A list of system include directories in which to search for files.
std::vector< std::string > includeDirs
A list of include directories in which to search for files.
Mode
Limit importing to linting or parsing only.
@ OnlyLint
Only lint the input, without elaboration and lowering to CIRCT IR.
@ OnlyParse
Only parse and elaborate the input, without mapping to CIRCT IR.
@ Full
Perform a full import and mapping to CIRCT IR.
std::vector< std::string > undefines
A list of macros that should be undefined in each compilation unit.
std::vector< std::string > excludeExts
A list of extensions that will be used to exclude files.
std::vector< std::string > paramOverrides
A list of top-level module parameters to override, of the form <name>=<value>.
bool debugInfo
Generate debug information in the form of debug dialect ops in the IR.
std::optional< bool > ignoreUnknownModules
If true, ignore errors about unknown modules.
std::optional< std::string > timeScale
A string that indicates the default time scale to use for any design elements that don't specify one ...
std::vector< std::string > topModules
If non-empty, specifies the list of modules that should serve as the top modules in the design.
std::optional< uint32_t > errorLimit
The maximum number of errors to print before giving up.