go/src/cmd
Mark Ryan b4e7d630bc cmd/go: add GORISCV64 environment variable
The variable represents the RISC-V user-mode application profile for
which to compile.  Valid values are rva20u64 (the default) and
rva22u64.

Setting GORISCV64=rva20u64 defines the riscv64.rva20u64 build tag,
sets the internal variable buildcfg.GORISCV64 to 20 and defines the
macro GORISCV64_rva20u64 for use in assembly language code.

Setting GORISCV64=rva22u64 defines the riscv64.rva20u64 and
riscv64.rva22u64 build tags, sets the internal variable
buildcfg.GORISCV64 to 22 and defines the macro GORISCV64_rva22u64
for use in assembly language code.

This patch only provides a mechanism for the compiler and hand-coded
assembly language functions to take advantage of the RISC-V
extensions mandated by the application profiles.  Further patches
will be required to get the compiler/assembler and assembly language
functions to actually generate and use these extensions.

Fixes #61476

Change-Id: I9195ae6ee71703cd2112160e89157ab63b8391af
Reviewed-on: https://go-review.googlesource.com/c/go/+/541135
Reviewed-by: M Zhuo <mengzhuo1203@gmail.com>
Reviewed-by: Joel Sing <joel@sing.id.au>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Wang Yaduo <wangyaduo@linux.alibaba.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
Reviewed-by: Bryan Mills <bcmills@google.com>
Run-TryBot: M Zhuo <mengzhuo1203@gmail.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
2024-01-24 07:25:25 +00:00
..
addr2line
api cmd/api: fix panic on exported basic type aliases 2024-01-04 17:31:12 +00:00
asm cmd/asm: for arm, rewrite argument shifted right by 0 to left by 0. 2023-12-15 20:51:01 +00:00
buildid
cgo cmd/cgo/internal/test: skip TestCallbackCallersSEH when internal linking 2024-01-23 06:52:00 +00:00
compile cmd/compile/internal/ssagen,runtime: merge trace consts into internal/abi 2024-01-23 02:16:01 +00:00
covdata cmd: fix mismatched symbols 2023-10-03 12:57:25 +00:00
cover cmd: fix mismatched symbols 2023-10-03 12:57:25 +00:00
dist cmd/go: add GORISCV64 environment variable 2024-01-24 07:25:25 +00:00
distpack cmd/distpack: include directory entries in tar files 2023-08-11 17:37:52 +00:00
doc cmd/doc: fix inconsistent receiver name 2024-01-08 20:15:52 +00:00
fix cmd/fix: use reflect.TypeFor for known types 2023-08-07 00:25:49 +00:00
go cmd/go: add GORISCV64 environment variable 2024-01-24 07:25:25 +00:00
gofmt io/fs, path/filepath, cmd/gofmt: replace statDirEntry with fs.FileInfoToDirEntry 2023-09-12 20:27:28 +00:00
internal cmd/go: add GORISCV64 environment variable 2024-01-24 07:25:25 +00:00
link cmd/link,runtime: merge minfunc const info internal/abi 2024-01-22 16:17:48 +00:00
nm
objdump cmd/dist: refactor generated cgo-support logic 2023-04-20 17:26:46 +00:00
pack all: add String for fs.{FileInfo,DirEntry} implementations 2023-05-04 16:27:35 +00:00
pprof runtime,runtime/pprof: get memory mappings on darwin. 2023-08-03 16:07:59 +00:00
test2json
tools cmd: vendor golang.org/x/tools/cmd/bisect 2023-05-09 01:28:10 +00:00
trace cmd/trace/v2: emit user log annotations in all views 2024-01-19 21:39:18 +00:00
vendor all: update vendored dependencies 2024-01-22 19:00:13 +00:00
vet cmd/vet: add lost checks in doc 2023-11-21 00:17:30 +00:00
README.vendor
go.mod all: update vendored dependencies 2024-01-22 19:00:13 +00:00
go.sum all: update vendored dependencies 2024-01-22 19:00:13 +00:00

README.vendor

See src/README.vendor for information on loading vendored packages
and updating the vendor directory.