DVICode: DV Intelligence for VS Code
Free, open-source SystemVerilog and UVM navigation for VS Code.
Follow definitions across packages and class hierarchies, see what a macro expands to, and
explore your design and UVM testbench without starting a simulator. DVICode runs on your
desktop, in WSL, or beside your sources on a Linux server over SSH. Currently in preview.

Features
- Errors as you type: undeclared names, unknown types, members and ports, missing
includes and macros, syntax mistakes. No errors on UVM 1.2, OpenTitan, Ibex, core-v-verif,
CVA6 and PULP AXI with their own file lists.
- Go anywhere: definitions, references, implementations and overrides, through macros,
packages, class inheritance and port connections.
- Smart completion: members after
., package items after ::, macros after `,
and complete module instantiations in one step.
- Hover documentation: signatures, doc comments and what a macro expands to.
- Inlay hints: port, parameter and argument names on positional connections and calls.
- Override and implement: complete an inherited method's name in a class to override it,
or implement every pure virtual method left with one code action.
- Design Hierarchy and UVM Verification Hierarchy views, worked out from the source:
filter them by name or path, and let them follow the editor (jump with F12 and the view
selects where you landed).
- Formatter: Format Document and Format Selection fix indentation and trailing blanks (and,
when asked, runs of blank lines), nothing else: every result is checked to change whitespace
only. Indentation follows the constructs (blocks,
case items, one-statement bodies,
headers, continuation lines, UVM *_begin/*_end macros); lines aligned by hand under the
line above are kept. `define definitions, block comments, strings and protected
regions are never touched. Settings under dvicode.format, or a .dvicode/format.json in
the project. Alignment of declarations and connections is not done yet.
- DVICode Lint (preview, off by default: turn on
dvicode.lint.enable): rules about
meaning, not only syntax, such as a randomize() whose result is thrown away, a UVM
registration macro that registers another class or a constructor the factory cannot call;
and, when you choose them, the checkable rules of the
HEXK SystemVerilog/UVM Style Guide.
Findings show with the compile problems, with quick fixes and one-click waivers; the same
engine runs in CI as dvicode lint. See
the lint guide.
- Parameters per instance: the Design Hierarchy shows the parameter values each instance
gets (overrides,
defparams, defaults, localparams and constant functions evaluated), the
generate branches that exist in it and one block per generate loop copy (g[0], g[1]);
hover a parameter or a signal for its value or width in each instance. What cannot be
evaluated is said, never guessed: branches whose condition is unknown are shown marked
undetermined.
- Register Model: the maps, registers, addresses and fields a UVM register block's
build() creates, read from its construction code, with search by address.
- Assertions and Coverage: right-click a signal or field to see the assertions, covers and
coverpoints that use it (as the checked value, a clock or a reset), through named
properties, port connections and
binds, and covergroup sample() arguments.
- uvm_config_db: hover a
get to see the set calls that can provide it (field, type
and scope matched as UVM 1.2 matches them, through the test's component hierarchy), and a
set for the get calls it reaches; go to definition from a field name to its sets.
- Instance repair: complete port and parameter names in an instance's lists, connect the
missing ports, expand
.*, turn ordered connections into named ones, and see ports
connected twice or ordered and named connections mixed.
- Factory override impact: hover a
set_*_override* call to see which components it
changes in the test's modeled build, which it may change, and why others are not changed.
- Drivers and Loads: right-click a signal or port and choose Show Drivers or Show Loads to
see where it is written (assignments,
force, output arguments, gate outputs) or read,
following port connections down into instances (bind instances too) and up to where its
module is instantiated. The places are found from the source, not by elaborating the design:
interfaces, alias and connections through expressions are not followed.
- TLM connections: with ports shown in the Verification Hierarchy, each port, export and
imp says what it is connected to, through the
connect() calls of the components'
connect_phase (also the ports the UVM library makes: a driver's seq_item_port, a
sequencer's seq_item_export, a subscriber's and an analysis FIFO's exports), and the imps a
port may reach through other ports and exports. Calls UVM rejects or ignores (an imp that
connects, different interfaces, after the end of elaboration) are shown with the reason; a
call whose handles cannot be followed (a helper's argument, an alias, another array element)
is shown as not followed, never guessed.
- Compile context: right-click a file (or a Compiled Files entry) and choose Show Compile
Context to see how it is compiled: every root file and invocation that compiles it with the
include chain, and for the one the editor uses the defines, the include directories in
search order, where each
`include was found (and other copies further down the
search), the macros the file uses or tests as defined there, the lines `ifdef removes,
design elements defined more than once and which one is used, and the preprocessing
problems. Hover an `include to see what found it. Copy Compile Context puts the
report on the clipboard for an issue.
- Macro expansion: see exactly what a
`uvm_* macro turns into.
- Clickable simulator logs: in
*.log files, transcript and terminals, source
locations open the file at the line (UVM report lines, VCS messages, and the common
file(line) and file:line forms), even when the log was written on another machine: the
project file whose path ends the same way is opened. A UVM component path
(uvm_test_top.env.sb) selects the component in the Verification Hierarchy, in the test the
log ran, and opens its class. On by default; dvicode.logs.links turns it off and
dvicode.logs.maxFileSizeMB (50) skips larger logs.
- Type and call hierarchies, outline, symbol search, rename, semantic highlighting.
- Quick fixes: "did you mean", "import package", "declare variable".
- Uses your existing file lists (
-f files), or configures the project by itself.
- Works where your sources live: natively on Windows, Linux and macOS, in WSL, or on a
Linux host over SSH, even for files that exist only on the server.
- Lightweight: a single engine of about 5 MB, installed for you. No telemetry.
| Macro hover |
Design and UVM hierarchies |
Problems and quick fixes |
 |
 |
 |
Getting started
Open a folder with SystemVerilog sources; the engine runs on your computer. For files in WSL
it runs in that WSL distribution; for files on a Linux server, run DVICode: Open Folder on
the Server... and pick the SSH host (SSH key or agent sign-in). To control the compile
order, add .dvicode/default.build in the simulator's argument-file syntax (-f,
+incdir+, +define+, -uvm, ...); without it the project is configured automatically.
Documentation
| |