[Gmp-commit] /var/hg/gmp: Properly extend arg n for mode32.

mercurial at gmplib.org mercurial at gmplib.org
Thu Apr 5 10:08:45 CEST 2012


details:   /var/hg/gmp/rev/ebea11b4a7e6
changeset: 14797:ebea11b4a7e6
user:      Torbjorn Granlund <tege at gmplib.org>
date:      Thu Apr 05 10:08:42 2012 +0200
description:
Properly extend arg n for mode32.

diffstat:

 ChangeLog                     |  5 +++++
 mpn/powerpc64/p7/hamdist.asm  |  4 +++-
 mpn/powerpc64/p7/popcount.asm |  4 +++-
 3 files changed, 11 insertions(+), 2 deletions(-)

diffs (40 lines):

diff -r cb1e505d37c6 -r ebea11b4a7e6 ChangeLog
--- a/ChangeLog	Wed Apr 04 20:08:50 2012 +0200
+++ b/ChangeLog	Thu Apr 05 10:08:42 2012 +0200
@@ -1,3 +1,8 @@
+2012-04-05  Torbjorn Granlund  <tege at gmplib.org>
+
+	* mpn/powerpc64/p7/popcount.asm: Properly extend arg n for mode32.
+	* mpn/powerpc64/p7/hamdist.asm: Likewise.
+
 2012-04-04  Torbjorn Granlund  <tege at gmplib.org>
 
 	* mpn/powerpc64/p7/popcount.asm: New file.
diff -r cb1e505d37c6 -r ebea11b4a7e6 mpn/powerpc64/p7/hamdist.asm
--- a/mpn/powerpc64/p7/hamdist.asm	Wed Apr 04 20:08:50 2012 +0200
+++ b/mpn/powerpc64/p7/hamdist.asm	Thu Apr 05 10:08:42 2012 +0200
@@ -36,7 +36,9 @@
 	std	r31, -8(r1)
 
 	addi	r0, n, 1
-	srdi	r0, r0, 1
+ifdef(`HAVE_ABI_mode32',
+`	rldicl	r0, r0, 63,33',	C ...branch count
+`	srdi	r0, r0, 1')	C ...for ctr
 	mtctr	r0
 
 	andi.	r0, n, 1
diff -r cb1e505d37c6 -r ebea11b4a7e6 mpn/powerpc64/p7/popcount.asm
--- a/mpn/powerpc64/p7/popcount.asm	Wed Apr 04 20:08:50 2012 +0200
+++ b/mpn/powerpc64/p7/popcount.asm	Thu Apr 05 10:08:42 2012 +0200
@@ -32,7 +32,9 @@
 ASM_START()
 PROLOGUE(mpn_popcount)
 	addi	r0, n, 1
-	srdi	r0, r0, 1
+ifdef(`HAVE_ABI_mode32',
+`	rldicl	r0, r0, 63,33',	C ...branch count
+`	srdi	r0, r0, 1')	C ...for ctr
 	mtctr	r0
 
 	andi.	r0, n, 1


More information about the gmp-commit mailing list