aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'soft-fp/soft-fp.h')
-rw-r--r--soft-fp/soft-fp.h37
1 files changed, 34 insertions, 3 deletions
diff --git a/soft-fp/soft-fp.h b/soft-fp/soft-fp.h
index 18779f88d8..dbf080e7f4 100644
--- a/soft-fp/soft-fp.h
+++ b/soft-fp/soft-fp.h
@@ -1,5 +1,6 @@
/* Software floating-point emulation.
- Copyright (C) 1997,1998,1999,2000,2002,2003 Free Software Foundation, Inc.
+ Copyright (C) 1997,1998,1999,2000,2002,2003,2005,2006
+ Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Richard Henderson (rth@cygnus.com),
Jakub Jelinek (jj@ultra.linux.cz),
@@ -11,6 +12,15 @@
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
+ In addition to the permissions in the GNU Lesser General Public
+ License, the Free Software Foundation gives you unlimited
+ permission to link the compiled version of this file into
+ combinations with other programs, and to distribute those
+ combinations without any restriction coming from the use of this
+ file. (The Lesser General Public License restrictions do apply in
+ other respects; for example, they cover modification of the file,
+ and distribution when not linked into a combine executable.)
+
The GNU C Library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
@@ -18,17 +28,25 @@
You should have received a copy of the GNU Lesser General Public
License along with the GNU C Library; if not, write to the Free
- Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
- 02111-1307 USA. */
+ Software Foundation, 51 Franklin Street, Fifth Floor, Boston,
+ MA 02110-1301, USA. */
#ifndef SOFT_FP_H
#define SOFT_FP_H
+#ifdef _LIBC
+#include <sfp-machine.h>
+#else
#include "sfp-machine.h"
+#endif
/* Allow sfp-machine to have its own byte order definitions. */
#ifndef __BYTE_ORDER
+#ifdef _LIBC
#include <endian.h>
+#else
+#error "endianness not defined by sfp-machine.h"
+#endif
#endif
#define _FP_WORKBITS 3
@@ -171,8 +189,21 @@ typedef unsigned int UHWtype __attribute__((mode(HI)));
typedef USItype UHWtype;
#endif
+#define SI_BITS (__CHAR_BIT__ * (int)sizeof(SItype))
+#define DI_BITS (__CHAR_BIT__ * (int)sizeof(DItype))
+
#ifndef umul_ppmm
+#ifdef _LIBC
#include <stdlib/longlong.h>
+#else
+#include "longlong.h"
+#endif
+#endif
+
+#ifdef _LIBC
+#include <stdlib.h>
+#else
+extern void abort (void);
#endif
#endif