mirror of
https://github.com/golang/go
synced 2024-11-19 13:04:45 -07:00
ee58eccc56
Also move the arm64 CountByte implementation while we're here. Fixes #19792 Change-Id: I1e0fdf1e03e3135af84150a2703b58dad1b0d57e Reviewed-on: https://go-review.googlesource.com/98518 Run-TryBot: Keith Randall <khr@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
20 lines
433 B
Go
20 lines
433 B
Go
// 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 runtime
|
|
|
|
import "internal/cpu"
|
|
|
|
const (
|
|
// bit masks taken from bits/hwcap.h
|
|
_HWCAP_S390_VX = 2048 // vector facility
|
|
)
|
|
|
|
func archauxv(tag, val uintptr) {
|
|
switch tag {
|
|
case _AT_HWCAP: // CPU capability bit flags
|
|
cpu.S390X.HasVX = val&_HWCAP_S390_VX != 0
|
|
}
|
|
}
|