GithubHelp home page GithubHelp logo

beanavil / vortex Goto Github PK

View Code? Open in Web Editor NEW

This project forked from vortexgpgpu/vortex

0.0 0.0 0.0 312.23 MB

License: Apache License 2.0

Shell 0.33% C++ 14.84% Python 0.14% C 3.49% Tcl 1.12% Verilog 58.19% Assembly 0.05% SystemVerilog 5.09% Makefile 0.46% PostScript 15.03% Dockerfile 0.03% Visual Basic 6.0 1.24%

vortex's Introduction

AOHW 2024

Build Status codecov

Team information

  • Team number: AOHW-200
  • Project name: RISC-V based GPU
  • Link to YouTube Video(s):
  • University name: Universitat Politècnica de Catalunya (UPC)
  • Participant(s):
    • Javier Beiro Piñón
    • Beatriz Navidad Vilches
    • Nicolás Zhilie Zhao
  • Supervisor: Dr. Leonidas Kosmidis

Vortex GPGPU

Vortex is a full-stack open-source RISC-V GPGPU. For our submission to the AOHW2024, we have added support for tensor instructions for loading, storing and performing multiplication and addition of matrices. We have also added warp-level intrinsics that make use of these instructions.

Specifications

  • Supports RISC-V RV32IMAF and RV64IMAFD
  • Microarchitecture:
    • configurable number of cores, warps, and threads.
    • configurable number of ALU, FPU, LSU, and SFU units per core.
    • configurable pipeline issue width.
    • optional shared memory, L1, L2, and L3 caches.
    • default configuration:
      • 1 core, 4 warps and 4 threads/warp
      • 4 ALU, 4 FPU, 4 LSU and 4 SFU units per core
      • issue width of 4
      • L1 enabled, L2 and L3 disabled
  • Software:
    • OpenCL 1.2 Support.
  • Supported FPGAs:
    • Altera Arria 10
    • Altera Stratix 10
    • Xilinx Alveo U50, U250, U280
    • Xilinx Versal VCK5000

Directory structure

  • ci: Continuous integration scripts.
  • docs: Documentation.
  • hw: Hardware sources.
  • kernel: RISC-V device runtime.
  • miscs: Miscellaneous resources.
  • runtime: Host drivers implementations.
  • sim: Simulators repository.
  • tests: Tests repository.
  • runTests.sh: script for executing all tests performed in the report.
  • runTests_cache.sh: script for measuring the memory access patterns in the implemented instruction.

Build Requirements

Supported OS Platforms

  • Ubuntu 18.04, 20.04
  • CentOS 7

Toolchain Dependencies

Build Instructions

We already ship a docker image based on Ubuntu 20.04 that has the Vortex repository cloned and all the dependencies installed. See .

The build process is described below.

Within docker container

It's only necessary to build Vortex's sources:

cd vortex
make -s -j $(nproc)

From scratch

  1. Get Vortex codebase

    git clone --recursive https://github.com/Beanavil/vortex.git vortex
    cd vortex
  2. Install dependencies

    sudo apt-get install build-essential zlib1g-dev libtinfo-dev libncurses5 uuid-dev libboost-serialization-dev libpng-dev libhwloc-dev ninja-build cmake

    and upgrade gcc to 11:

    sudo apt-get install gcc-11 g++-11

    Multiple gcc versions on Ubuntu can be managed with update-alternatives, e.g.:

    sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 9
    sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-9 9
    sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-11 11
    sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-11 11
  3. Set up prebuilt toolchain

    By default, the toolchain will be installed to the /opt folder, which requires sudo access. You can install the toolchain to a different location of your choice by setting TOOLDIR (e.g. export TOOLDIR=$HOME/tools).

    export TOOLDIR=/opt
    ./ci/toolchain_install.sh --all
    source ./ci/toolchain_env.sh
  4. Set up custom LLVM

    git clone https://github.com/Beanavil/vortex-llvm llvm-vortex && cd llvm-vortex
    cmake -G Ninja -S llvm -B build -DLLVM_INSTALL_UTILS=ON -DCMAKE_INSTALL_PREFIX=$TOOLDIR/llvm-vortex -DCMAKE_BUILD_TYPE=Release -DLLVM_DEFAULT_TARGET_TRIPLE="riscv32-unknown-elf" -DLLVM_TARGETS_TO_BUILD="RISCV" -DLLVM_ENABLE_PROJECTS="clang"
    ninja -C build install
  5. Build Vortex's sources

    make -s -j $(nproc)

Execute the tensor core test

For executing the tensor core test for $2\times 2$ matrices with hardware simulation:

./ci/blackbox.sh --driver=rtlsim --app=tmul --args="-n2"

vortex's People

Contributors

tinebp avatar pear0 avatar stackmachinesa avatar santoshsrivatsan24 avatar cdkersey avatar gadzookie avatar zlj09 avatar felsabbagh3 avatar malikburton avatar codetector1374 avatar beanavil avatar udit8348 avatar hyesoon avatar caiyzik avatar nicolaszhao1908 avatar timmy139710 avatar eunaeuna avatar limvot avatar shin0403 avatar xandyliu avatar jabepi avatar lpc97667 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.