diff options
| author | Joel Sing <joel@sing.id.au> | 2019-11-04 04:58:37 +1100 |
|---|---|---|
| committer | Joel Sing <joel@sing.id.au> | 2020-01-19 14:04:09 +0000 |
| commit | 8e0be05ec7c369387c0ed3c9cf37968c6d3afbbd (patch) | |
| tree | a52a3963edf41ea1960b0c018d047ecfe0756460 /src/runtime/internal/sys | |
| parent | cbaa666682386fe5350bf87d7d70171704c90fe4 (diff) | |
| download | go-8e0be05ec7c369387c0ed3c9cf37968c6d3afbbd.tar.xz | |
runtime: add support for linux/riscv64
Based on riscv-go port.
Updates #27532
Change-Id: If522807a382130be3c8d40f4b4c1131d1de7c9e3
Reviewed-on: https://go-review.googlesource.com/c/go/+/204632
Run-TryBot: Joel Sing <joel@sing.id.au>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Keith Randall <khr@golang.org>
Diffstat (limited to 'src/runtime/internal/sys')
| -rw-r--r-- | src/runtime/internal/sys/arch.go | 1 | ||||
| -rw-r--r-- | src/runtime/internal/sys/arch_riscv64.go | 18 |
2 files changed, 19 insertions, 0 deletions
diff --git a/src/runtime/internal/sys/arch.go b/src/runtime/internal/sys/arch.go index 75beb7872f..13c00cf639 100644 --- a/src/runtime/internal/sys/arch.go +++ b/src/runtime/internal/sys/arch.go @@ -14,6 +14,7 @@ const ( MIPS MIPS64 PPC64 + RISCV64 S390X WASM ) diff --git a/src/runtime/internal/sys/arch_riscv64.go b/src/runtime/internal/sys/arch_riscv64.go new file mode 100644 index 0000000000..7cdcc8fcbd --- /dev/null +++ b/src/runtime/internal/sys/arch_riscv64.go @@ -0,0 +1,18 @@ +// Copyright 2016 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package sys + +const ( + ArchFamily = RISCV64 + BigEndian = false + CacheLineSize = 64 + DefaultPhysPageSize = 4096 + PCQuantum = 4 + Int64Align = 8 + HugePageSize = 1 << 21 + MinFrameSize = 8 +) + +type Uintreg uint64 |
