diff options
author | Torbjorn Granlund <tege@gmplib.org> | 2012-04-21 21:09:01 +0200 |
---|---|---|
committer | Torbjorn Granlund <tege@gmplib.org> | 2012-04-21 21:09:01 +0200 |
commit | 48700d5f6b8e6b0cd92cbb7ab09e62e1e8540db5 (patch) | |
tree | 020f3ea975d75ccb846ea7e7ff2b21d625691283 /mpn/arm/copyi.asm | |
parent | 43c4d906132b7471b7f6508dba333cc924dc21d4 (diff) | |
download | gmp-48700d5f6b8e6b0cd92cbb7ab09e62e1e8540db5.tar.gz |
ARM changes.
Diffstat (limited to 'mpn/arm/copyi.asm')
-rw-r--r-- | mpn/arm/copyi.asm | 31 |
1 files changed, 17 insertions, 14 deletions
diff --git a/mpn/arm/copyi.asm b/mpn/arm/copyi.asm index 5ee93acd4..ba9824192 100644 --- a/mpn/arm/copyi.asm +++ b/mpn/arm/copyi.asm @@ -1,6 +1,6 @@ dnl ARM mpn_copyi. -dnl Copyright 2003 Free Software Foundation, Inc. +dnl Copyright 2003, 2012 Free Software Foundation, Inc. dnl This file is part of the GNU MP Library. @@ -19,12 +19,16 @@ dnl along with the GNU MP Library. If not, see http://www.gnu.org/licenses/. include(`../config.m4') -C This runs at 3 cycles/limb in the StrongARM. - -define(`rp',`r0') -define(`up',`r1') -define(`n',`r2') +C cycles/limb +C StrongARM ? +C XScale ? +C Cortex-A8 ? +C Cortex-A9 1.5 +C Cortex-A15 ? +define(`rp', `r0') +define(`up', `r1') +define(`n', `r2') ASM_START() PROLOGUE(mpn_copyi) @@ -39,15 +43,14 @@ L(skip1): stmia rp!, { r3, r12 } C store 2 limbs L(skip2): bics n, n, #3 - beq L(return) + beq L(rtn) stmfd sp!, { r7, r8, r9 } C save regs on stack -L(loop): - ldmia up!, { r3, r8, r9, r12 } C load 4 limbs - ldr r7, [rp, #12] C cache allocate + +L(top): ldmia up!, { r3, r8, r9, r12 } C load 4 limbs subs n, n, #4 stmia rp!, { r3, r8, r9, r12 } C store 4 limbs - bne L(loop) + bne L(top) + ldmfd sp!, { r7, r8, r9 } C restore regs from stack -L(return): - mov pc, lr -EPILOGUE(mpn_copyi) +L(rtn): bx lr +EPILOGUE() |