[Gmp-commit] /var/hg/gmp-5.0: Fix r0 clobbering issue with "large" code affec...
mercurial at gmplib.org
mercurial at gmplib.org
Sat Jul 21 19:19:14 CEST 2012
details: /var/hg/gmp-5.0/rev/829215e83ff1
changeset: 13585:829215e83ff1
user: Torbjorn Granlund <tege at gmplib.org>
date: Sat Jul 21 19:19:11 2012 +0200
description:
Fix r0 clobbering issue with "large" code affecting elf+darwin PIC.
diffstat:
ChangeLog | 5 +++++
mpn/powerpc32/vmx/mod_34lsub1.asm | 17 +++++++++--------
2 files changed, 14 insertions(+), 8 deletions(-)
diffs (79 lines):
diff -r 816c18dbd492 -r 829215e83ff1 ChangeLog
--- a/ChangeLog Tue Jun 19 15:02:48 2012 +0200
+++ b/ChangeLog Sat Jul 21 19:19:11 2012 +0200
@@ -1,3 +1,8 @@
+2012-07-21 Torbjorn Granlund <tege at gmplib.org>
+
+ * mpn/powerpc32/vmx/mod_34lsub1.asm: Fix r0 clobbering issue with
+ "large" code affecting elf+darwin PIC.
+
2012-05-27 Marco Bodrato <bodrato at mail.dm.unipi.it>
* mpn/x86_64/fat/fat.c: abort iff longmode-capable-bit is turned off.
diff -r 816c18dbd492 -r 829215e83ff1 mpn/powerpc32/vmx/mod_34lsub1.asm
--- a/mpn/powerpc32/vmx/mod_34lsub1.asm Tue Jun 19 15:02:48 2012 +0200
+++ b/mpn/powerpc32/vmx/mod_34lsub1.asm Sat Jul 21 19:19:11 2012 +0200
@@ -1,6 +1,7 @@
dnl PowerPC-32 mpn_mod_34lsub1 -- mpn remainder mod 2^24-1.
-dnl Copyright 2002, 2003, 2005, 2006, 2007 Free Software Foundation, Inc.
+dnl Copyright 2002, 2003, 2005, 2006, 2007, 2012 Free Software Foundation,
+dnl Inc.
dnl This file is part of the GNU MP Library.
@@ -135,15 +136,15 @@
andi. r7, up, 15
vxor a0, v0, v0
- lis r0, 0xaaaa
+ lis r9, 0xaaaa
vxor a1, v0, v0
- ori r0, r0, 0xaaab
+ ori r9, r9, 0xaaab
vxor a2, v0, v0
li r5, 16
vxor c0, v0, v0
li r6, 32
vxor c1, v0, v0
- LEAL( r11, cnsts)
+ LEAL( r11, cnsts) C CAUTION clobbers r0 for elf, darwin
vxor c2, v0, v0
vxor z, v0, v0
@@ -158,7 +159,7 @@
vsldoi a2, z, a2, 12
addi n, n, 9
- mulhwu r0, n, r0
+ mulhwu r0, n, r9
srwi r0, r0, 3 C r0 = floor(n/12)
mtctr r0
@@ -174,7 +175,7 @@
vsldoi a1, z, a1, 8
addi n, n, 6
- mulhwu r0, n, r0
+ mulhwu r0, n, r9
srwi r0, r0, 3 C r0 = floor(n/12)
mtctr r0
@@ -188,7 +189,7 @@
vsldoi a0, z, a0, 4
addi n, n, 3
- mulhwu r0, n, r0
+ mulhwu r0, n, r9
srwi r0, r0, 3 C r0 = floor(n/12)
mtctr r0
@@ -197,7 +198,7 @@
b L(0)
L(aligned16):
- mulhwu r0, n, r0
+ mulhwu r0, n, r9
srwi r0, r0, 3 C r0 = floor(n/12)
mtctr r0
More information about the gmp-commit
mailing list