TDEB Top Bar

Trending
Semiconductor Industry News — The Digital Electronics Blog
Follow Us

TDEB Masthead

The Semiconductor Hub

Semiconductors.  Chips and Systems.  Innovation.

Indexed by leading Search Engines, AI and referenced by Engineers worldwide 500+ Articles 10M+ Pageviews 30+ Reports 50+ Citations

Source Navigator for Verilog: Browsing Large HDL Projects

mg
by
0
Share Facebook X LinkedIn WhatsApp Email

Source Navigator for Verilog is a full-featured tool for editing and navigating large projects with many Verilog files. It parses Verilog code into a database that can be used to navigate files, trace connectivity, and find modules and signals in the design. It can even parse your files as you edit, so you don't launch those long compile scripts only to end up with a syntax error after 5 minutes of compiling.

Where it came from

Source-Navigator was developed by Cygnus Solutions as a commercial IDE (integrated development environment) for software engineers and was later released under the GPL by Red Hat. It supports many languages, including C, C++, Tcl, Java, Fortran and COBOL. There are many similar products for software engineers, but at the time almost nothing was available for hardware engineers using languages such as Verilog. By adding a Verilog parser to Source-Navigator, hardware engineers could enjoy the same kind of tool.

Cygnus announced Source-Navigator 4.5 on November 30, 1999, while its merger with Red Hat was pending. The Verilog version was a separate open-source project hosted on SourceForge.

What it does for an RTL engineer

A chip design can have hundreds of Verilog files spread across many directories. Finding where a signal is driven, which modules instantiate a block, or what a port connects to two levels up is slow with a plain text editor and grep. A code navigator builds a symbol database once and then answers those questions instantly:

  • Find a definition: jump from a module instance to the module's source.
  • Trace connectivity: follow a signal through ports and instances across the hierarchy.
  • Browse the hierarchy: see which modules are instantiated where.
  • Catch syntax errors early: because files are parsed as you edit, typos show up before you start a long compile or simulation run.

When you would use it

This kind of tool helps most when you join a project and need to learn an unfamiliar code base, when you debug a connectivity problem across many files, or when you review someone else's RTL. It does not replace a simulator or a lint tool; it makes reading the code faster.

Deep dive: the numbers and details

This part holds the version history and how the tool fits a design flow. Skip it if the overview is all you need.

Release details

The project page records these points:

ItemDetail from the project page
Latest releaseAnnounced October 27, 2002, with the base Source-Navigator updated to version 5.1.1
New in that releaseA Verilog menu that links to external tools for lint, compile, simulate and waveform display
User interfaceBuilt with Tcl/Tk, so it can be extended
Downloads reportedOver 2,000
Base licenseSource-Navigator released under the GPL by Red Hat

Source-Navigator 4.5 at launch

The 1999 announcement listed two editions: Developer, for projects up to 250,000 lines of code, and Enterprise, with no line limit and cross-platform support. Supported languages were C, C++, Java, Tcl, [incr Tcl], FORTRAN, COBOL and assembly, with version control integration for RCS, CVS, SCCS and ClearCase.

What happened next

The software line continued as Source Navigator NG, a GPLv2 fork. Its SourceForge page lists NG4.5 as the latest release, last updated on August 20, 2014, for Linux, BSD and Windows. The NG project page describes the release history: NG3 moved the symbol database to db4 for speed, NG4 added PHP support and native Win32 builds, and NG4.5 fixed the option to disable cross-references. The NG pages do not mention the Verilog parser, so check before assuming Verilog support in NG.

How a symbol database works

A navigator parses each file once into tables of symbols: module definitions, instances, ports, nets, parameters and where each is used. Queries such as "who drives this net" become database lookups instead of text searches. The cost is the initial parse and keeping the database in step as files change, which is why incremental parsing on save matters on large projects.

Choosing a navigator today

When you evaluate any HDL navigator, check these points on your own code:

  • Does it parse the language version you use (Verilog-2001, SystemVerilog, VHDL)?
  • Does it handle `define macros, `include files and generate blocks correctly?
  • Can it follow a signal through port connections in both directions?
  • How long does the first parse take on the full design, and how fast are updates after an edit?
  • Can it launch your lint and simulation scripts, as the 2002 Verilog menu did?

Common mistakes when navigating RTL

  • Parsing the wrong file set. A navigator only knows the files you give it. If the file list differs from the one the simulator compiles, for example an old copy of a module in another directory, the tool will happily show you code that is not in the build. Generate the navigator's file list from the same script that drives compilation.
  • Ignoring defines. Code inside `ifdef blocks depends on which macros are set. Make sure the navigator sees the same `define values as the build, or it will show connectivity that the real design does not have.
  • Trusting names over connections. A signal can be renamed at every level of hierarchy. Trace through port connections rather than searching for a name, which is exactly what a symbol database is good at.
  • Forgetting generated code. Register maps and wrappers produced by scripts are often not checked in. Run the generators before you build the database so those files are included.
Share Facebook X LinkedIn WhatsApp Email

Post a Comment

0 Comments

Your comments will be moderated before it appears here.

Post a Comment (0)

#buttons=(Ok, Go it!) #days=(20)

Our website uses cookies to enhance your experience. Learn more
Ok, Go it!