Skip to content

4a6f656c/riscv-go

This branch is 10188 commits ahead of, 2 commits behind riscvarchive/riscv-go:riscvdev.

Folders and files

NameName
Last commit message
Last commit date

Latest commit

1c193b2 · Nov 4, 2019
Nov 2, 2018
Aug 8, 2019
Sep 29, 2019
Jul 3, 2019
Nov 4, 2019
May 9, 2019
Nov 4, 2019
Nov 4, 2019
Dec 12, 2014
Oct 28, 2017
Sep 9, 2019
Feb 12, 2018
Sep 15, 2019
Jun 1, 2016
Dec 6, 2010
Apr 19, 2017
Sep 26, 2019
Jun 20, 2016
Aug 25, 2016
Feb 18, 2011

The Go Programming Language

RISC-V Go Port

This repository is home of the RISC-V port of the Go programming language.

The upstream Go project can be found at https://github.com/golang/go.

Quick Start

Setup:

$ git clone https://review.gerrithub.io/riscv/riscv-go riscv-go
$ cd riscv-go
$ git checkout riscvdev  # RISC-V work happens on this branch
$ export GOROOT_BOOTSTRAP=/path/to/prebuilt/go/tree
$ export PATH="$(pwd)/misc/riscv:$(pwd)/bin:$PATH"
$ cd src
$ ./make.bash

Compile and run in qemu-riscv64 (which is expected to be in PATH):

$ GOARCH=riscv GOOS=linux go run ../riscvtest/add.go

Build:

$ GOARCH=riscv GOOS=linux go build ../riscvtest/add.go

Test:

Our basic tests are in the riscvtest directory:

$ cd ../riscvtest
$ go run run.go

If this exits without error, all is well!

QEMU

Spike plus pk support only a small subset of Linux syscalls and will not be capable of supporting the full Go runtime.

The RISC-V QEMU port supports a much wider set of syscalls with its "User Mode Simulation". See Method 2 in the QEMU README for instructions.

Contributing

All contributors must sign the upstream Contributor License Agreement, as this port will be merged into upstream Go upon completion.

Code review occurs via our GerritHub project, rather than via GitHub Pull Requests.

The upstream contribution guidelines include a basic overview of using Gerrit. While the upstream Go Gerrit server is different from ours, codereview.cfg will configure git-codereview to send CLs to GerritHub.

About

No description, website, or topics provided.

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 90.0%
  • HTML 5.0%
  • Assembly 4.6%
  • C 0.2%
  • Shell 0.1%
  • Perl 0.1%