Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/yasnakateb/cgras

Coarse Grained Reconfigurable Arrays with Chisel3
https://github.com/yasnakateb/cgras

cgras chisel chisel-test chisel3 computer-architecture hardware sbt scala

Last synced: 2 months ago
JSON representation

Coarse Grained Reconfigurable Arrays with Chisel3

Awesome Lists containing this project

README

        

# CGRAs
CGRAs (Coarse-Grained Reconfigurable Architectures) are arrays of interconnected Processing Elements (PEs) arranged in a mesh style, offering a blend of hardware performance and software flexibility. In this architecture, each PE consists of a Cell Processing unit containing a Functional Unit (FU) surrounded by configurable routing logic. By mapping graph nodes to the FUs and configuring routing logic to establish connections between them based on the graph edges, the overlay executes a given Data Flow Graph (DFG). This overlay architecture operates on a data-driven execution model, where an FU performs an operation only when its inputs are ready and its output is available. Inputs are located in the north and outputs can be obtained from the east.
## Architecture

## Overlay
![](assets/cgra.png)
## Processing Element
![](assets/pe.png)
## Elastic Buffer
![](assets/eb.png)

### Benchmarks

| Name | Inputs | Outputs | Expression |
|-------------------------|-------------------------|-----------------------|----------------------------------------------|
| Sum | 2 Arrays | 1 Array | x[i] = a[i] + b[i] |
| Accumulate | 2 Arrays | 1 Array, 1 Scalar | c[i] = c[i] (a[i] + b[i]) , x = x + ∑ c[i]
| Cap | 2 Arrays | 1 Array | (((a[i] * 6) >> 2) * 2) * (((b[i] * 3 * a[i])>>2) * a[i]);
| Mac | 2 Arrays, 1 Scalar | 1 Scalar | x = x + ∑ a[i] b[i]
| Mac2 | 4 Arrays, 2 Scalars | 2 Scalars | x = x + ∑ a[i] b[i] , y = y + ∑a[i] (b[i] + 1)c[i] d[i]

## Building on Ubuntu

1. Install gtkwave: `$ sudo apt-get -y install gtkwave`

2. Clone the repository.

3. Use the Makefile to run the tests. For example, $ make test_name where test_name can be:
* alu-test
* fu-test
* join-test
* d-eb-test
* d-reg-test
* fs-test
* fr-test
* conf-mux-test
* d-fifo-test
* cell-processing-test
* processing-element-test
* overlay-sum
* overlay-cap
* overlay-acc
* overlay-mac
* overlay-mac2

4. The VCD files are generated in the `test_run_dir` folder.

5. You can check the inputs and results of the benchmarks in the following table:

| Benchmark | a | b | c | d | x | y | Result | Result |
|-----------|-------------------|-------------------|-------------------|-------------------|-------------------|------------|----------------|----------------------|
| SUM | North East | Middle North OV 3 | | | | | North East (x) | |
| ACC | North East | North West | Middle North OV 2 | | Middle North OV 3 | | North East (c) | Middle East OV 1 (x) |
| CAP | North West | North East | | | | | | Middle East OV 2 (x) |
| MAC | Middle North OV 2 | Middle North OV 3 | | | North East | | North East (x) | |
| MAC 2 | Middle North OV | North West | Middle North OV 1 | Middle North OV 2 | Middle North OV 3 | North East | North East (y) | Middle East OV (x) |