This repository contains the results of an analysis of available testing frameworks for Tydi and Chisel related projects. An analysis of Chisel1 and Tydi-Chisel2 (through the chisel tydi_lib3) by Casper Cromjongh projects has been performed.
Specifically, we are interested in the following research questions:
- What are the available testing frameworks for Tydi-Chisel?
- What are the advantages and disadvantages of each selected framework?
- How chisel and tydi constructs are represented in the testing frameworks?
- How can the representation be generated?
- To what extent do signals in waveform viewers match the original source code?
- What is the gap between the source code and the waveform representation and testing framework?
All these aspects are explored and discussed in the results section.
Specifically, the repository is divided into two main sections:
- A collection of Chisel and Tydi-Chisel examples that support the analysis of the frameworks
- Tool analysis results
Below the tree repository index is presented with links to each section.
Main page: examples.
Sections | Description |
---|---|
Chisel code examples | A collection of Chisel code examples. It contains: source code, test benches and examples explanation. |
Tydi-Chisel code examples | A collection of Tydi-Chisel code examples. It contains: tydi and chisel source codes, test benches and examples explanation. |
Main page: results.
Section | Description |
---|---|
Chiseltest | An analysis of the features of chiseltest: a testing framework for Chisel and Chisel-related projects. |
HGDB-debugger | An analysis of hgdb debugger. |
Waveforms | An analysis of the waveforms produced by Chisel test benches. |
Analysis by example | A detailed analysis of Chisel and Tydi-Chisel representations in testing frameworks. |
- Install Chisel following the instructions in the Chisel GitHub repository1.
- Install the Tydi lang compiler locally (in .cargo/bin):
git clone https://github.com/twoentartian/tydi-lang-2.git cd tydi-lang-2 cargo install --path tydi-lang-complier
- Install the Tydi lang transpiler:
cd examples/tydi-chisel-examples/tydi make compile-transpiler
- Install the
tydi_chisel
library:Now thecd examples/tydi-chisel-examples/chisel make all # The makefile will install the tydi_chisel library locally
tydi_chisel
library is installed in the local maven repository and it can be added as a local dependency with:and imported in a chisel source code with:libraryDependencies += "nl.tudelft" %% "root" % "0.1.0",
import nl.tudelft.tydi_chisel._
Now that everything is installed, it is possible to compile the Tydi-lang source projects.
- Compile all the Tydi projects in the
src
folder:cd examples/tydi-chisel-examples/tydi/ make
- (Alternative) Compile a single Tydi project:
cd examples/tydi-chisel-examples/tydi/ make SRC=<path_to_tydi_source_DIRECTORY>
This will create a build
folder with the compiled Tydi to json IR and Chisel boilerplate code.
Footnotes
-
Chisel, an open-source hardware description language (Constructing Hardware in a Scala Embedded Language). ↩ ↩2
-
Casper Cromjongh et al. “Tydi-Chisel: Collaborative and Interface-Driven Data-Streaming Accelerators”. In: 2023 IEEE Nordic Circuits and Systems Conference (NorCAS). Aalborg, Denmark: IEEE, Oct. 31, 2023, pp. 1–7. ISBN: 9798350337570. ↩
-
A implementation of Tydi interfaces and concepts in Chisel. ↩