tldr/pages/common/verilator.md

21 lines
743 B
Markdown
Raw Normal View History

2022-11-26 08:07:29 +00:00
# verilator
2022-11-28 18:36:58 +00:00
> Converts Verilog and SystemVerilog hardware description language (HDL) design into a C++ or SystemC model to be executed after compiling.
2022-11-26 08:07:29 +00:00
> More information: <https://veripool.org/guide/latest/>.
- Build a specific C project in the current directory:
`verilator --binary --build-jobs 0 -Wall {{path/to/source.v}}`
- Create a C++ executable in a specific folder:
`verilator --cc --exe --build --build-jobs 0 -Wall {{path/to/source.cpp}} {{path/to/output.v}}`
- Perform linting over a code in the current directory:
`verilator --lint-only -Wall`
- Create XML output about the design (files, modules, instance hierarchy, logic and data types) to feed into other tools:
`verilator --xml-output -Wall {{path/to/output.xml}}`