summaryrefslogtreecommitdiff
path: root/mpn/mips64
diff options
context:
space:
mode:
authorTorbjorn Granlund <tege@gmplib.org>2011-03-14 16:06:57 +0100
committerTorbjorn Granlund <tege@gmplib.org>2011-03-14 16:06:57 +0100
commit0e9c41b5bf52fa2bd109f78957b7f0e85e72cda9 (patch)
tree564907c24a29c94c03fd9d959fd3f038bc60b4a2 /mpn/mips64
parent8384ae9a8631a541ae2d15af2bcc1e685e6ea990 (diff)
downloadgmp-0e9c41b5bf52fa2bd109f78957b7f0e85e72cda9.tar.gz
Add _nc entry point.
Diffstat (limited to 'mpn/mips64')
-rw-r--r--mpn/mips64/add_n.asm15
-rw-r--r--mpn/mips64/sub_n.asm15
2 files changed, 26 insertions, 4 deletions
diff --git a/mpn/mips64/add_n.asm b/mpn/mips64/add_n.asm
index 1a3978c3f..d6cdf9370 100644
--- a/mpn/mips64/add_n.asm
+++ b/mpn/mips64/add_n.asm
@@ -1,7 +1,7 @@
dnl MIPS64 mpn_add_n -- Add two limb vectors of the same length > 0 and store
dnl sum in a third limb vector.
-dnl Copyright 1995, 2000, 2001, 2002 Free Software Foundation, Inc.
+dnl Copyright 1995, 2000, 2001, 2002, 2011 Free Software Foundation, Inc.
dnl This file is part of the GNU MP Library.
@@ -27,6 +27,17 @@ C s2_ptr $6
C size $7
ASM_START()
+PROLOGUE(mpn_add_nc)
+ ld $10,0($5)
+ ld $11,0($6)
+
+ daddiu $7,$7,-1
+ and $9,$7,4-1 C number of limbs in first loop
+ beq $9,$0,.L0 C if multiple of 4 limbs, skip first loop
+ move $2,$8
+ b .Loop0
+ dsubu $7,$7,$9
+EPILOGUE()
PROLOGUE(mpn_add_n)
ld $10,0($5)
ld $11,0($6)
@@ -109,4 +120,4 @@ PROLOGUE(mpn_add_n)
sd $11,0($4)
j $31
or $2,$2,$8
-EPILOGUE(mpn_add_n)
+EPILOGUE()
diff --git a/mpn/mips64/sub_n.asm b/mpn/mips64/sub_n.asm
index b28c1ced9..1419cbfd1 100644
--- a/mpn/mips64/sub_n.asm
+++ b/mpn/mips64/sub_n.asm
@@ -1,7 +1,7 @@
dnl MIPS64 mpn_sub_n -- Subtract two limb vectors of the same length > 0 and
dnl store difference in a third limb vector.
-dnl Copyright 1995, 2000, 2001, 2002 Free Software Foundation, Inc.
+dnl Copyright 1995, 2000, 2001, 2002, 2011 Free Software Foundation, Inc.
dnl This file is part of the GNU MP Library.
@@ -27,6 +27,17 @@ C s2_ptr $6
C size $7
ASM_START()
+PROLOGUE(mpn_sub_nc)
+ ld $10,0($5)
+ ld $11,0($6)
+
+ daddiu $7,$7,-1
+ and $9,$7,4-1 C number of limbs in first loop
+ beq $9,$0,.L0 C if multiple of 4 limbs, skip first loop
+ move $2,$8
+ b .Loop0
+ dsubu $7,$7,$9
+EPILOGUE()
PROLOGUE(mpn_sub_n)
ld $10,0($5)
ld $11,0($6)
@@ -109,4 +120,4 @@ PROLOGUE(mpn_sub_n)
sd $11,0($4)
j $31
or $2,$2,$8
-EPILOGUE(mpn_sub_n)
+EPILOGUE()