Setting up RV32 Toolchain on BWRC

Refer to the following tutorial on how to set up RISC-V Toolchain for 32 bit instruction set on Berkeley Wireless Research Center (BWRC) computer clusters.

The default RISCV toolchain that comes with Chipyard does not support RV32 / software floating-point compilation.

We need to set up a new toolchain.

git clone git@github.com:riscv-collab/riscv-gnu-toolchain.git
cd riscv-gnu-toolchain/

Install Prerequisites

on Ubuntu 22.04 machine, we need to do

sudo apt update
sudo apt install gawk

Compile

Change "--prefix" to your desired installation directory.

This takes eternity to compile...

./configure --prefix=/tools/C/chiyufeng/documents/RISCV/ --with-multilib-generator="rv32i-ilp32--;rv32im-ilp32--;rv32iac-ilp32--;rv32imac-ilp32--;rv32imafc-ilp32f--;rv64imac-lp64--;rv64imafdc-lp64d--"
make -j16

Or, can just source this environment

source /tools/C/chiyufeng/documents/riscv_env.sh

Last updated