All Projects → freechipsproject → diagrammer

freechipsproject / diagrammer

Licence: Apache-2.0 License
Provides dot visualizations of chisel/firrtl circuits

Programming Languages

scala
5932 projects
shell
77523 projects

Projects that are alternatives of or similar to diagrammer

Chisel3
Chisel 3: A Modern Hardware Design Language
Stars: ✭ 2,290 (+2913.16%)
Mutual labels:  chisel, chisel3, firrtl
ofdm
Chisel Things for OFDM
Stars: ✭ 23 (-69.74%)
Mutual labels:  chisel, chisel3, firrtl
KyogenRV
The Simple 5-staged pipeline RISC-V written in chisel3 for intel FPGA.
Stars: ✭ 37 (-51.32%)
Mutual labels:  chisel, chisel3
essent
high-performance RTL simulator
Stars: ✭ 60 (-21.05%)
Mutual labels:  chisel, firrtl
Quasar
Quasar 2.0: Chisel equivalent of SweRV-EL2
Stars: ✭ 19 (-75%)
Mutual labels:  chisel, chisel3
YatCPU-docs
Documentatin for YatCPU
Stars: ✭ 15 (-80.26%)
Mutual labels:  chisel3
Fuxi
Fuxi (伏羲) is a 32-bit pipelined RISC-V processor written in Chisel3.
Stars: ✭ 68 (-10.53%)
Mutual labels:  chisel
fpga-tidbits
Chisel components for FPGA projects
Stars: ✭ 88 (+15.79%)
Mutual labels:  chisel
Chisel-FFT-generator
FFT generator using Chisel
Stars: ✭ 26 (-65.79%)
Mutual labels:  chisel
yatcpu
Yet another toy CPU.
Stars: ✭ 42 (-44.74%)
Mutual labels:  chisel3
lectures
Lectures for the Agile Hardware Design course in Jupyter Notebooks
Stars: ✭ 42 (-44.74%)
Mutual labels:  chisel3
PyChip-py-hcl
A Hardware Construct Language
Stars: ✭ 36 (-52.63%)
Mutual labels:  firrtl
tree-core-cpu
A series of RISC-V soft core processor written from scratch. Now, we're using all open-source toolchain( chisel, mill, verilator, NEMU, AM and difftest framework, etc) to design and verify.
Stars: ✭ 22 (-71.05%)
Mutual labels:  chisel
tree-core-ide
The next generation integrated development environment for processor design and verification. It has multi-hardware language support, open source IP management and easy-to-use rtl simulation toolset.
Stars: ✭ 79 (+3.95%)
Mutual labels:  chisel3
Rocket Chip
Rocket Chip Generator
Stars: ✭ 2,079 (+2635.53%)
Mutual labels:  chisel

Chisel / FIRRTL Diagramming Project

This project can generate GraphViz dot files and from those svg files representing Chisel generated Firrtl circuits. It is also an example of a creating a Firrtl Transformation. This transformation can be applied through the use of annotations as demonstrated in the examples.GCD test. The graphs are mostly clickable, clicking a module will take you to a diagram for just that module. There is a TopLevel diagram that just shows the module hierarchy. Also, an individual arrow can be hovered over to make it turn red and become easier to follow.

Example

Top Level Example

Graph

Module Example

Graph

Using

Install

Installing this software should be pretty much the following.

git clone https://github.com/freechipsproject/diagrammer
cd diagrammer

Dependencies

You will need GraphViz (specifically a default path to the program dot) and sbt.

Note that this project currently depends on the master branches of all components of the Chisel ecosystem (chisel3 and firrtl), so you will need to clone and sbt publishLocal for each of these.

Creating Circuit Diagrams.

To create a set of graphs of a Firrtl Circuit all you need is this project and a Firrtl file (typically a file generated by Chisel with a .fir extension). Let's say you have a Firrtl file ~/projects/output/circuit.fir. From the command line you while in this directory for this project, you run

./diagram.sh -i ~/projects/output/circuit.fir

This will create a number of files in the same directory as the firrtl file that representing the firrtl graph. Each file will be a diagram for each module contained in the firrtl file, plus a file TopLevel.dot.svg file. It will also attempt to open the TopLevel.dot.svg file in a browser using the command open. Each Module in the TopLevel diagram is clickable and should take you into the diagram for that specific module. Because of the size of these files, the diagrams will include the internal logic of that module plus and IO only presentation of any sub-modules found.

Options

  • -i, --firrtl-source set the source firrtl to work on
  • -t, --targer-dir sets the output directory for the svg
  • -s, --start-module sets the module name where the graphs will start being generated. The default is at the top
  • -o, --open-program sets the open program, default is open, set to empty to tell it not to do open
  • -j, --just-top-level generates just the top level diagram

How Diagrammer Works

This program uses a number of firrtl transforms to create multiple graphviz dot file graph programs. The dot files are translated into .svg files. See GeneratorBootcamp Firrtl Chapters for a good introduction to writing Firrtl transforms

TODO

  • This used to work by annotating a circuit, consider re-adding that
  • Setting to allow the graphs to go deeper into sub-module logic
  • Provide links to the chisel source
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].