All Projects → MaxXSoft → Fuxi

MaxXSoft / Fuxi

Licence: GPL-3.0 license
Fuxi (伏羲) is a 32-bit pipelined RISC-V processor written in Chisel3.

Programming Languages

Verilog
626 projects
scala
5932 projects

Projects that are alternatives of or similar to Fuxi

Neorv32
A small and customizable full-scale 32-bit RISC-V soft-core CPU and SoC written in platform-independent VHDL.
Stars: ✭ 106 (+55.88%)
Mutual labels:  cpu, fpga, riscv
tree-core-cpu
A series of RISC-V soft core processor written from scratch. Now, we're using all open-source toolchain( chisel, mill, verilator, NEMU, AM and difftest framework, etc) to design and verify.
Stars: ✭ 22 (-67.65%)
Mutual labels:  cpu, chisel, riscv
Ustc Rvsoc
FPGA-based RISC-V CPU+SoC.
Stars: ✭ 77 (+13.24%)
Mutual labels:  cpu, fpga, riscv
Cva6
The CORE-V CVA6 is an Application class 6-stage RISC-V CPU capable of booting Linux
Stars: ✭ 1,144 (+1582.35%)
Mutual labels:  cpu, fpga, riscv
kianRiscV
KianRISC-V! No RISC-V, no fun! RISC-V CPU with strong design rules and unittested! CPU you can trust! kianv rv32im risc-v a hdmi soc with harris computer architecture in verilog: multicycle, singlecycle and 5-stage pipelining Processor. Multicycle Soc with firmware that runs raytracer, mandelbrot, 3d hdmi gfx, dma controller, etc.....
Stars: ✭ 167 (+145.59%)
Mutual labels:  cpu, fpga, riscv
Darkriscv
opensouce RISC-V cpu core implemented in Verilog from scratch in one night!
Stars: ✭ 1,062 (+1461.76%)
Mutual labels:  cpu, fpga, riscv
Vexriscv
A FPGA friendly 32 bit RISC-V CPU implementation
Stars: ✭ 1,041 (+1430.88%)
Mutual labels:  cpu, fpga, riscv
KyogenRV
The Simple 5-staged pipeline RISC-V written in chisel3 for intel FPGA.
Stars: ✭ 37 (-45.59%)
Mutual labels:  fpga, chisel, riscv
Riscboy
Portable games console, designed from scratch: CPU, graphics, PCB, and the kitchen sink
Stars: ✭ 103 (+51.47%)
Mutual labels:  cpu, fpga
Riscv Fs
F# RISC-V Instruction Set formal specification
Stars: ✭ 173 (+154.41%)
Mutual labels:  cpu, riscv
Forth Cpu
A Forth CPU and System on a Chip, based on the J1, written in VHDL
Stars: ✭ 244 (+258.82%)
Mutual labels:  cpu, fpga
J1sc
A reimplementation of a tiny stack CPU
Stars: ✭ 64 (-5.88%)
Mutual labels:  cpu, fpga
managed ml systems and iot
Managed Machine Learning Systems and Internet of Things Live Lesson
Stars: ✭ 35 (-48.53%)
Mutual labels:  cpu, fpga
FPGACosmacELF
A re-creation of a Cosmac ELF computer, Coded in SpinalHDL
Stars: ✭ 31 (-54.41%)
Mutual labels:  cpu, fpga
Biriscv
32-bit Superscalar RISC-V CPU
Stars: ✭ 208 (+205.88%)
Mutual labels:  cpu, fpga
community
ROS 2 Hardware Acceleration Working Group community governance model & list of projects
Stars: ✭ 34 (-50%)
Mutual labels:  cpu, fpga
TinyMIPS
The Project TinyMIPS is dedicated to enabling undergraduates to build a complete computer system from scratch.
Stars: ✭ 29 (-57.35%)
Mutual labels:  cpu, fpga
yatcpu
Yet another toy CPU.
Stars: ✭ 42 (-38.24%)
Mutual labels:  cpu, riscv
BenEaterVHDL
VHDL project to run a simple 8-bit computer very similar to the one built by Ben Eater (see https://eater.net)
Stars: ✭ 30 (-55.88%)
Mutual labels:  cpu, fpga
fpga-tidbits
Chisel components for FPGA projects
Stars: ✭ 88 (+29.41%)
Mutual labels:  fpga, chisel

Fuxi

Test

Fuxi (伏羲) is a 32-bit pipelined RISC-V processor written in Chisel3.

datapath

Implemented ISAs

  • RV32I 2.1
  • Zifencei extension 2.0
  • Zicsr extension 2.0
  • M extension 2.0
  • A extension 2.0
  • Machine-level ISA 1.11
  • Supervisor-level ISA 1.11

Unimplemented Details

Fuxi processor is designed for running GeeOS, or other simple operating systems or bare-metal software. Considering the complexity, the following functions has not yet been implemented:

  • Memory privilege in mstatus register: MPRV bit and MXR bit are hardwired to 0.
  • Virtualization support in mstatus register: TVM bit, TW bit and TSR bit are hardwired to 0.
  • Physical Memory Protection: all PMP registers are hardwired to 0.

Performance

With default configuration:

  • Dhrystone 2.1: 0.60 DMIPS/MHz.
  • CoreMark: 2.15 CoreMark/MHz.

Getting Started

By issuing the following command lines, you can get generated verilog file in directory verilog/build:

$ git clone https://github.com/MaxXSoft/Fuxi
$ cd Fuxi
$ make

Running Tests

Running Unit Tests

All unit tests are available in directory src/test/scala. For example, unit test for decode stage is available in core/DecoderTest.scala, you can run this test by executing the following command lines:

$ sbt
> test:runMain core.DecoderTest

Running CoreTest

CoreTest is a special unit test provided in this repository, it can run simple RISC-V programs using the Fuxi core. We also provided some programs in directory src/test/resources. For example, you can run one of it:

$ sbt
> test:runMain core.CoreTest -if src/test/resources/fib.txt

Trace information during running program fib.txt will be printed to the console.

CoreTest supports the following command line arguments:

Option Abbreviation Argument Description
--init-file -if path to program file Specify the initialization file of ROM.
--trace-file -tf path to trace file Specify the trace file, default to empty.
--gen-trace -gt 0 or other values Set to 0 for trace comparison, otherwise use Fuxi core to generate trace file. Default to 0.

So you can test the core using a trace file generated by other processor or emulator:

> test:runMain core.CoreTest -if src/test/resources/fib.txt -tf src/test/resources/fib_trace.txt

For other details, please read the source file of CoreTest.scala.

All provided programs:

Name Description
fib.txt Generate the first 10 terms of the Fibonacci sequence.
mdu.txt Perform some multiplications and divisions.
mecall.txt Test machine mode environment call.
secall.txt Test supervisor mode environment call.

Running Other Test Benches

This part is under construction.

As we see in the top level module, the complete Fuxi processor consists of Core and CoreBus, the latter provides MMU, cache system and AXI4 interface for the Core part.

All of the unit test cases currently contained in this repository can only test modules in the Core part, we are still preparing the test bench the entire processor system. For now, you can build a tiny SoC by yourself based on some AXI4 IP cores to run other test benches you want.

Copyright and License

Copyright (C) 2010-2020 MaxXing. License GPLv3.

Special thanks to @Yukiteru Lee.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].