Skip to main content

Simulation Backends

Use Verilator by default. Use Icarus Verilog for lightweight smoke tests, or where installing Verilator is impractical. Use xezim for a 4-state simulator that checks concurrent SVA without a C++ build step.

Choose a backend​

CapabilityVerilatorIcarus 12xezim
SystemVerilog procedural codeYesYesYes
Concurrent SVA and cover propertyYesNoYes
interface class frameworksYesNoYes
RTL Buddy line/toggle coverageYesNoYes (statement-level)
cocotb through VPIYesYesYes (VCS-flavour VPI library)
Default waveformFSTVCDFST, with --fst

Verilator compiles a cycle-based simv binary. Icarus compiles a .vvp snapshot and runs it with vvp; RTL Buddy generates a simv wrapper so the rest of the flow is the same.

xezim parses, elaborates and simulates in one invocation. The compile runs xezim --compile, which stops after elaboration, so syntax and elaboration errors fail the compile as with the other backends. RTL Buddy then writes a simv wrapper that reruns the same command line without --compile. Both point --cache-dir at the build directory, so runs reuse the elaborated design. The wrapper also adds --error-exit: without it xezim exits 0 after $error or a failed assertion, so the exit status could not fail a test, with or without a PASS/FAIL marker. xezim prints every error-severity message as ** Error: <message> followed by a Time: … Scope: … line: a bare failed assertion as ** Error: Assertion error., an assertion's else $error(...) action block or a plain $error with its own message. assertions: true counts each of these, as it counts Verilator's %Error: … Assertion failed lines. Note that:

  • $dumpfile/$dumpvars do nothing without --wave. Put --wave, or --fst dump.fst, in the builder's compile-time options for the modes that need waves.
  • xezim stops at --max-time, 100 ms of simulated time by default. Raise it in compile-time for longer tests.
  • xezim is built from source: cargo build --release in a xezim checkout (Rust 1.92+). rb tool-check lists it as optional.

If a suite must run on Icarus, gate unsupported constructs. Use expected failures only when the failure mode is understood.

Select a builder​

The builder comes from, in order: --builder <name>, the test's builder:, the suite's builder:, the platform default.

Set simulator-family on the cfg-rtl-builder entry, or use an executable name RTL Buddy can infer it from. See Selecting the simulator builder.

Open waveforms​

Verilator writes dump.fst, Icarus writes dump.vcd, and xezim writes the file --fst names. rb wave opens the newest supported dump under artefacts/<test>/.

To convert an Icarus dump to FST after simulation, set wave-format: fst-postproc on the builder. If vcd2fst is missing, the VCD is kept.

Collect coverage​

RTL Buddy coverage supports Verilator and xezim and follows the platform-selected builder. Pass --builder <name> or make that builder the platform default; a suite- or test-level override alone is not enough. See Coverage uses the platform builder. xezim coverage is statement-level and has no expression metric; see Collect coverage with xezim.