summaryrefslogtreecommitdiff
path: root/libgo/go/internal/cpu/cpu_arm64_test.go
blob: f4c419a23f3151e13dc067671eba63ebef93e5cc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
// Copyright 2018 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 cpu_test

import (
	. "internal/cpu"
	"runtime"
	"testing"
)

func TestARM64minimalFeatures(t *testing.T) {
	switch runtime.GOOS {
	case "linux", "android":
	default:
		t.Skipf("%s/arm64 is not supported", runtime.GOOS)
	}

	if !ARM64.HasASIMD {
		t.Fatalf("HasASIMD expected true, got false")
	}
	if !ARM64.HasFP {
		t.Fatalf("HasFP expected true, got false")
	}
}