Add mips big-endian asm

This commit is contained in:
Linus Yang 2017-08-18 21:16:49 +08:00
parent 769b99546b
commit 8d1e735041
2 changed files with 1835 additions and 8 deletions

View File

@ -507,6 +507,7 @@ AES_encrypt:
.frame $29,64,$31 .frame $29,64,$31
.mask 0xc0ff0000,-4 .mask 0xc0ff0000,-4
.set noreorder .set noreorder
.cpload $25
sub $29,64 sub $29,64
sw $31,64-1*4($29) sw $31,64-1*4($29)
sw $30,64-2*4($29) sw $30,64-2*4($29)
@ -518,8 +519,6 @@ AES_encrypt:
sw $18,64-8*4($29) sw $18,64-8*4($29)
sw $17,64-9*4($29) sw $17,64-9*4($29)
sw $16,64-10*4($29) sw $16,64-10*4($29)
.cplocal $7
.cpsetup $25,$0,AES_encrypt
.set reorder .set reorder
la $7,AES_Te # PIC-ified 'load address' la $7,AES_Te # PIC-ified 'load address'
@ -1050,6 +1049,7 @@ AES_decrypt:
.frame $29,64,$31 .frame $29,64,$31
.mask 0xc0ff0000,-4 .mask 0xc0ff0000,-4
.set noreorder .set noreorder
.cpload $25
sub $29,64 sub $29,64
sw $31,64-1*4($29) sw $31,64-1*4($29)
sw $30,64-2*4($29) sw $30,64-2*4($29)
@ -1061,8 +1061,6 @@ AES_decrypt:
sw $18,64-8*4($29) sw $18,64-8*4($29)
sw $17,64-9*4($29) sw $17,64-9*4($29)
sw $16,64-10*4($29) sw $16,64-10*4($29)
.cplocal $7
.cpsetup $25,$0,AES_decrypt
.set reorder .set reorder
la $7,AES_Td # PIC-ified 'load address' la $7,AES_Td # PIC-ified 'load address'
@ -1359,11 +1357,10 @@ AES_set_encrypt_key:
.frame $29,32,$31 .frame $29,32,$31
.mask 0xc0000000,-4 .mask 0xc0000000,-4
.set noreorder .set noreorder
.cpload $25
sub $29,32 sub $29,32
sw $31,32-1*4($29) sw $31,32-1*4($29)
sw $30,32-2*4($29) sw $30,32-2*4($29)
.cplocal $7
.cpsetup $25,$0,AES_set_encrypt_key
.set reorder .set reorder
la $7,AES_Te4 # PIC-ified 'load address' la $7,AES_Te4 # PIC-ified 'load address'
@ -1383,11 +1380,10 @@ AES_set_decrypt_key:
.frame $29,32,$31 .frame $29,32,$31
.mask 0xc0000000,-4 .mask 0xc0000000,-4
.set noreorder .set noreorder
.cpload $25
sub $29,32 sub $29,32
sw $31,32-1*4($29) sw $31,32-1*4($29)
sw $30,32-2*4($29) sw $30,32-2*4($29)
.cplocal $7
.cpsetup $25,$0,AES_set_decrypt_key
.set reorder .set reorder
la $7,AES_Te4 # PIC-ified 'load address' la $7,AES_Te4 # PIC-ified 'load address'

1831
lib/aes_acc/asm/mips_be.S Normal file

File diff suppressed because it is too large Load Diff