mirror of
https://github.com/golang/sys.git
synced 2026-01-29 07:02:06 +03:00
The CPUCFG instruction on loong64 was introduced in Go1.24, which caused compilation errors when using this feature in Go1.23 and earlier versions. Change-Id: I68891bbfc527194ecdafebac3398e700bfb53c2f Reviewed-on: https://go-review.googlesource.com/c/sys/+/656915 Reviewed-by: Meidan Li <limeidan@loongson.cn> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: David Chase <drchase@google.com> Reviewed-by: Junyang Shao <shaojunyang@google.com>
14 lines
358 B
ArmAsm
14 lines
358 B
ArmAsm
// Copyright 2025 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.
|
|
|
|
#include "textflag.h"
|
|
|
|
// func get_cpucfg(reg uint32) uint32
|
|
TEXT ·get_cpucfg(SB), NOSPLIT|NOFRAME, $0
|
|
MOVW reg+0(FP), R5
|
|
// CPUCFG R5, R4 = 0x00006ca4
|
|
WORD $0x00006ca4
|
|
MOVW R4, ret+8(FP)
|
|
RET
|