Commit f86f5cb4 authored by Benjamin Barenblat's avatar Benjamin Barenblat Committed by Andrew Waterman
Browse files

Support generating Go code (#3)

* Support generating Go code

Generate Go code for the RISC-V Go port
<https://github.com/riscv/riscv-go>.

* Clarify use of yank in Go backend

* Go: Also generate funct3, csr, and funct7 encodings

* Go: Emit all instructions

Changes to the RISC-V Go implementation obviate the need for
GO_UNUSED_INSTRUCTIONS.

* Go: Print CSRs as signed values

* Go: Update parse-opcodes to use obj.As

See https://github.com/golang/go/commit/0d9258a830c585.

* Go: Return errors out of band

* Go: Return 'ok' status instead of 'err' status

Also clean up imports.

* Go: Make gofmt-clean

* Go: Return rs2 value for each instructions

Some binary floating-point instructions (ab)use the rs2 value to hold
additional instruction data, so we need that data in the Go assembler.
parent 3c1a9110
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment