Commit 4e8cec41 authored by Bruno Ferres's avatar Bruno Ferres
Browse files


parent f2b19074
**QECE** (*Quick Exploration using Chisel Estimators*) is a **chisel based** project to provide circuit estimators and exploration functions for FPGA design processes.
## Structure
Sources can be found under `./src/main/scala/...` and associated unit-tests under `./src/test/scala/...`
Project is divided in different submodules:
* global project configuration file is `./src/main/scala/ProjectConfig.scala`
* resources for integration in other chisel projects are to be found in `./src/main/resources/...`
* estimation transforms can be found in `./src/main/scala/estimation/...`
* exploration relative functions - including exploration strategies - can be found in `./src/main/scala/exploration/...`
* backend bindings are available in `./src/main/scala/backend/...` - only Xilinx Virtex 7 boards are available currently
* characterization functions - *i.e.* functions to generate a characterized library of operators and macros for a given target board - can be found in `./src/main/scala/characterization/...`
## Running
To run the transformations on your own project, you need to take a few steps:
* publish your transformations on your environment, using `sbt quickPublish` (as `sbt publishLocal` generates *scaladoc*, which currently results in a bug)
* in your project, update the `build.sbt` with `libraryDependencies += "fr.tima" %% "chisel-transforms" % "1.0.0"`
* you can access to the different classes with `import qece.<package>.<Class>`
**N.B.:** You may have to reload/update your `sbt` project.
## Estimations
Three kinds of estimators are considered at the moment: **resource estimation**, **frequency estimation** and **quality of result estimation**.
* FIRRTL based **resource estimation** is based on prior **macro replacement** of some patterns in the circuits, and uses a library of characterized operators.</br>
Such library is to be found in `./src/main/resources/lib/<target>.json`, and can be generated using `qece.characterization.LibraryBuilder` class (`./src/main/scala/characterization/Library.scala`).</br>
Another resource estimator is based on **synthesis results** through backend calls.
* **Quality of result estimation** is based on an empirical approach, leveraging simulator bindings to provide insights of circuit behavior.
* FIRRTL based **frequency estimation** is currently deprecated, as chosen approach result in complex and non accurate estimations.</br>
However, frequency estimation through **synthesis results** are available using backend API.
Estimators can be call by using `qece.estimation.WithTransform` trait - and examples are to be found in `./src/test/scala/estimation/...`.
## Exploration
In order to be explorable, a **chisel** `Module` must implement `qece.exploration.utils.WithExplorable` trait - you can directly extend `qece.exploration.utils.Explorable` class to build a `MultiIOModule` implementing this trait.
Strategies can be defined using `qece.exploration.strategies.StrategyBuilder` - and examples are to be found in `./src/test/scala/exploration/strategies/...`.
## Linting
The code base is checked with a linter. We use three different linters:
* scalastyle is used to check the code base for formatting prior to merge.
* scalafmt is configure with the same parameters than scalastyle. It should be run before pushing, in order to limit
scalastyle errors. scalafmt is not able to check everything, especially it does not enforce names
* scalafix is used to check (and fix if run locally) semantic and syntactic rules (for now, only unused imports)
In order to automatically apply formatting rules, run:
In order to check the rules locally, you can run the following commands in sbt:
## Contact
Feel free to contact me at [](
The project was developed in **SLS team** at [TIMA lab](, under the supervision of [Frédéric ROUSSEAU]( and [Olivier MULLER](
**QECE** (*Quick Exploration using Chisel Estimators*) is a **chisel based** project to provide circuit estimators and exploration functions for flexible FPGA design processes.
For more information, please take a look at the [wiki](
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment