diff options
author | Andy Polyakov <appro@openssl.org> | 2005-10-09 09:53:58 +0000 |
---|---|---|
committer | Andy Polyakov <appro@openssl.org> | 2005-10-09 09:53:58 +0000 |
commit | 54f3d200d32e70aa1c5b4d72e6c879e3da769926 (patch) | |
tree | f67fcf72ceedcc1bcd64cf65fee70dcf0a5ece19 /crypto/perlasm/x86unix.pl | |
parent | 3f67e11fabc8e02cfe2bd5b53c1cc0e8126cf31b (diff) | |
download | openssl-54f3d200d32e70aa1c5b4d72e6c879e3da769926.tar.gz |
Throw in bn/asm/x86-mont.pl Montgomery multiplication "teaser".
Diffstat (limited to 'crypto/perlasm/x86unix.pl')
-rw-r--r-- | crypto/perlasm/x86unix.pl | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/crypto/perlasm/x86unix.pl b/crypto/perlasm/x86unix.pl index 9bc5c0e893..38c7a6df42 100644 --- a/crypto/perlasm/x86unix.pl +++ b/crypto/perlasm/x86unix.pl @@ -215,7 +215,6 @@ sub main'cld { &out0("cld"); } # SSE2 sub main'emms { &out0("emms"); } sub main'movd { &out2("movd",@_); } -sub main'movq { &out2("movq",@_); } sub main'movdqu { &out2("movdqu",@_); } sub main'movdqa { &out2("movdqa",@_); } sub main'movdq2q{ &out2("movdq2q",@_); } @@ -227,6 +226,13 @@ sub main'psllq { &out2("psllq",@_); } sub main'pxor { &out2("pxor",@_); } sub main'por { &out2("por",@_); } sub main'pand { &out2("pand",@_); } +sub main'movq { + local($p1,$p2)=@_; + if ($p1=~/^mm[0-7]$/ && $p2=~/^mm[0-7]$/) + # movq between mmx registers sinks Intel CPUs + { push(@out,"\tpshufw\t\$0xe4,%$p2,%$p1\n"); } + else { &out2("movq",@_); } + } # The bswapl instruction is new for the 486. Emulate if i386. sub main'bswap |