Coder Social home page Coder Social logo

five's Introduction

five

build License

five is a RISC-V emulator in Rust.

This emulator is under development and currently supports RV32I ISA.

Usage

You'll need to install cargo-make before running the emulator.

cargo install cargo-make

To run a binary, use the cargo make CLI command.

git clone [email protected]:plavelo/five.git
cd five
cargo make cli <path-to-binary>

Testing

In order to run the tests, you'll need RISC-V toolchain.

curl -o toolchain.tar.gz https://static.dev.sifive.com/dev-tools/riscv64-unknown-elf-gcc-8.1.0-2019.01.0-x86_64-linux-ubuntu14.tar.gz
sudo mkdir /opt/riscv
sudo tar xfz toolchain.tar.gz --strip-components 1 -C /opt/riscv
export PATH=/opt/riscv/bin:$PATH

Build RISC-V executable binaries for testing.

cargo make buildtest

Then, run the tests with the following command.

cargo test

You can also specify a binary to run the test as follows.

cargo make cli ./riscv-tests/isa/rv32ui-p-add.bin

Features

  • 32-bit/64-bit ISA
    • RV32I/RV64I (except fence/ebreak)
    • RV32M/RV64M
    • RV32F/RV64F (except fsqrt.s)
    • RV32D/RV64D
    • RV32A/RV64A
    • RV32C/RV64C
    • Zifencei
    • Zicsr
  • Privileged ISA
  • Peripheral device
    • UART
    • Virtio
  • Device tree

Resources

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.