cpu: add basic support for GOARCH=loong64

Updates golang/go#46229

Change-Id: Ibee284c742532dec798f4a5ecfe38b429825d7aa
Reviewed-on: https://go-review.googlesource.com/c/sys/+/399334
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Auto-Submit: Ian Lance Taylor <iant@google.com>
Reviewed-by: Russ Cox <rsc@golang.org>
This commit is contained in:
limeidan
2022-04-09 11:40:40 +08:00
committed by Gopher Robot
parent a24fb2fb8a
commit 0a89baf871
2 changed files with 14 additions and 0 deletions

View File

@@ -46,6 +46,7 @@ func hostByteOrder() byteOrder {
case "386", "amd64", "amd64p32",
"alpha",
"arm", "arm64",
"loong64",
"mipsle", "mips64le", "mips64p32le",
"nios2",
"ppc64le",

13
cpu/cpu_loong64.go Normal file
View File

@@ -0,0 +1,13 @@
// Copyright 2022 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.
//go:build loong64
// +build loong64
package cpu
const cacheLineSize = 64
func initOptions() {
}