Merge pull request #9 from pattop/master
ppc32: fix fp_montgomery_reduce assembly
This commit is contained in:
commit
e0fe602802
@ -325,22 +325,18 @@ asm( \
|
|||||||
asm( \
|
asm( \
|
||||||
" mullw 16,%3,%4 \n\t" \
|
" mullw 16,%3,%4 \n\t" \
|
||||||
" mulhwu 17,%3,%4 \n\t" \
|
" mulhwu 17,%3,%4 \n\t" \
|
||||||
" addc 16,16,%0 \n\t" \
|
" addc 16,16,%2 \n\t" \
|
||||||
" addze 17,17 \n\t" \
|
" addze 17,17 \n\t" \
|
||||||
" lwz 18,%1 \n\t" \
|
" addc %1,16,%5 \n\t" \
|
||||||
" addc 16,16,18 \n\t" \
|
|
||||||
" addze %0,17 \n\t" \
|
" addze %0,17 \n\t" \
|
||||||
" stw 16,%1 \n\t" \
|
:"=r"(cy),"=r"(_c[0]):"0"(cy),"r"(mu),"r"(tmpm[0]),"1"(_c[0]):"16", "17", "cc"); ++tmpm;
|
||||||
:"=r"(cy),"=g"(_c[0]):"0"(cy),"r"(mu),"r"(tmpm[0]),"1"(_c[0]):"16", "17", "18","cc"); ++tmpm;
|
|
||||||
|
|
||||||
#define PROPCARRY \
|
#define PROPCARRY \
|
||||||
asm( \
|
asm( \
|
||||||
" lwz 16,%1 \n\t" \
|
" addc %1,%3,%2 \n\t" \
|
||||||
" addc 16,16,%0 \n\t" \
|
" xor %0,%2,%2 \n\t" \
|
||||||
" stw 16,%1 \n\t" \
|
" addze %0,%2 \n\t" \
|
||||||
" xor %0,%0,%0 \n\t" \
|
:"=r"(cy),"=r"(_c[0]):"0"(cy),"1"(_c[0]):"cc");
|
||||||
" addze %0,%0 \n\t" \
|
|
||||||
:"=r"(cy),"=g"(_c[0]):"0"(cy),"1"(_c[0]):"16","cc");
|
|
||||||
|
|
||||||
/******************************************************************/
|
/******************************************************************/
|
||||||
#elif defined(TFM_PPC64)
|
#elif defined(TFM_PPC64)
|
||||||
|
Loading…
Reference in New Issue
Block a user