diff options
author | Jeffrey Walton <noloader@gmail.com> | 2019-05-25 06:23:19 -0400 |
---|---|---|
committer | Jeffrey Walton <noloader@gmail.com> | 2019-05-25 06:23:19 -0400 |
commit | fc10a7f1ea56b0c3c3ca7db8fa4de868cf3daad2 (patch) | |
tree | c86d705156d874fe672223c6d81394c3179a6ca8 /sha256_armv4.S | |
parent | 92df2a685f55a4777a897f0a921ed06e3e21401a (diff) | |
download | cryptopp-git-fc10a7f1ea56b0c3c3ca7db8fa4de868cf3daad2.tar.gz |
Fix SHA512 on ARM benchmarks
This was a mistake when porting from Cryptogams to Crypto++. The macros VFP_ABI_PUSH and VFP_ABI_POP needed to be defined because they save and restore SIMD register state. They were originally missing during the port. The benchmarks would hang because the doubles we used for benchmarking were blown away in sha512_block_data_order_neon.
Diffstat (limited to 'sha256_armv4.S')
-rw-r--r-- | sha256_armv4.S | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/sha256_armv4.S b/sha256_armv4.S index 74c208f7..ef1f4854 100644 --- a/sha256_armv4.S +++ b/sha256_armv4.S @@ -113,19 +113,15 @@ sha256_block_data_order: #else adr r3,.Lsha256_block_data_order #endif + #if __ARM_MAX_ARCH__>=7 - @ldr r12,.LCRYPTOGAMS_armcap ldr r12,=CRYPTOGAMS_armcap_P -# if !defined(_WIN32) - @ldr r12,[r3,r12] @ CRYPTOGAMS_armcap_P ldr r12,[r12] @ CRYPTOGAMS_armcap_P -# endif -# if defined(__APPLE__) || defined(_WIN32) - ldr r12,[r12] -# endif + tst r12,#ARMV7_NEON bne .LNEON #endif + add r2,r1,r2,lsl#6 @ len to point at the end of inp stmdb sp!,{r0,r1,r2,r4-r11,lr} ldmia r0,{r4,r5,r6,r7,r8,r9,r10,r11} |