Text file src/internal/cpu/cpu_arm64.s

     1  // Copyright 2020 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  #include "textflag.h"
     6  
     7  // func getisar0() uint64
     8  TEXT ·getisar0(SB),NOSPLIT,$0
     9  	// get Instruction Set Attributes 0 into R0
    10  	MRS	ID_AA64ISAR0_EL1, R0
    11  	MOVD	R0, ret+0(FP)
    12  	RET
    13  
    14  // func getisar1() uint64
    15  TEXT ·getisar1(SB),NOSPLIT,$0-8
    16  	// get Instruction Set Attributes 1 into R0
    17  	MRS	ID_AA64ISAR1_EL1, R0
    18  	MOVD	R0, ret+0(FP)
    19  	RET
    20  
    21  // func getpfr0() uint64
    22  TEXT ·getpfr0(SB),NOSPLIT,$0-8
    23  	// get Processor Feature Register 0 into R0
    24  	MRS ID_AA64PFR0_EL1, R0
    25  	MOVD R0, ret+0(FP)
    26  	RET
    27  
    28  // func getMIDR() uint64
    29  TEXT ·getMIDR(SB), NOSPLIT, $0-8
    30  	MRS	MIDR_EL1, R0
    31  	MOVD	R0, ret+0(FP)
    32  	RET
    33  

View as plain text