Code Monkey home page Code Monkey logo

ece499's Introduction

MATRIX MULTIPLICATION ACCELERATOR

Simulation

In order to simulate the accelerator, following steps must be followed:

  1. Install RISCV tools following steps in the https://github.com/chipsalliance/rocket-tools/ repository. This will install all the tools needed for running the simulation including the gnu toolchain.
  2. Once the tools have been installed, clone the https://github.com/ucb-bar/chipyard repository. This repository is used to produce a RISC V system on chip with rocket or BOOM cores along with MMIO mapped peripherals and coprocessors. For this project, a single rocket core with the matrix multiplication accelerator will be generated.
  3. Add the project repository as a submodule to the chipyard repository in the generators folder using the following command.
cd generators
git submodule add https://github.com/yeshuj/ECE499.git
  1. Copy the test cases from software/ directory in the yeshuj/ECE499 repository and paste it in tests/ directory in the chipyard repository.
  2. In the tests/ directory, run the make command. This will install libgloss locally if it's not installed, and will compile the test cases to a .riscv binary file which can be run on the simulator.
  3. Add a config similar to the one shown in figure 7 to the file “generators/chipyard/src/main/scala/config/TutorialConfigs.scala”. This config generates a simple SoC with just a rocket core and the accelerator with designated opcode 2.
  4. Replace the build.sbt in chipyard root with the one in docker-recources/build.sbt
  5. Run the following command in the sims/verilator directory to run the simulation.
make -j8 CONFIG=Tutorial499Config run-binary-debug BINARY=../../tests/matmul.riscv

Using Docker

  1. To run the simulation using docker, it the root directory, run the following command to build the container:
docker build .
  1. Enter the container using the command:
docker run -it <image tag>
  1. In the container, run:
./test.sh

This script runs the tests in matmul.c

ece499's People

Contributors

yeshuj avatar actions-user avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.