projects
/
oweals
/
openssl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
24c2cd3
)
chacha/asm/chacha-x86.pl: make it compile on legacy systems.
author
Andy Polyakov
<appro@openssl.org>
Sun, 1 May 2016 12:09:15 +0000
(14:09 +0200)
committer
Andy Polyakov
<appro@openssl.org>
Mon, 2 May 2016 10:34:42 +0000
(12:34 +0200)
Usage of $ymm variable is a bit misleading here, it doesn't refer
to %ymm register bank, but rather to VEX instruction encoding,
which AMD XOP code path depends on.
Reviewed-by: Richard Levitte <levitte@openssl.org>
crypto/chacha/asm/chacha-x86.pl
patch
|
blob
|
history
diff --git
a/crypto/chacha/asm/chacha-x86.pl
b/crypto/chacha/asm/chacha-x86.pl
index 8b9696ff0252a4982cd35b06125e6901ac4455f9..d18663badd7ecd30d1295e3060abd001ce798ff5 100755
(executable)
--- a/
crypto/chacha/asm/chacha-x86.pl
+++ b/
crypto/chacha/asm/chacha-x86.pl
@@
-437,8
+437,10
@@
my ($ap,$bp,$cp,$dp)=map(($_&~3)+(($_-1)&3),($ai,$bi,$ci,$di)); # previous
&function_begin("ChaCha20_ssse3");
&set_label("ssse3_shortcut");
+if ($ymm) {
&test (&DWP(4,"ebp"),1<<11); # test XOP bit
&jnz (&label("xop_shortcut"));
+}
&mov ($out,&wparam(0));
&mov ($inp,&wparam(1));
@@
-770,7
+772,7
@@
sub SSSE3ROUND { # critical path is 20 "SIMD ticks" per round
}
&asciz ("ChaCha20 for x86, CRYPTOGAMS by <appro\@openssl.org>");
-if ($
x
mm) {
+if ($
y
mm) {
my ($xa,$xa_,$xb,$xb_,$xc,$xc_,$xd,$xd_)=map("xmm$_",(0..7));
my ($out,$inp,$len)=("edi","esi","ecx");