From c09a0318b7b8dd501de52e332b38c748b36a869d Mon Sep 17 00:00:00 2001 From: Andy Polyakov Date: Wed, 3 May 2006 14:07:34 +0000 Subject: [PATCH] Minor PPC assembler updates. --- crypto/bn/asm/ppc-mont.pl | 1 + crypto/perlasm/ppc-xlate.pl | 3 ++- crypto/sha/asm/sha1-ppc.pl | 5 +++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/crypto/bn/asm/ppc-mont.pl b/crypto/bn/asm/ppc-mont.pl index 8a260212b7..e9149c98cf 100644 --- a/crypto/bn/asm/ppc-mont.pl +++ b/crypto/bn/asm/ppc-mont.pl @@ -98,6 +98,7 @@ $nlo="r25"; $nhi="r0"; $code=<<___; +.machine any .text .globl .bn_mul_mont diff --git a/crypto/perlasm/ppc-xlate.pl b/crypto/perlasm/ppc-xlate.pl index a51147a3a7..7e0f9e96c0 100755 --- a/crypto/perlasm/ppc-xlate.pl +++ b/crypto/perlasm/ppc-xlate.pl @@ -58,7 +58,8 @@ my $text = sub { my $machine = sub { my $junk = shift; my $arch = shift; - $arch = "ppc970" if ($arch eq "any" and $flavour =~ /osx/); + if ($arch eq "any" and $flavour =~ /osx/) + { $arch = ($flavour =~ /64/) ? "ppc970-64" : "ppc970"; } ".machine $arch"; }; diff --git a/crypto/sha/asm/sha1-ppc.pl b/crypto/sha/asm/sha1-ppc.pl index 9c955ef036..c1bf1f4872 100755 --- a/crypto/sha/asm/sha1-ppc.pl +++ b/crypto/sha/asm/sha1-ppc.pl @@ -62,10 +62,10 @@ sub BODY_00_19 { my ($i,$a,$b,$c,$d,$e,$f)=@_; my $j=$i+1; $code.=<<___ if ($i==0); - lwz @X[$i],$i*4($inp) + lwz @X[$i],`$i*4`($inp) ___ $code.=<<___ if ($i<15); - lwz @X[$j],$j*4($inp) + lwz @X[$j],`$j*4`($inp) add $f,$K,$e rotlwi $e,$a,5 add $f,$f,@X[$i] @@ -149,6 +149,7 @@ ___ } $code=<<___; +.machine any .text .globl .sha1_block_asm_data_order -- 2.25.1