sha/asm/sha1-x86_64.pl: fix crash in SHAEXT code on Windows.
authorAndy Polyakov <appro@openssl.org>
Sun, 31 Jul 2016 19:19:57 +0000 (21:19 +0200)
committerAndy Polyakov <appro@openssl.org>
Thu, 11 Aug 2016 11:39:57 +0000 (13:39 +0200)
RT#4530

Reviewed-by: Tim Hudson <tjh@openssl.org>
crypto/sha/asm/sha1-x86_64.pl

index e8f61ab..97baae3 100755 (executable)
@@ -380,9 +380,9 @@ $code.=<<___;
 .align 16
 .Loop_shaext:
        dec             $num
 .align 16
 .Loop_shaext:
        dec             $num
-       lea             0x40($inp),%rax         # next input block
+       lea             0x40($inp),%r         # next input block
        paddd           @MSG[0],$E
        paddd           @MSG[0],$E
-       cmovne          %rax,$inp
+       cmovne          %r8,$inp
        movdqa          $ABCD,$ABCD_SAVE        # offload $ABCD
 ___
 for($i=0;$i<20-4;$i+=2) {
        movdqa          $ABCD,$ABCD_SAVE        # offload $ABCD
 ___
 for($i=0;$i<20-4;$i+=2) {