Skip to content

Commit 299257e

Browse files
authored
Merge pull request #9360 from SparkiDev/aarch64_sha256_vreg_fix
Aarch64 ASM: missing push and pop of vector regs
2 parents bac055d + d7807d3 commit 299257e

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

wolfcrypt/src/port/arm/armv8-sha256-asm.S

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,12 +120,14 @@ Transform_Sha256_Len_neon:
120120
.p2align 2
121121
_Transform_Sha256_Len_neon:
122122
#endif /* __APPLE__ */
123-
stp x29, x30, [sp, #-80]!
123+
stp x29, x30, [sp, #-112]!
124124
add x29, sp, #0
125125
stp x17, x19, [x29, #24]
126126
stp x20, x21, [x29, #40]
127127
stp x22, x23, [x29, #56]
128128
str x24, [x29, #72]
129+
stp d8, d9, [x29, #80]
130+
stp d10, d11, [x29, #96]
129131
#ifndef __APPLE__
130132
adrp x3, L_SHA256_transform_neon_len_k
131133
add x3, x3, :lo12:L_SHA256_transform_neon_len_k
@@ -1089,7 +1091,9 @@ L_sha256_len_neon_start:
10891091
ldp x20, x21, [x29, #40]
10901092
ldp x22, x23, [x29, #56]
10911093
ldr x24, [x29, #72]
1092-
ldp x29, x30, [sp], #0x50
1094+
ldp d8, d9, [x29, #80]
1095+
ldp d10, d11, [x29, #96]
1096+
ldp x29, x30, [sp], #0x70
10931097
ret
10941098
#ifndef __APPLE__
10951099
.size Transform_Sha256_Len_neon,.-Transform_Sha256_Len_neon

0 commit comments

Comments
 (0)