mirror of
https://github.com/emmansun/gmsm.git
synced 2025-04-26 04:06:18 +08:00
try out arm64 inst
This commit is contained in:
parent
7154c92ba2
commit
5bd003ebbe
14
sm4/arm64_verify.s
Normal file
14
sm4/arm64_verify.s
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
#include "textflag.h"
|
||||||
|
|
||||||
|
// func tblAsm(in, imm, out *byte)
|
||||||
|
TEXT ·tblAsm(SB),NOSPLIT,$0
|
||||||
|
MOVD in+0(FP), R8
|
||||||
|
MOVD imm+8(FP), R9
|
||||||
|
MOVD out+16(FP), R10
|
||||||
|
|
||||||
|
VLD1 (R8), [V0.B16]
|
||||||
|
VLD1 (R9), [V1.B16]
|
||||||
|
|
||||||
|
VTBL V1.B16, [V0.B16], V2.B16
|
||||||
|
VST1 V2.B16, (R10)
|
||||||
|
RET
|
10
sm4/arm64_verify_test.go
Normal file
10
sm4/arm64_verify_test.go
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
//go:build arm64
|
||||||
|
// +build arm64
|
||||||
|
|
||||||
|
//go:noescape
|
||||||
|
func tblAsm(in, imm, out *byte)
|
||||||
|
|
||||||
|
func TestTblAsm(t *testing.T) {
|
||||||
|
in := []byte{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15}
|
||||||
|
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user