internal/buildcfg: add ability to get GORISCV64 variable in GOGOARCH

For #61476

Change-Id: I29f4c1c3c3303e70ec2d7f380112eb2d00754018
Reviewed-on: https://go-review.googlesource.com/c/go/+/665655
Reviewed-by: Mark Ryan <markdryan@rivosinc.com>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Mark Freeman <mark@golang.org>
Reviewed-by: Meng Zhuo <mengzhuo1203@gmail.com>
This commit is contained in:
Julian Zhu 2025-04-15 21:34:42 +08:00 committed by Meng Zhuo
parent 6f6c6c5782
commit ada30b8248

View file

@ -392,6 +392,8 @@ func GOGOARCH() (name, value string) {
return "GOMIPS64", GOMIPS64
case "ppc64", "ppc64le":
return "GOPPC64", fmt.Sprintf("power%d", GOPPC64)
case "riscv64":
return "GORISCV64", fmt.Sprintf("rva%du64", GORISCV64)
case "wasm":
return "GOWASM", GOWASM.String()
}