sunwayforever / gcc-toy

GCC Toy RISC-V backend step by step

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

GCC Toy RISC-V Backend

This repository is used to show how to build a RISC-V backend step by step.

References

  1. http://atgreen.github.io/ggx/

Getting started

build riscv64-unknown-linux-gnu-gcc

$> git clone https://github.com/riscv-collab/riscv-gnu-toolchain
$> cd /path/to/riscv-gnu-toolchain
$> configure --prefix=/opt/gcc-riscv --with-arch=rv64gc --with-abi=lp64d --enable-multilib
$> make linux

build Toy backend and test

$> cd /path/to/gcc-toy/toy
$> make gcc
$> make 
$> make run

documentation

https://pages.dogdog.run/toolchain/gcc_toy_riscv_backend.html

About

GCC Toy RISC-V backend step by step

License:GNU General Public License v2.0