summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjoseph <joseph@7b3dc134-2b1b-0410-93df-9e9f96275f8d>2007-04-16 19:27:58 +0000
committerjoseph <joseph@7b3dc134-2b1b-0410-93df-9e9f96275f8d>2007-04-16 19:27:58 +0000
commit02ea1e3487e7464c0813067d3c850b277ace63e9 (patch)
tree79fc170e5ed1d560a7ca3672f249429681c16083
parent1590e6cad283b71a34158d9a8f928d1719440d41 (diff)
downloadeglibc2-02ea1e3487e7464c0813067d3c850b277ace63e9.tar.gz
libc:
* sysdeps/powerpc/fpu/bits/fenvinline.h: Test _SOFT_FLOAT together with __NO_FPRS__. * sysdeps/powerpc/fpu/bits/mathinline.h: Likewise. * sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext-common.S: Use __GETCONTEXT_EXTRA instead of __CONTEXT_EXTRA. * sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S: Use __SETCONTEXT_EXTRA instead of __CONTEXT_EXTRA. * sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S: Use __GETCONTEXT_EXTRA and __SETCONTEXT_EXTRA instead of __CONTEXT_EXTRA. ports: * sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/getcontext-extra.S: Put contents in a gas macro. * sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/setcontext-extra.S: Likewise. * sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/getcontext.S: Update. * sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/setcontext.S: Update. * sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/swapcontext.S: Update. git-svn-id: svn://svn.eglibc.org/branches/eglibc-2_5@1999 7b3dc134-2b1b-0410-93df-9e9f96275f8d
-rw-r--r--libc/ChangeLog.eglibc13
-rw-r--r--libc/sysdeps/powerpc/fpu/bits/fenvinline.h3
-rw-r--r--libc/sysdeps/powerpc/fpu/bits/mathinline.h2
-rw-r--r--libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext-common.S4
-rw-r--r--libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S4
-rw-r--r--libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S8
-rw-r--r--ports/ChangeLog.eglibc13
-rw-r--r--ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/getcontext-extra.S5
-rw-r--r--ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/getcontext.S4
-rw-r--r--ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/setcontext-extra.S5
-rw-r--r--ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/setcontext.S4
-rw-r--r--ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/swapcontext.S5
12 files changed, 52 insertions, 18 deletions
diff --git a/libc/ChangeLog.eglibc b/libc/ChangeLog.eglibc
index 20192e06e..a1e195cb1 100644
--- a/libc/ChangeLog.eglibc
+++ b/libc/ChangeLog.eglibc
@@ -1,3 +1,16 @@
+2007-04-16 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/powerpc/fpu/bits/fenvinline.h: Test _SOFT_FLOAT together
+ with __NO_FPRS__.
+ * sysdeps/powerpc/fpu/bits/mathinline.h: Likewise.
+ * sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext-common.S:
+ Use __GETCONTEXT_EXTRA instead of __CONTEXT_EXTRA.
+ * sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S:
+ Use __SETCONTEXT_EXTRA instead of __CONTEXT_EXTRA.
+ * sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S:
+ Use __GETCONTEXT_EXTRA and __SETCONTEXT_EXTRA instead of
+ __CONTEXT_EXTRA.
+
2007-04-13 Jim Blandy <jimb@codesourcery.com>
* scripts/run-with-env.sh: New script.
diff --git a/libc/sysdeps/powerpc/fpu/bits/fenvinline.h b/libc/sysdeps/powerpc/fpu/bits/fenvinline.h
index 7e632933e..1311c0337 100644
--- a/libc/sysdeps/powerpc/fpu/bits/fenvinline.h
+++ b/libc/sysdeps/powerpc/fpu/bits/fenvinline.h
@@ -18,7 +18,8 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
-#if defined __GNUC__ && !defined __NO_FPRS__ && !defined __NO_MATH_INLINES
+#if defined __GNUC__ && !defined _SOFT_FLOAT && !defined __NO_FPRS__ \
+ && !defined __NO_MATH_INLINES
/* Inline definition for fegetround. */
# define fegetround() \
diff --git a/libc/sysdeps/powerpc/fpu/bits/mathinline.h b/libc/sysdeps/powerpc/fpu/bits/mathinline.h
index a6414ba77..448f3f263 100644
--- a/libc/sysdeps/powerpc/fpu/bits/mathinline.h
+++ b/libc/sysdeps/powerpc/fpu/bits/mathinline.h
@@ -28,7 +28,7 @@
# define __MATH_INLINE extern __inline
#endif /* __cplusplus */
-#if defined __GNUC__ && !defined __NO_FPRS__
+#if defined __GNUC__ && !defined _SOFT_FLOAT && !defined __NO_FPRS__
#ifdef __USE_ISOC99
# if !__GNUC_PREREQ (2,97)
diff --git a/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext-common.S b/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext-common.S
index bad479998..c84d18ced 100644
--- a/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext-common.S
+++ b/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext-common.S
@@ -268,8 +268,8 @@ ENTRY(__CONTEXT_FUNC_NAME)
# endif
#endif
-#ifdef __CONTEXT_EXTRA
-#include <getcontext-extra.S>
+#ifdef __GETCONTEXT_EXTRA
+ __GETCONTEXT_EXTRA
#endif
/* We need to set up parms and call sigprocmask which will clobber
diff --git a/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S b/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S
index c98a4190d..4df677fe8 100644
--- a/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S
+++ b/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S
@@ -233,8 +233,8 @@ ENTRY(__CONTEXT_FUNC_NAME)
lfd fp31,_UC_FREGS+(31*8)(r31)
#endif /* __CONTEXT_ENABLE_FPRS */
-#ifdef __CONTEXT_EXTRA
-#include <setcontext-extra.S>
+#ifdef __SETCONTEXT_EXTRA
+ __SETCONTEXT_EXTRA
#endif
/* Restore LR and CCR, and set CTR to the NIP value */
diff --git a/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S b/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S
index d5e1f2c7d..35242152f 100644
--- a/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S
+++ b/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S
@@ -270,8 +270,8 @@ ENTRY(__CONTEXT_FUNC_NAME)
# endif /* __CONTEXT_ENABLE_VRS */
#endif /* __CONTEXT_ENABLE_FPRS */
-#ifdef __CONTEXT_EXTRA
-#include <getcontext-extra.S>
+#ifdef __GETCONTEXT_EXTRA
+ __GETCONTEXT_EXTRA
#endif
/* Restore ucontext (parm1) from stack. */
@@ -463,8 +463,8 @@ ENTRY(__CONTEXT_FUNC_NAME)
lfd fp31,_UC_FREGS+(31*8)(r31)
#endif /* __CONTEXT_ENABLE_FPRS */
-#ifdef __CONTEXT_EXTRA
-#include <setcontext-extra.S>
+#ifdef __SETCONTEXT_EXTRA
+ __SETCONTEXT_EXTRA
#endif
/* Restore LR and CCR, and set CTR to the NIP value */
diff --git a/ports/ChangeLog.eglibc b/ports/ChangeLog.eglibc
index d7088a423..df08f674c 100644
--- a/ports/ChangeLog.eglibc
+++ b/ports/ChangeLog.eglibc
@@ -1,3 +1,16 @@
+2007-04-16 Joseph Myers <joseph@codesourcery.com>
+
+ * sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/getcontext-extra.S:
+ Put contents in a gas macro.
+ * sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/setcontext-extra.S:
+ Likewise.
+ * sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/getcontext.S:
+ Update.
+ * sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/setcontext.S:
+ Update.
+ * sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/swapcontext.S:
+ Update.
+
2006-03-28 Paul Brook <paul@codesourcery.com>
* sysdeps/arm/machine-gmon.h (MCOUNT): Add Thumb-2 implementation.
diff --git a/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/getcontext-extra.S b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/getcontext-extra.S
index 145f4aa86..d1ac7ee89 100644
--- a/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/getcontext-extra.S
+++ b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/getcontext-extra.S
@@ -1,5 +1,5 @@
/* Save current context. Support for saving high parts of registers.
- Copyright (C) 2006 Free Software Foundation, Inc.
+ Copyright (C) 2006, 2007 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Joseph Myers <joseph@codesourcery.com>, 2006.
@@ -21,6 +21,7 @@
/* We follow the kernel's layout, which saves the high parts of the
SPE registers in the vregs area, immediately followed by the
SPEFSCR value. */
+.macro getcontext_extra
la r10,(_UC_VREGS)(r3)
evstwwe r0,(0*4)(r10)
evstwwe r1,(1*4)(r10)
@@ -56,3 +57,5 @@
evstwwe r31,(31*4)(r10)
mfspefscr r9
stw r9,(32*4)(r10)
+.endm
+#define __GETCONTEXT_EXTRA getcontext_extra
diff --git a/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/getcontext.S b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/getcontext.S
index 5b3f2cc54..8ac9c97af 100644
--- a/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/getcontext.S
+++ b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/getcontext.S
@@ -1,5 +1,5 @@
/* Save current context.
- Copyright (C) 2002, 2004, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2002, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -28,7 +28,7 @@
#define __CONTEXT_FUNC_NAME __getcontext
#undef __CONTEXT_ENABLE_FPRS
#undef __CONTEXT_ENABLE_VRS
-#define __CONTEXT_EXTRA
+#include "getcontext-extra.S"
#include "getcontext-common.S"
diff --git a/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/setcontext-extra.S b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/setcontext-extra.S
index 089153c1e..78af4831f 100644
--- a/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/setcontext-extra.S
+++ b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/setcontext-extra.S
@@ -1,5 +1,5 @@
/* Jump to a new context. Support for restoring high parts of registers.
- Copyright (C) 2006 Free Software Foundation, Inc.
+ Copyright (C) 2006, 2007 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Joseph Myers <joseph@codesourcery.com>, 2006.
@@ -18,6 +18,7 @@
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
+.macro setcontext_extra
lwz r3,_UC_VREGS+(0*4)(r31)
evmergelo r0,r3,r0
lwz r3,_UC_VREGS+(1*4)(r31)
@@ -88,3 +89,5 @@
evmergelo r31,r3,r31
lwz r3,_UC_VREGS+(32*4)(r31)
mtspefscr r3
+.endm
+#define __SETCONTEXT_EXTRA setcontext_extra
diff --git a/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/setcontext.S b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/setcontext.S
index f4344f76f..775903328 100644
--- a/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/setcontext.S
+++ b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/setcontext.S
@@ -1,5 +1,5 @@
/* Jump to a new context.
- Copyright (C) 2002, 2004, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2002, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -28,7 +28,7 @@
#define __CONTEXT_FUNC_NAME __setcontext
#undef __CONTEXT_ENABLE_FPRS
#undef __CONTEXT_ENABLE_VRS
-#define __CONTEXT_EXTRA
+#include "setcontext-extra.S"
#include "setcontext-common.S"
diff --git a/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/swapcontext.S b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/swapcontext.S
index d5be04d63..caa36c61e 100644
--- a/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/swapcontext.S
+++ b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/e500/fpu/swapcontext.S
@@ -1,5 +1,5 @@
/* Save current context and jump to a new context.
- Copyright (C) 2002, 2004, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2002, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -28,7 +28,8 @@
#define __CONTEXT_FUNC_NAME __swapcontext
#undef __CONTEXT_ENABLE_FPRS
#undef __CONTEXT_ENABLE_VRS
-#define __CONTEXT_EXTRA
+#include "getcontext-extra.S"
+#include "setcontext-extra.S"
# include "swapcontext-common.S"