[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[patches] DFP branch: Add __dpd_ prefix to soft-dfp files
- To: patches@xxxxxxxxxx, Peter Eberlein <eberlein@xxxxxxxxxx>, Ryan Arnold <ryanarn@xxxxxxxxxx>, Janis Johnson <janis@xxxxxxxxxx>
- Subject: [patches] DFP branch: Add __dpd_ prefix to soft-dfp files
- From: Andreas Krebbel <krebbel@xxxxxxxxxxxxxxxxxx>
- Date: Thu, 28 Aug 2008 17:34:36 +0200
Hello,
I've modified Peters makecfiles.sh script in order to prefix the base
math functions with __dpd_ and the filenames with dpd-. I've regenerated
all the files and modified Versions and Makefile.
There also seemed to be a superfluos file extendtfdd which I've removed.
The conversion is done by the already existing trunctfdd.
I've tested the patch on s390x with the S/390 DFP support patch ontop.
Please apply if you think it is ok.
Bye,
-Andreas-
Index: dfp/sysdeps/soft-dfp/adddd3.c
===================================================================
--- dfp/sysdeps/soft-dfp/adddd3.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal64 addition for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 64
-#define ACTUAL_FUNCTION_NAME __adddd3
-#include <decimal64.h>
-
-#include "addsd3.c"
Index: dfp/sysdeps/soft-dfp/addsd3.c
===================================================================
--- dfp/sysdeps/soft-dfp/addsd3.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,68 +0,0 @@
-/* _Decimal32 addition for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#ifndef _DECIMAL_SIZE
-# include <decimal32.h>
-# define _DECIMAL_SIZE 32
-# define ACTUAL_FUNCTION_NAME __addsd3
-#endif
-
-#include <decContext.h>
-#include <decNumber.h>
-#include <math.h>
-
-#define FUNCTION_NAME add
-
-#include <dfpmacro.h>
-DEC_TYPE
-ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
-{
- DEC_TYPE result;
- decNumber dn_x, dn_y, dn_result;
- decContext context;
- ___decContextDefault(&context, DEFAULT_CONTEXT);
-
- FUNC_CONVERT_TO_DN(&x, &dn_x);
- FUNC_CONVERT_TO_DN(&y, &dn_y);
-
- ___decNumberAdd(&dn_result, &dn_x, &dn_y, &context);
-
- if (context.status != 0)
- {
- int ieee_flags = 0;
- if (context.status & DEC_IEEE_854_Division_by_zero)
- ieee_flags |= FE_DIVBYZERO;
- if (context.status & DEC_IEEE_854_Inexact)
- ieee_flags |= FE_INEXACT;
- if (context.status & DEC_IEEE_854_Invalid_operation)
- ieee_flags |= FE_INVALID;
- if (context.status & DEC_IEEE_854_Overflow)
- ieee_flags |= FE_OVERFLOW;
- if (context.status & DEC_IEEE_854_Underflow)
- ieee_flags |= FE_UNDERFLOW;
- if (ieee_flags != 0)
- feraiseexcept (ieee_flags);
- }
-
- FUNC_CONVERT_FROM_DN (&dn_result, &result, &context);
- return result;
-}
Index: dfp/sysdeps/soft-dfp/addtd3.c
===================================================================
--- dfp/sysdeps/soft-dfp/addtd3.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal128 addition for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 128
-#define ACTUAL_FUNCTION_NAME __addtd3
-#include <decimal128.h>
-
-#include "addsd3.c"
Index: dfp/sysdeps/soft-dfp/divdd3.c
===================================================================
--- dfp/sysdeps/soft-dfp/divdd3.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal64 division for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 64
-#define ACTUAL_FUNCTION_NAME __divdd3
-#include <decimal64.h>
-
-#include "divsd3.c"
Index: dfp/sysdeps/soft-dfp/divsd3.c
===================================================================
--- dfp/sysdeps/soft-dfp/divsd3.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,68 +0,0 @@
-/* _Decimal32 division for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#ifndef _DECIMAL_SIZE
-# include <decimal32.h>
-# define _DECIMAL_SIZE 32
-# define ACTUAL_FUNCTION_NAME __divsd3
-#endif
-
-#include <decContext.h>
-#include <decNumber.h>
-#include <math.h>
-
-#define FUNCTION_NAME div
-
-#include <dfpmacro.h>
-DEC_TYPE
-ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
-{
- DEC_TYPE result;
- decNumber dn_x, dn_y, dn_result;
- decContext context;
- ___decContextDefault(&context, DEFAULT_CONTEXT);
-
- FUNC_CONVERT_TO_DN(&x, &dn_x);
- FUNC_CONVERT_TO_DN(&y, &dn_y);
-
- ___decNumberDivide(&dn_result, &dn_x, &dn_y, &context);
-
- if (context.status != 0)
- {
- int ieee_flags = 0;
- if (context.status & DEC_IEEE_854_Division_by_zero)
- ieee_flags |= FE_DIVBYZERO;
- if (context.status & DEC_IEEE_854_Inexact)
- ieee_flags |= FE_INEXACT;
- if (context.status & DEC_IEEE_854_Invalid_operation)
- ieee_flags |= FE_INVALID;
- if (context.status & DEC_IEEE_854_Overflow)
- ieee_flags |= FE_OVERFLOW;
- if (context.status & DEC_IEEE_854_Underflow)
- ieee_flags |= FE_UNDERFLOW;
- if (ieee_flags != 0)
- feraiseexcept (ieee_flags);
- }
-
- FUNC_CONVERT_FROM_DN (&dn_result, &result, &context);
- return result;
-}
Index: dfp/sysdeps/soft-dfp/divtd3.c
===================================================================
--- dfp/sysdeps/soft-dfp/divtd3.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal128 division for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 128
-#define ACTUAL_FUNCTION_NAME __divtd3
-#include <decimal128.h>
-
-#include "divsd3.c"
Index: dfp/sysdeps/soft-dfp/dpd-adddd3.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-adddd3.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal64 addition for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 64
+#define ACTUAL_FUNCTION_NAME __dpd_adddd3
+#include <decimal64.h>
+
+#include "dpd-addsd3.c"
Index: dfp/sysdeps/soft-dfp/dpd-addsd3.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-addsd3.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,68 @@
+/* _Decimal32 addition for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#ifndef _DECIMAL_SIZE
+# include <decimal32.h>
+# define _DECIMAL_SIZE 32
+# define ACTUAL_FUNCTION_NAME __dpd_addsd3
+#endif
+
+#include <decContext.h>
+#include <decNumber.h>
+#include <math.h>
+
+#define FUNCTION_NAME add
+
+#include <dfpmacro.h>
+DEC_TYPE
+ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
+{
+ DEC_TYPE result;
+ decNumber dn_x, dn_y, dn_result;
+ decContext context;
+ ___decContextDefault(&context, DEFAULT_CONTEXT);
+
+ FUNC_CONVERT_TO_DN(&x, &dn_x);
+ FUNC_CONVERT_TO_DN(&y, &dn_y);
+
+ ___decNumberAdd(&dn_result, &dn_x, &dn_y, &context);
+
+ if (context.status != 0)
+ {
+ int ieee_flags = 0;
+ if (context.status & DEC_IEEE_854_Division_by_zero)
+ ieee_flags |= FE_DIVBYZERO;
+ if (context.status & DEC_IEEE_854_Inexact)
+ ieee_flags |= FE_INEXACT;
+ if (context.status & DEC_IEEE_854_Invalid_operation)
+ ieee_flags |= FE_INVALID;
+ if (context.status & DEC_IEEE_854_Overflow)
+ ieee_flags |= FE_OVERFLOW;
+ if (context.status & DEC_IEEE_854_Underflow)
+ ieee_flags |= FE_UNDERFLOW;
+ if (ieee_flags != 0)
+ feraiseexcept (ieee_flags);
+ }
+
+ FUNC_CONVERT_FROM_DN (&dn_result, &result, &context);
+ return result;
+}
Index: dfp/sysdeps/soft-dfp/dpd-addtd3.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-addtd3.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal128 addition for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 128
+#define ACTUAL_FUNCTION_NAME __dpd_addtd3
+#include <decimal128.h>
+
+#include "dpd-addsd3.c"
Index: dfp/sysdeps/soft-dfp/dpd-divdd3.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-divdd3.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal64 division for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 64
+#define ACTUAL_FUNCTION_NAME __dpd_divdd3
+#include <decimal64.h>
+
+#include "dpd-divsd3.c"
Index: dfp/sysdeps/soft-dfp/dpd-divsd3.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-divsd3.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,68 @@
+/* _Decimal32 division for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#ifndef _DECIMAL_SIZE
+# include <decimal32.h>
+# define _DECIMAL_SIZE 32
+# define ACTUAL_FUNCTION_NAME __dpd_divsd3
+#endif
+
+#include <decContext.h>
+#include <decNumber.h>
+#include <math.h>
+
+#define FUNCTION_NAME div
+
+#include <dfpmacro.h>
+DEC_TYPE
+ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
+{
+ DEC_TYPE result;
+ decNumber dn_x, dn_y, dn_result;
+ decContext context;
+ ___decContextDefault(&context, DEFAULT_CONTEXT);
+
+ FUNC_CONVERT_TO_DN(&x, &dn_x);
+ FUNC_CONVERT_TO_DN(&y, &dn_y);
+
+ ___decNumberDivide(&dn_result, &dn_x, &dn_y, &context);
+
+ if (context.status != 0)
+ {
+ int ieee_flags = 0;
+ if (context.status & DEC_IEEE_854_Division_by_zero)
+ ieee_flags |= FE_DIVBYZERO;
+ if (context.status & DEC_IEEE_854_Inexact)
+ ieee_flags |= FE_INEXACT;
+ if (context.status & DEC_IEEE_854_Invalid_operation)
+ ieee_flags |= FE_INVALID;
+ if (context.status & DEC_IEEE_854_Overflow)
+ ieee_flags |= FE_OVERFLOW;
+ if (context.status & DEC_IEEE_854_Underflow)
+ ieee_flags |= FE_UNDERFLOW;
+ if (ieee_flags != 0)
+ feraiseexcept (ieee_flags);
+ }
+
+ FUNC_CONVERT_FROM_DN (&dn_result, &result, &context);
+ return result;
+}
Index: dfp/sysdeps/soft-dfp/dpd-divtd3.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-divtd3.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal128 division for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 128
+#define ACTUAL_FUNCTION_NAME __dpd_divtd3
+#include <decimal128.h>
+
+#include "dpd-divsd3.c"
Index: dfp/sysdeps/soft-dfp/dpd-eqdd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-eqdd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal64 compare equality for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 64
+#define ACTUAL_FUNCTION_NAME __dpd_eqdd2
+#include <decimal64.h>
+
+#include "dpd-eqsd2.c"
Index: dfp/sysdeps/soft-dfp/dpd-eqsd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-eqsd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,51 @@
+/* _Decimal32 compare equality for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#ifndef _DECIMAL_SIZE
+# include <decimal32.h>
+# define _DECIMAL_SIZE 32
+# define ACTUAL_FUNCTION_NAME __dpd_eqsd2
+#endif
+
+#include <decContext.h>
+#include <decNumber.h>
+#include <math.h>
+
+#define FUNCTION_NAME eq
+
+#include <dfpmacro.h>
+int
+ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
+{
+ decNumber dn_x, dn_y, result;
+ decContext context;
+ ___decContextDefault(&context, DEFAULT_CONTEXT);
+
+ FUNC_CONVERT_TO_DN(&x, &dn_x);
+ FUNC_CONVERT_TO_DN(&y, &dn_y);
+
+ if(___decNumberIsNaN(&dn_x) || ___decNumberIsNaN(&dn_y))
+ return 1;
+
+ ___decNumberCompare(&result, &dn_x, &dn_y, &context);
+ return !___decNumberIsZero(&result);
+}
Index: dfp/sysdeps/soft-dfp/dpd-eqtd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-eqtd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal128 compare equality for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 128
+#define ACTUAL_FUNCTION_NAME __dpd_eqtd2
+#include <decimal128.h>
+
+#include "dpd-eqsd2.c"
Index: dfp/sysdeps/soft-dfp/dpd-extendddtd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-extendddtd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal64 to Decimal128
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_DECIMAL
+#define SRC 64
+#define DEST 128
+#define NAME extend
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-extendddtf.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-extendddtf.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal64 to binary long double (128)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_BINARY
+#define SRC 64
+#define DEST 128
+#define NAME extend
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-extenddfdd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-extenddfdd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary double (64) to Decimal64
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define BINARY_TO_DECIMAL
+#define SRC 64
+#define DEST 64
+#define NAME extend
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-extenddftd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-extenddftd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary double (64) to Decimal128
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define BINARY_TO_DECIMAL
+#define SRC 64
+#define DEST 128
+#define NAME extend
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-extendsddd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-extendsddd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal32 to Decimal64
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_DECIMAL
+#define SRC 32
+#define DEST 64
+#define NAME extend
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-extendsddf.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-extendsddf.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal32 to binary double (64)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_BINARY
+#define SRC 32
+#define DEST 64
+#define NAME extend
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-extendsdtd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-extendsdtd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal32 to Decimal128
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_DECIMAL
+#define SRC 32
+#define DEST 128
+#define NAME extend
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-extendsdtf.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-extendsdtf.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal32 to binary long double (128)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_BINARY
+#define SRC 32
+#define DEST 128
+#define NAME extend
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-extendsfdd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-extendsfdd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary float (32) to Decimal64
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define BINARY_TO_DECIMAL
+#define SRC 32
+#define DEST 64
+#define NAME extend
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-extendsfsd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-extendsfsd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary float (32) to Decimal32
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define BINARY_TO_DECIMAL
+#define SRC 32
+#define DEST 32
+#define NAME extend
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-extendsftd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-extendsftd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary float (32) to Decimal128
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define BINARY_TO_DECIMAL
+#define SRC 32
+#define DEST 128
+#define NAME extend
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-extendtftd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-extendtftd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary long double (dual 64bit) to Decimal128
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define BINARY_TO_DECIMAL
+#define SRC 128
+#define DEST 128
+#define NAME extend
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-fixdddi.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-fixdddi.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal64 to binary long (64)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_INTEGER
+#define SRC 64
+#define DEST 64
+#define NAME fix
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-fixddsi.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-fixddsi.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal64 to binary integer (32)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_INTEGER
+#define SRC 64
+#define DEST 32
+#define NAME fix
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-fixsddi.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-fixsddi.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal32 to binary long (64)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_INTEGER
+#define SRC 32
+#define DEST 64
+#define NAME fix
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-fixsdsi.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-fixsdsi.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal32 to binary integer (32)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_INTEGER
+#define SRC 32
+#define DEST 32
+#define NAME fix
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-fixtddi.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-fixtddi.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal64 to binary long (64)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_INTEGER
+#define SRC 128
+#define DEST 64
+#define NAME fix
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-fixtdsi.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-fixtdsi.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal64 to binary integer (32)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_INTEGER
+#define SRC 128
+#define DEST 32
+#define NAME fix
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-fixunsdddi.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-fixunsdddi.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,29 @@
+/* Handle conversion from Decimal64 to binary unsigned long (64)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_INTEGER
+#define SRC 64
+#define DEST 64
+#define NAME fixuns
+#define UNSIGNED
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-fixunsddsi.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-fixunsddsi.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,29 @@
+/* Handle conversion from Decimal64 to binary unsigned integer (32)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_INTEGER
+#define SRC 64
+#define DEST 32
+#define NAME fixuns
+#define UNSIGNED
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-fixunssddi.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-fixunssddi.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,29 @@
+/* Handle conversion from Decimal32 to binary unsigned long (64)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_INTEGER
+#define SRC 32
+#define DEST 64
+#define NAME fixuns
+#define UNSIGNED
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-fixunssdsi.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-fixunssdsi.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,29 @@
+/* Handle conversion from Decimal32 to binary unsigned integer (32)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_INTEGER
+#define SRC 32
+#define DEST 32
+#define NAME fixuns
+#define UNSIGNED
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-fixunstddi.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-fixunstddi.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,29 @@
+/* Handle conversion from Decimal64 to binary unsigned long (64)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_INTEGER
+#define SRC 128
+#define DEST 64
+#define NAME fixuns
+#define UNSIGNED
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-fixunstdsi.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-fixunstdsi.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,29 @@
+/* Handle conversion from Decimal64 to binary unsigned integer (32)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_INTEGER
+#define SRC 128
+#define DEST 32
+#define NAME fixuns
+#define UNSIGNED
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-floatdidd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-floatdidd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary long (64) to Decimal64
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define INTEGER_TO_DECIMAL
+#define SRC 64
+#define DEST 64
+#define NAME float
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-floatdisd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-floatdisd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary long (64) to Decimal32
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define INTEGER_TO_DECIMAL
+#define SRC 64
+#define DEST 32
+#define NAME float
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-floatditd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-floatditd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary long (64) to Decimal128
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define INTEGER_TO_DECIMAL
+#define SRC 64
+#define DEST 128
+#define NAME float
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-floatsidd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-floatsidd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary integer (32) to Decimal64
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define INTEGER_TO_DECIMAL
+#define SRC 32
+#define DEST 64
+#define NAME float
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-floatsisd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-floatsisd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary integer (32) to Decimal32
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define INTEGER_TO_DECIMAL
+#define SRC 32
+#define DEST 32
+#define NAME float
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-floatsitd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-floatsitd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary integer (32) to Decimal128
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define INTEGER_TO_DECIMAL
+#define SRC 32
+#define DEST 128
+#define NAME float
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-floatunsdidd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-floatunsdidd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,29 @@
+/* Handle conversion from binary unsigned long (64) to Decimal64
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define INTEGER_TO_DECIMAL
+#define SRC 64
+#define DEST 64
+#define NAME floatuns
+#define UNSIGNED
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-floatunsdisd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-floatunsdisd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,29 @@
+/* Handle conversion from binary unsigned long (64) to Decimal32
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define INTEGER_TO_DECIMAL
+#define SRC 64
+#define DEST 32
+#define NAME floatuns
+#define UNSIGNED
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-floatunsditd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-floatunsditd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,29 @@
+/* Handle conversion from binary unsigned long (64) to Decimal128
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define INTEGER_TO_DECIMAL
+#define SRC 64
+#define DEST 128
+#define NAME floatuns
+#define UNSIGNED
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-floatunssidd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-floatunssidd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,29 @@
+/* Handle conversion from binary unsigned integer (32) to Decimal64
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define INTEGER_TO_DECIMAL
+#define SRC 32
+#define DEST 64
+#define NAME floatuns
+#define UNSIGNED
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-floatunssisd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-floatunssisd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,29 @@
+/* Handle conversion from binary unsigned integer (32) to Decimal32
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define INTEGER_TO_DECIMAL
+#define SRC 32
+#define DEST 32
+#define NAME floatuns
+#define UNSIGNED
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-floatunssitd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-floatunssitd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,29 @@
+/* Handle conversion from binary unsigned integer (32) to Decimal128
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define INTEGER_TO_DECIMAL
+#define SRC 32
+#define DEST 128
+#define NAME floatuns
+#define UNSIGNED
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-gedd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-gedd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal64 compare greather-than or equal for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 64
+#define ACTUAL_FUNCTION_NAME __dpd_gedd2
+#include <decimal64.h>
+
+#include "dpd-gesd2.c"
Index: dfp/sysdeps/soft-dfp/dpd-gesd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-gesd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,51 @@
+/* _Decimal32 compare greather-than or equal for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#ifndef _DECIMAL_SIZE
+# include <decimal32.h>
+# define _DECIMAL_SIZE 32
+# define ACTUAL_FUNCTION_NAME __dpd_gesd2
+#endif
+
+#include <decContext.h>
+#include <decNumber.h>
+#include <math.h>
+
+#define FUNCTION_NAME ge
+
+#include <dfpmacro.h>
+int
+ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
+{
+ decNumber dn_x, dn_y, result;
+ decContext context;
+ ___decContextDefault(&context, DEFAULT_CONTEXT);
+
+ FUNC_CONVERT_TO_DN(&x, &dn_x);
+ FUNC_CONVERT_TO_DN(&y, &dn_y);
+
+ if(___decNumberIsNaN(&dn_x) || ___decNumberIsNaN(&dn_y))
+ return -1;
+
+ ___decNumberCompare(&result, &dn_x, &dn_y, &context);
+ return -___decNumberIsNegative(&result);
+}
Index: dfp/sysdeps/soft-dfp/dpd-getd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-getd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal128 compare greather-than or equal for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 128
+#define ACTUAL_FUNCTION_NAME __dpd_getd2
+#include <decimal128.h>
+
+#include "dpd-gesd2.c"
Index: dfp/sysdeps/soft-dfp/dpd-gtdd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-gtdd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal64 compare greater-than for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 64
+#define ACTUAL_FUNCTION_NAME __dpd_gtdd2
+#include <decimal64.h>
+
+#include "dpd-gtsd2.c"
Index: dfp/sysdeps/soft-dfp/dpd-gtsd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-gtsd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,51 @@
+/* _Decimal32 compare greater-than for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#ifndef _DECIMAL_SIZE
+# include <decimal32.h>
+# define _DECIMAL_SIZE 32
+# define ACTUAL_FUNCTION_NAME __dpd_gtsd2
+#endif
+
+#include <decContext.h>
+#include <decNumber.h>
+#include <math.h>
+
+#define FUNCTION_NAME gt
+
+#include <dfpmacro.h>
+int
+ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
+{
+ decNumber dn_x, dn_y, result;
+ decContext context;
+ ___decContextDefault(&context, DEFAULT_CONTEXT);
+
+ FUNC_CONVERT_TO_DN(&x, &dn_x);
+ FUNC_CONVERT_TO_DN(&y, &dn_y);
+
+ if(___decNumberIsNaN(&dn_x) || ___decNumberIsNaN(&dn_y))
+ return -1;
+
+ ___decNumberCompare(&result, &dn_x, &dn_y, &context);
+ return !___decNumberIsNegative(&result) && !___decNumberIsZero(&result);
+}
Index: dfp/sysdeps/soft-dfp/dpd-gttd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-gttd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal128 compare greater-than for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 128
+#define ACTUAL_FUNCTION_NAME __dpd_gttd2
+#include <decimal128.h>
+
+#include "dpd-gtsd2.c"
Index: dfp/sysdeps/soft-dfp/dpd-ledd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-ledd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal64 compare less-than or equal for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 64
+#define ACTUAL_FUNCTION_NAME __dpd_ledd2
+#include <decimal64.h>
+
+#include "dpd-lesd2.c"
Index: dfp/sysdeps/soft-dfp/dpd-lesd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-lesd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,51 @@
+/* _Decimal32 compare less-than or equal for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#ifndef _DECIMAL_SIZE
+# include <decimal32.h>
+# define _DECIMAL_SIZE 32
+# define ACTUAL_FUNCTION_NAME __dpd_lesd2
+#endif
+
+#include <decContext.h>
+#include <decNumber.h>
+#include <math.h>
+
+#define FUNCTION_NAME le
+
+#include <dfpmacro.h>
+int
+ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
+{
+ decNumber dn_x, dn_y, result;
+ decContext context;
+ ___decContextDefault(&context, DEFAULT_CONTEXT);
+
+ FUNC_CONVERT_TO_DN(&x, &dn_x);
+ FUNC_CONVERT_TO_DN(&y, &dn_y);
+
+ if(___decNumberIsNaN(&dn_x) || ___decNumberIsNaN(&dn_y))
+ return 1;
+
+ ___decNumberCompare(&result, &dn_x, &dn_y, &context);
+ return !___decNumberIsNegative(&result) && !___decNumberIsZero(&result);
+}
Index: dfp/sysdeps/soft-dfp/dpd-letd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-letd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal128 compare less-than or equal for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 128
+#define ACTUAL_FUNCTION_NAME __dpd_letd2
+#include <decimal128.h>
+
+#include "dpd-lesd2.c"
Index: dfp/sysdeps/soft-dfp/dpd-ltdd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-ltdd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal64 compare less-than for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 64
+#define ACTUAL_FUNCTION_NAME __dpd_ltdd2
+#include <decimal64.h>
+
+#include "dpd-ltsd2.c"
Index: dfp/sysdeps/soft-dfp/dpd-ltsd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-ltsd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,51 @@
+/* _Decimal32 compare less-than for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#ifndef _DECIMAL_SIZE
+# include <decimal32.h>
+# define _DECIMAL_SIZE 32
+# define ACTUAL_FUNCTION_NAME __dpd_ltsd2
+#endif
+
+#include <decContext.h>
+#include <decNumber.h>
+#include <math.h>
+
+#define FUNCTION_NAME lt
+
+#include <dfpmacro.h>
+int
+ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
+{
+ decNumber dn_x, dn_y, result;
+ decContext context;
+ ___decContextDefault(&context, DEFAULT_CONTEXT);
+
+ FUNC_CONVERT_TO_DN(&x, &dn_x);
+ FUNC_CONVERT_TO_DN(&y, &dn_y);
+
+ if(___decNumberIsNaN(&dn_x) || ___decNumberIsNaN(&dn_y))
+ return 1;
+
+ ___decNumberCompare(&result, &dn_x, &dn_y, &context);
+ return -___decNumberIsNegative(&result);
+}
Index: dfp/sysdeps/soft-dfp/dpd-lttd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-lttd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal128 compare less-than for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 128
+#define ACTUAL_FUNCTION_NAME __dpd_lttd2
+#include <decimal128.h>
+
+#include "dpd-ltsd2.c"
Index: dfp/sysdeps/soft-dfp/dpd-muldd3.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-muldd3.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal64 multiplication for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 64
+#define ACTUAL_FUNCTION_NAME __dpd_muldd3
+#include <decimal64.h>
+
+#include "dpd-mulsd3.c"
Index: dfp/sysdeps/soft-dfp/dpd-mulsd3.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-mulsd3.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,68 @@
+/* _Decimal32 multiplication for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#ifndef _DECIMAL_SIZE
+# include <decimal32.h>
+# define _DECIMAL_SIZE 32
+# define ACTUAL_FUNCTION_NAME __dpd_mulsd3
+#endif
+
+#include <decContext.h>
+#include <decNumber.h>
+#include <math.h>
+
+#define FUNCTION_NAME mul
+
+#include <dfpmacro.h>
+DEC_TYPE
+ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
+{
+ DEC_TYPE result;
+ decNumber dn_x, dn_y, dn_result;
+ decContext context;
+ ___decContextDefault(&context, DEFAULT_CONTEXT);
+
+ FUNC_CONVERT_TO_DN(&x, &dn_x);
+ FUNC_CONVERT_TO_DN(&y, &dn_y);
+
+ ___decNumberMultiply(&dn_result, &dn_x, &dn_y, &context);
+
+ if (context.status != 0)
+ {
+ int ieee_flags = 0;
+ if (context.status & DEC_IEEE_854_Division_by_zero)
+ ieee_flags |= FE_DIVBYZERO;
+ if (context.status & DEC_IEEE_854_Inexact)
+ ieee_flags |= FE_INEXACT;
+ if (context.status & DEC_IEEE_854_Invalid_operation)
+ ieee_flags |= FE_INVALID;
+ if (context.status & DEC_IEEE_854_Overflow)
+ ieee_flags |= FE_OVERFLOW;
+ if (context.status & DEC_IEEE_854_Underflow)
+ ieee_flags |= FE_UNDERFLOW;
+ if (ieee_flags != 0)
+ feraiseexcept (ieee_flags);
+ }
+
+ FUNC_CONVERT_FROM_DN (&dn_result, &result, &context);
+ return result;
+}
Index: dfp/sysdeps/soft-dfp/dpd-multd3.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-multd3.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal128 multiplication for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 128
+#define ACTUAL_FUNCTION_NAME __dpd_multd3
+#include <decimal128.h>
+
+#include "dpd-mulsd3.c"
Index: dfp/sysdeps/soft-dfp/dpd-nedd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-nedd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal64 compare inequality for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 64
+#define ACTUAL_FUNCTION_NAME __dpd_nedd2
+#include <decimal64.h>
+
+#include "dpd-nesd2.c"
Index: dfp/sysdeps/soft-dfp/dpd-nesd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-nesd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,51 @@
+/* _Decimal32 compare inequality for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#ifndef _DECIMAL_SIZE
+# include <decimal32.h>
+# define _DECIMAL_SIZE 32
+# define ACTUAL_FUNCTION_NAME __dpd_nesd2
+#endif
+
+#include <decContext.h>
+#include <decNumber.h>
+#include <math.h>
+
+#define FUNCTION_NAME ne
+
+#include <dfpmacro.h>
+int
+ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
+{
+ decNumber dn_x, dn_y, result;
+ decContext context;
+ ___decContextDefault(&context, DEFAULT_CONTEXT);
+
+ FUNC_CONVERT_TO_DN(&x, &dn_x);
+ FUNC_CONVERT_TO_DN(&y, &dn_y);
+
+ if(___decNumberIsNaN(&dn_x) || ___decNumberIsNaN(&dn_y))
+ return 1;
+
+ ___decNumberCompare(&result, &dn_x, &dn_y, &context);
+ return !___decNumberIsZero(&result);
+}
Index: dfp/sysdeps/soft-dfp/dpd-netd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-netd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal128 compare inequality for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 128
+#define ACTUAL_FUNCTION_NAME __dpd_netd2
+#include <decimal128.h>
+
+#include "dpd-nesd2.c"
Index: dfp/sysdeps/soft-dfp/dpd-subdd3.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-subdd3.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal64 subtraction for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 64
+#define ACTUAL_FUNCTION_NAME __dpd_subdd3
+#include <decimal64.h>
+
+#include "dpd-subsd3.c"
Index: dfp/sysdeps/soft-dfp/dpd-subsd3.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-subsd3.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,68 @@
+/* _Decimal32 subtraction for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#ifndef _DECIMAL_SIZE
+# include <decimal32.h>
+# define _DECIMAL_SIZE 32
+# define ACTUAL_FUNCTION_NAME __dpd_subsd3
+#endif
+
+#include <decContext.h>
+#include <decNumber.h>
+#include <math.h>
+
+#define FUNCTION_NAME sub
+
+#include <dfpmacro.h>
+DEC_TYPE
+ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
+{
+ DEC_TYPE result;
+ decNumber dn_x, dn_y, dn_result;
+ decContext context;
+ ___decContextDefault(&context, DEFAULT_CONTEXT);
+
+ FUNC_CONVERT_TO_DN(&x, &dn_x);
+ FUNC_CONVERT_TO_DN(&y, &dn_y);
+
+ ___decNumberSubtract(&dn_result, &dn_x, &dn_y, &context);
+
+ if (context.status != 0)
+ {
+ int ieee_flags = 0;
+ if (context.status & DEC_IEEE_854_Division_by_zero)
+ ieee_flags |= FE_DIVBYZERO;
+ if (context.status & DEC_IEEE_854_Inexact)
+ ieee_flags |= FE_INEXACT;
+ if (context.status & DEC_IEEE_854_Invalid_operation)
+ ieee_flags |= FE_INVALID;
+ if (context.status & DEC_IEEE_854_Overflow)
+ ieee_flags |= FE_OVERFLOW;
+ if (context.status & DEC_IEEE_854_Underflow)
+ ieee_flags |= FE_UNDERFLOW;
+ if (ieee_flags != 0)
+ feraiseexcept (ieee_flags);
+ }
+
+ FUNC_CONVERT_FROM_DN (&dn_result, &result, &context);
+ return result;
+}
Index: dfp/sysdeps/soft-dfp/dpd-subtd3.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-subtd3.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal128 subtraction for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 128
+#define ACTUAL_FUNCTION_NAME __dpd_subtd3
+#include <decimal128.h>
+
+#include "dpd-subsd3.c"
Index: dfp/sysdeps/soft-dfp/dpd-truncdddf.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-truncdddf.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal64 to binary double (64)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_BINARY
+#define SRC 64
+#define DEST 64
+#define NAME trunc
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-truncddsd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-truncddsd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal64 to Decimal32
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_DECIMAL
+#define SRC 64
+#define DEST 32
+#define NAME trunc
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-truncddsf.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-truncddsf.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal64 to binary float (32)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_BINARY
+#define SRC 64
+#define DEST 32
+#define NAME trunc
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-truncdfsd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-truncdfsd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary double (64) to Decimal32
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define BINARY_TO_DECIMAL
+#define SRC 64
+#define DEST 32
+#define NAME trunc
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-truncsdsf.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-truncsdsf.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal32 to binary float (32)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_BINARY
+#define SRC 32
+#define DEST 32
+#define NAME trunc
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-trunctddd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-trunctddd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal128 to Decimal64
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_DECIMAL
+#define SRC 128
+#define DEST 64
+#define NAME trunc
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-trunctddf.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-trunctddf.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal128 to binary double (64)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_BINARY
+#define SRC 128
+#define DEST 64
+#define NAME trunc
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-trunctdsd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-trunctdsd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal128 to Decimal32
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_DECIMAL
+#define SRC 128
+#define DEST 32
+#define NAME trunc
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-trunctdsf.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-trunctdsf.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal128 to binary float (32)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_BINARY
+#define SRC 128
+#define DEST 32
+#define NAME trunc
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-trunctdtf.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-trunctdtf.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from Decimal128 to binary long double (dual 64bit)
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define DECIMAL_TO_BINARY
+#define SRC 128
+#define DEST 128
+#define NAME trunc
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-trunctfdd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-trunctfdd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary long double (128) to Decimal64
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define BINARY_TO_DECIMAL
+#define SRC 128
+#define DEST 64
+#define NAME trunc
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-trunctfsd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-trunctfsd.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,28 @@
+/* Handle conversion from binary long double (128) to Decimal32
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define BINARY_TO_DECIMAL
+#define SRC 128
+#define DEST 32
+#define NAME trunc
+
+#include "convert.c"
Index: dfp/sysdeps/soft-dfp/dpd-unorddd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-unorddd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal64 compare unordered for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 64
+#define ACTUAL_FUNCTION_NAME __dpd_unorddd2
+#include <decimal64.h>
+
+#include "dpd-unordsd2.c"
Index: dfp/sysdeps/soft-dfp/dpd-unordsd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-unordsd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,48 @@
+/* _Decimal32 compare unordered for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#ifndef _DECIMAL_SIZE
+# include <decimal32.h>
+# define _DECIMAL_SIZE 32
+# define ACTUAL_FUNCTION_NAME __dpd_unordsd2
+#endif
+
+#include <decContext.h>
+#include <decNumber.h>
+#include <math.h>
+
+#define FUNCTION_NAME unord
+
+#include <dfpmacro.h>
+int
+ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
+{
+ decNumber dn_x;
+ decNumber dn_y;
+ decContext context;
+ ___decContextDefault(&context, DEFAULT_CONTEXT);
+
+ FUNC_CONVERT_TO_DN(&x, &dn_x);
+ FUNC_CONVERT_TO_DN(&y, &dn_y);
+
+ return (___decNumberIsNaN(&dn_x) || ___decNumberIsNaN(&dn_y));
+}
Index: dfp/sysdeps/soft-dfp/dpd-unordtd2.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ dfp/sysdeps/soft-dfp/dpd-unordtd2.c 2008-08-28 15:23:55.000000000 +0200
@@ -0,0 +1,27 @@
+/* _Decimal128 compare unordered for soft-dfp
+ Copyright (C) 2007, 2008 IBM Corporation.
+
+ Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
+
+ The Decimal Floating Point C Library is free software; you can
+ redistribute it and/or modify it under the terms of the GNU Lesser
+ General Public License version 2.1.
+
+ The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License version 2.1 along with the Decimal Floating Point C Library;
+ if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+ Suite 330, Boston, MA 02111-1307 USA.
+
+ Please see dfp/COPYING.txt for more information. */
+
+
+#define _DECIMAL_SIZE 128
+#define ACTUAL_FUNCTION_NAME __dpd_unordtd2
+#include <decimal128.h>
+
+#include "dpd-unordsd2.c"
Index: dfp/sysdeps/soft-dfp/eqdd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/eqdd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal64 compare equality for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 64
-#define ACTUAL_FUNCTION_NAME __eqdd2
-#include <decimal64.h>
-
-#include "eqsd2.c"
Index: dfp/sysdeps/soft-dfp/eqsd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/eqsd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,51 +0,0 @@
-/* _Decimal32 compare equality for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#ifndef _DECIMAL_SIZE
-# include <decimal32.h>
-# define _DECIMAL_SIZE 32
-# define ACTUAL_FUNCTION_NAME __eqsd2
-#endif
-
-#include <decContext.h>
-#include <decNumber.h>
-#include <math.h>
-
-#define FUNCTION_NAME eq
-
-#include <dfpmacro.h>
-int
-ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
-{
- decNumber dn_x, dn_y, result;
- decContext context;
- ___decContextDefault(&context, DEFAULT_CONTEXT);
-
- FUNC_CONVERT_TO_DN(&x, &dn_x);
- FUNC_CONVERT_TO_DN(&y, &dn_y);
-
- if(___decNumberIsNaN(&dn_x) || ___decNumberIsNaN(&dn_y))
- return 1;
-
- ___decNumberCompare(&result, &dn_x, &dn_y, &context);
- return !___decNumberIsZero(&result);
-}
Index: dfp/sysdeps/soft-dfp/eqtd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/eqtd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal128 compare equality for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 128
-#define ACTUAL_FUNCTION_NAME __eqtd2
-#include <decimal128.h>
-
-#include "eqsd2.c"
Index: dfp/sysdeps/soft-dfp/extendddtd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/extendddtd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal64 to Decimal128
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_DECIMAL
-#define SRC 64
-#define DEST 128
-#define NAME extend
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/extendddtf.c
===================================================================
--- dfp/sysdeps/soft-dfp/extendddtf.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal64 to binary long double (128)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_BINARY
-#define SRC 64
-#define DEST 128
-#define NAME extend
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/extenddfdd.c
===================================================================
--- dfp/sysdeps/soft-dfp/extenddfdd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary double (64) to Decimal64
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define BINARY_TO_DECIMAL
-#define SRC 64
-#define DEST 64
-#define NAME extend
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/extenddftd.c
===================================================================
--- dfp/sysdeps/soft-dfp/extenddftd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary double (64) to Decimal128
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define BINARY_TO_DECIMAL
-#define SRC 64
-#define DEST 128
-#define NAME extend
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/extendsddd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/extendsddd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal32 to Decimal64
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_DECIMAL
-#define SRC 32
-#define DEST 64
-#define NAME extend
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/extendsddf.c
===================================================================
--- dfp/sysdeps/soft-dfp/extendsddf.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal32 to binary double (64)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_BINARY
-#define SRC 32
-#define DEST 64
-#define NAME extend
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/extendsdtd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/extendsdtd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal32 to Decimal128
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_DECIMAL
-#define SRC 32
-#define DEST 128
-#define NAME extend
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/extendsdtf.c
===================================================================
--- dfp/sysdeps/soft-dfp/extendsdtf.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal32 to binary long double (128)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_BINARY
-#define SRC 32
-#define DEST 128
-#define NAME extend
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/extendsfdd.c
===================================================================
--- dfp/sysdeps/soft-dfp/extendsfdd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary float (32) to Decimal64
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define BINARY_TO_DECIMAL
-#define SRC 32
-#define DEST 64
-#define NAME extend
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/extendsfsd.c
===================================================================
--- dfp/sysdeps/soft-dfp/extendsfsd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary float (32) to Decimal32
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define BINARY_TO_DECIMAL
-#define SRC 32
-#define DEST 32
-#define NAME extend
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/extendsftd.c
===================================================================
--- dfp/sysdeps/soft-dfp/extendsftd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary float (32) to Decimal128
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define BINARY_TO_DECIMAL
-#define SRC 32
-#define DEST 128
-#define NAME extend
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/extendtfdd.c
===================================================================
--- dfp/sysdeps/soft-dfp/extendtfdd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,55 +0,0 @@
-/* Handle
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#include <math.h>
-
-extern _Decimal64 __extenddfdd(double);
-
-_Decimal64
-__extendtfdd (long double a)
-{
- _Decimal64 result = 0.0DD;
- _Decimal64 temp;
- union {
- long double ld;
- double d[2];
- }
-
- switch (fpclassify (a)) {
- case FP_ZERO:
- result = signbit(a) ? -0.0DD : 0.0DD;
- break;
- case FP_INFINITY:
- result = a>0.0 ? DEC_INFINITY : -DEC_INFINITY;
- break;
- case FP_NAN:
- result = DEC_NAN;
- break;
- default:
- ldd.ld = a;
- temp = __extenddfdd (ldd.d[0]);
- result = temp;
- temp = __extenddfdd (ldd.d[1]);
- result = result + temp;
- }
- return result;
-}
Index: dfp/sysdeps/soft-dfp/extendtftd.c
===================================================================
--- dfp/sysdeps/soft-dfp/extendtftd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary long double (dual 64bit) to Decimal128
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define BINARY_TO_DECIMAL
-#define SRC 128
-#define DEST 128
-#define NAME extend
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/fixdddi.c
===================================================================
--- dfp/sysdeps/soft-dfp/fixdddi.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal64 to binary long (64)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_INTEGER
-#define SRC 64
-#define DEST 64
-#define NAME fix
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/fixddsi.c
===================================================================
--- dfp/sysdeps/soft-dfp/fixddsi.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal64 to binary integer (32)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_INTEGER
-#define SRC 64
-#define DEST 32
-#define NAME fix
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/fixsddi.c
===================================================================
--- dfp/sysdeps/soft-dfp/fixsddi.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal32 to binary long (64)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_INTEGER
-#define SRC 32
-#define DEST 64
-#define NAME fix
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/fixsdsi.c
===================================================================
--- dfp/sysdeps/soft-dfp/fixsdsi.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal32 to binary integer (32)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_INTEGER
-#define SRC 32
-#define DEST 32
-#define NAME fix
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/fixtddi.c
===================================================================
--- dfp/sysdeps/soft-dfp/fixtddi.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal64 to binary long (64)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_INTEGER
-#define SRC 128
-#define DEST 64
-#define NAME fix
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/fixtdsi.c
===================================================================
--- dfp/sysdeps/soft-dfp/fixtdsi.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal64 to binary integer (32)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_INTEGER
-#define SRC 128
-#define DEST 32
-#define NAME fix
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/fixunsdddi.c
===================================================================
--- dfp/sysdeps/soft-dfp/fixunsdddi.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,29 +0,0 @@
-/* Handle conversion from Decimal64 to binary unsigned long (64)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_INTEGER
-#define SRC 64
-#define DEST 64
-#define NAME fixuns
-#define UNSIGNED
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/fixunsddsi.c
===================================================================
--- dfp/sysdeps/soft-dfp/fixunsddsi.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,29 +0,0 @@
-/* Handle conversion from Decimal64 to binary unsigned integer (32)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_INTEGER
-#define SRC 64
-#define DEST 32
-#define NAME fixuns
-#define UNSIGNED
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/fixunssddi.c
===================================================================
--- dfp/sysdeps/soft-dfp/fixunssddi.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,29 +0,0 @@
-/* Handle conversion from Decimal32 to binary unsigned long (64)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_INTEGER
-#define SRC 32
-#define DEST 64
-#define NAME fixuns
-#define UNSIGNED
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/fixunssdsi.c
===================================================================
--- dfp/sysdeps/soft-dfp/fixunssdsi.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,29 +0,0 @@
-/* Handle conversion from Decimal32 to binary unsigned integer (32)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_INTEGER
-#define SRC 32
-#define DEST 32
-#define NAME fixuns
-#define UNSIGNED
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/fixunstddi.c
===================================================================
--- dfp/sysdeps/soft-dfp/fixunstddi.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,29 +0,0 @@
-/* Handle conversion from Decimal64 to binary unsigned long (64)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_INTEGER
-#define SRC 128
-#define DEST 64
-#define NAME fixuns
-#define UNSIGNED
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/fixunstdsi.c
===================================================================
--- dfp/sysdeps/soft-dfp/fixunstdsi.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,29 +0,0 @@
-/* Handle conversion from Decimal64 to binary unsigned integer (32)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_INTEGER
-#define SRC 128
-#define DEST 32
-#define NAME fixuns
-#define UNSIGNED
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/floatdidd.c
===================================================================
--- dfp/sysdeps/soft-dfp/floatdidd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary long (64) to Decimal64
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define INTEGER_TO_DECIMAL
-#define SRC 64
-#define DEST 64
-#define NAME float
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/floatdisd.c
===================================================================
--- dfp/sysdeps/soft-dfp/floatdisd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary long (64) to Decimal32
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define INTEGER_TO_DECIMAL
-#define SRC 64
-#define DEST 32
-#define NAME float
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/floatditd.c
===================================================================
--- dfp/sysdeps/soft-dfp/floatditd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary long (64) to Decimal128
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define INTEGER_TO_DECIMAL
-#define SRC 64
-#define DEST 128
-#define NAME float
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/floatsidd.c
===================================================================
--- dfp/sysdeps/soft-dfp/floatsidd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary integer (32) to Decimal64
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define INTEGER_TO_DECIMAL
-#define SRC 32
-#define DEST 64
-#define NAME float
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/floatsisd.c
===================================================================
--- dfp/sysdeps/soft-dfp/floatsisd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary integer (32) to Decimal32
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define INTEGER_TO_DECIMAL
-#define SRC 32
-#define DEST 32
-#define NAME float
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/floatsitd.c
===================================================================
--- dfp/sysdeps/soft-dfp/floatsitd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary integer (32) to Decimal128
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define INTEGER_TO_DECIMAL
-#define SRC 32
-#define DEST 128
-#define NAME float
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/floatunsdidd.c
===================================================================
--- dfp/sysdeps/soft-dfp/floatunsdidd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,29 +0,0 @@
-/* Handle conversion from binary unsigned long (64) to Decimal64
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define INTEGER_TO_DECIMAL
-#define SRC 64
-#define DEST 64
-#define NAME floatuns
-#define UNSIGNED
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/floatunsdisd.c
===================================================================
--- dfp/sysdeps/soft-dfp/floatunsdisd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,29 +0,0 @@
-/* Handle conversion from binary unsigned long (64) to Decimal32
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define INTEGER_TO_DECIMAL
-#define SRC 64
-#define DEST 32
-#define NAME floatuns
-#define UNSIGNED
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/floatunsditd.c
===================================================================
--- dfp/sysdeps/soft-dfp/floatunsditd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,29 +0,0 @@
-/* Handle conversion from binary unsigned long (64) to Decimal128
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define INTEGER_TO_DECIMAL
-#define SRC 64
-#define DEST 128
-#define NAME floatuns
-#define UNSIGNED
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/floatunssidd.c
===================================================================
--- dfp/sysdeps/soft-dfp/floatunssidd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,29 +0,0 @@
-/* Handle conversion from binary unsigned integer (32) to Decimal64
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define INTEGER_TO_DECIMAL
-#define SRC 32
-#define DEST 64
-#define NAME floatuns
-#define UNSIGNED
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/floatunssisd.c
===================================================================
--- dfp/sysdeps/soft-dfp/floatunssisd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,29 +0,0 @@
-/* Handle conversion from binary unsigned integer (32) to Decimal32
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define INTEGER_TO_DECIMAL
-#define SRC 32
-#define DEST 32
-#define NAME floatuns
-#define UNSIGNED
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/floatunssitd.c
===================================================================
--- dfp/sysdeps/soft-dfp/floatunssitd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,29 +0,0 @@
-/* Handle conversion from binary unsigned integer (32) to Decimal128
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define INTEGER_TO_DECIMAL
-#define SRC 32
-#define DEST 128
-#define NAME floatuns
-#define UNSIGNED
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/gedd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/gedd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal64 compare greather-than or equal for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 64
-#define ACTUAL_FUNCTION_NAME __gedd2
-#include <decimal64.h>
-
-#include "gesd2.c"
Index: dfp/sysdeps/soft-dfp/gesd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/gesd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,51 +0,0 @@
-/* _Decimal32 compare greather-than or equal for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#ifndef _DECIMAL_SIZE
-# include <decimal32.h>
-# define _DECIMAL_SIZE 32
-# define ACTUAL_FUNCTION_NAME __gesd2
-#endif
-
-#include <decContext.h>
-#include <decNumber.h>
-#include <math.h>
-
-#define FUNCTION_NAME ge
-
-#include <dfpmacro.h>
-int
-ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
-{
- decNumber dn_x, dn_y, result;
- decContext context;
- ___decContextDefault(&context, DEFAULT_CONTEXT);
-
- FUNC_CONVERT_TO_DN(&x, &dn_x);
- FUNC_CONVERT_TO_DN(&y, &dn_y);
-
- if(___decNumberIsNaN(&dn_x) || ___decNumberIsNaN(&dn_y))
- return -1;
-
- ___decNumberCompare(&result, &dn_x, &dn_y, &context);
- return -___decNumberIsNegative(&result);
-}
Index: dfp/sysdeps/soft-dfp/getd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/getd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal128 compare greather-than or equal for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 128
-#define ACTUAL_FUNCTION_NAME __getd2
-#include <decimal128.h>
-
-#include "gesd2.c"
Index: dfp/sysdeps/soft-dfp/gtdd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/gtdd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal64 compare greater-than for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 64
-#define ACTUAL_FUNCTION_NAME __gtdd2
-#include <decimal64.h>
-
-#include "gtsd2.c"
Index: dfp/sysdeps/soft-dfp/gtsd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/gtsd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,51 +0,0 @@
-/* _Decimal32 compare greater-than for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#ifndef _DECIMAL_SIZE
-# include <decimal32.h>
-# define _DECIMAL_SIZE 32
-# define ACTUAL_FUNCTION_NAME __gtsd2
-#endif
-
-#include <decContext.h>
-#include <decNumber.h>
-#include <math.h>
-
-#define FUNCTION_NAME gt
-
-#include <dfpmacro.h>
-int
-ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
-{
- decNumber dn_x, dn_y, result;
- decContext context;
- ___decContextDefault(&context, DEFAULT_CONTEXT);
-
- FUNC_CONVERT_TO_DN(&x, &dn_x);
- FUNC_CONVERT_TO_DN(&y, &dn_y);
-
- if(___decNumberIsNaN(&dn_x) || ___decNumberIsNaN(&dn_y))
- return -1;
-
- ___decNumberCompare(&result, &dn_x, &dn_y, &context);
- return !___decNumberIsNegative(&result) && !___decNumberIsZero(&result);
-}
Index: dfp/sysdeps/soft-dfp/gttd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/gttd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal128 compare greater-than for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 128
-#define ACTUAL_FUNCTION_NAME __gttd2
-#include <decimal128.h>
-
-#include "gtsd2.c"
Index: dfp/sysdeps/soft-dfp/ledd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/ledd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal64 compare less-than or equal for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 64
-#define ACTUAL_FUNCTION_NAME __ledd2
-#include <decimal64.h>
-
-#include "lesd2.c"
Index: dfp/sysdeps/soft-dfp/lesd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/lesd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,51 +0,0 @@
-/* _Decimal32 compare less-than or equal for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#ifndef _DECIMAL_SIZE
-# include <decimal32.h>
-# define _DECIMAL_SIZE 32
-# define ACTUAL_FUNCTION_NAME __lesd2
-#endif
-
-#include <decContext.h>
-#include <decNumber.h>
-#include <math.h>
-
-#define FUNCTION_NAME le
-
-#include <dfpmacro.h>
-int
-ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
-{
- decNumber dn_x, dn_y, result;
- decContext context;
- ___decContextDefault(&context, DEFAULT_CONTEXT);
-
- FUNC_CONVERT_TO_DN(&x, &dn_x);
- FUNC_CONVERT_TO_DN(&y, &dn_y);
-
- if(___decNumberIsNaN(&dn_x) || ___decNumberIsNaN(&dn_y))
- return 1;
-
- ___decNumberCompare(&result, &dn_x, &dn_y, &context);
- return !___decNumberIsNegative(&result) && !___decNumberIsZero(&result);
-}
Index: dfp/sysdeps/soft-dfp/letd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/letd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal128 compare less-than or equal for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 128
-#define ACTUAL_FUNCTION_NAME __letd2
-#include <decimal128.h>
-
-#include "lesd2.c"
Index: dfp/sysdeps/soft-dfp/ltdd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/ltdd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal64 compare less-than for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 64
-#define ACTUAL_FUNCTION_NAME __ltdd2
-#include <decimal64.h>
-
-#include "ltsd2.c"
Index: dfp/sysdeps/soft-dfp/ltsd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/ltsd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,51 +0,0 @@
-/* _Decimal32 compare less-than for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#ifndef _DECIMAL_SIZE
-# include <decimal32.h>
-# define _DECIMAL_SIZE 32
-# define ACTUAL_FUNCTION_NAME __ltsd2
-#endif
-
-#include <decContext.h>
-#include <decNumber.h>
-#include <math.h>
-
-#define FUNCTION_NAME lt
-
-#include <dfpmacro.h>
-int
-ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
-{
- decNumber dn_x, dn_y, result;
- decContext context;
- ___decContextDefault(&context, DEFAULT_CONTEXT);
-
- FUNC_CONVERT_TO_DN(&x, &dn_x);
- FUNC_CONVERT_TO_DN(&y, &dn_y);
-
- if(___decNumberIsNaN(&dn_x) || ___decNumberIsNaN(&dn_y))
- return 1;
-
- ___decNumberCompare(&result, &dn_x, &dn_y, &context);
- return -___decNumberIsNegative(&result);
-}
Index: dfp/sysdeps/soft-dfp/lttd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/lttd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal128 compare less-than for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 128
-#define ACTUAL_FUNCTION_NAME __lttd2
-#include <decimal128.h>
-
-#include "ltsd2.c"
Index: dfp/sysdeps/soft-dfp/makecfiles.sh
===================================================================
--- dfp/sysdeps/soft-dfp/makecfiles.sh.orig 2008-08-28 15:23:11.000000000 +0200
+++ dfp/sysdeps/soft-dfp/makecfiles.sh 2008-08-28 15:23:40.000000000 +0200
@@ -1,10 +1,12 @@
#!/bin/bash
+DPD_FUNC_PREF="__dpd_"
+DPD_FILE_PREF="dpd-"
function header {
cat > ${1} << EOF
/* $2
- Copyright (C) 2007 IBM Corporation.
+ Copyright (C) 2007, 2008 IBM Corporation.
Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
@@ -163,13 +165,13 @@ EOF
## generate name postfix description
function generate {
- name32=${1}sd${2}
- name64=${1}dd${2}
- name128=${1}td${2}
-
- file32=${name32}.c
- file64=${name64}.c
- file128=${name128}.c
+ name32=${DPD_FUNC_PREF}${1}sd${2}
+ name64=${DPD_FUNC_PREF}${1}dd${2}
+ name128=${DPD_FUNC_PREF}${1}td${2}
+
+ file32=${DPD_FILE_PREF}${1}sd${2}.c
+ file64=${DPD_FILE_PREF}${1}dd${2}.c
+ file128=${DPD_FILE_PREF}${1}td${2}.c
desc=$3
header $file32 "_Decimal32 $desc for soft-dfp"
@@ -180,7 +182,7 @@ function generate {
#ifndef _DECIMAL_SIZE
# include <decimal32.h>
# define _DECIMAL_SIZE 32
-# define ACTUAL_FUNCTION_NAME __${name32}
+# define ACTUAL_FUNCTION_NAME ${name32}
#endif
#include <decContext.h>
@@ -210,13 +212,13 @@ esac
echo "#define _DECIMAL_SIZE 64" >> ${file64}
- echo "#define ACTUAL_FUNCTION_NAME __${name64}" >> ${file64}
+ echo "#define ACTUAL_FUNCTION_NAME ${name64}" >> ${file64}
echo "#include <decimal64.h>" >> ${file64}
echo "" >> ${file64}
echo "#include \"${file32}\"" >> ${file64}
echo "#define _DECIMAL_SIZE 128" >> ${file128}
- echo "#define ACTUAL_FUNCTION_NAME __${name128}" >> ${file128}
+ echo "#define ACTUAL_FUNCTION_NAME ${name128}" >> ${file128}
echo "#include <decimal128.h>" >> ${file128}
echo "" >> ${file128}
echo "#include \"${file32}\"" >> ${file128}
@@ -256,12 +258,12 @@ function convert {
di) destwidth=64; action=${action}_TO_INTEGER;;
esac
- name=${op}${from}${to}
+ file=${DPD_FILE_PREF}${op}${from}${to}
if [ $action == DECIMAL_TO_DECIMAL ]
then
- name=${name}2
+ file=${file}2
fi
- file=${name}.c
+ file=${file}.c
echo $file
@@ -348,288 +350,3 @@ convert floatuns si td "Handle conversio
convert floatuns di sd "Handle conversion from binary unsigned long (64) to Decimal32"
convert floatuns di dd "Handle conversion from binary unsigned long (64) to Decimal64"
convert floatuns di td "Handle conversion from binary unsigned long (64) to Decimal128"
-
-
-exit
-
-makefile=Makefile
-versions=Versions
-
-echo "libdfp {" > ${versions}
-echo " GLIBC_2.5 {" >> ${versions}
-
-echo "# Makefile fragment for soft-dfp." > ${makefile}
-echo "" >> ${makefile}
-echo "ifeq (\$(subdir),dfp)" >> ${makefile}
-echo "sysdep-CFLAGS += -DWORDS_BIT_ENDIAN=1 -DLONG_DOUBLE_TYPE_SIZE=128 -DBITS_PER_UNIT=8" >> ${makefile}
-
-echo "libdfp-routines += \\">> ${makefile}
-makeline=" "
-
-
-## arguments: file, description
-function header {
-
-}
-
-## arguments: file, operation, description
-function arith {
-
- case $1 in
- add)
-
- header file
-
-
-
-}
-
-
-for ins in add sub mul div eq ne lt gt le ge unord
- do
- versionline=" ";
- for a in 32 64 128; do
- width=$a
- case $width in
- 32) postfix=sd ;;
- 64) postfix=dd ;;
- 128) postfix=td ;;
- esac
- case $ins in
- add|sub|mul|div)
- define=L_${ins}_${postfix}
- file=${ins}${postfix}3
- case $ins in
- add) desc="addition";;
- sub) desc="subtraction";;
- mul) desc="multiplication";;
- div) desc="division";;
- esac
- type=_Decimal${width}
- ;;
- eq|ne|lt|gt|le|ge|unord)
- define=L_${ins}_${postfix}
- file=${ins}${postfix}2
- case $ins in
- eq) desc="compare equality";;
- ne) desc="compare inequality";;
- lt) desc="compare less-than";;
- gt) desc="compare greater-than";;
- le) desc="compare less-than or equal";;
- ge) desc="compare greater-than or equal";;
- unord) desc="compare unordered";;
- esac
- ;;
- extend) case $width in
- 32) define=L_sd_to_dd; width=32; file=extendsddd2
- desc="extension to {{{_Decimal64}}}";;
- 64) define=L_sd_to_td; width=32; file=extendsdtd2
- desc="extension to {{{_Decimal128}}}";;
- 128) define=L_dd_to_td; width=64; file=extendddtd2
- desc="extension to {{{_Decimal128}}}";;
- esac
- ;;
- extend2) case $width in
- 32) define=L_sf_to_sd; width=32; file=extendsfsd
- desc="extension from float";;
- 64) define=L_sd_to_df; width=32; file=extendsddf
- desc="extension to double";;
- 128) define=L_sd_to_tf; width=32; file=extendsdtf
- desc="extension to long double";;
- esac
- ;;
- extend3) case $width in
- 32) define=L_sf_to_dd; width=64; file=extendsfdd
- desc="extension from float";;
- 64) define=L_df_to_dd; width=64; file=extenddfdd
- desc="extension from double";;
- 128) define=L_dd_to_tf; width=64; file=extendddtf
- desc="extension to long double";;
- esac
- ;;
- extend4) case $width in
- 32) define=L_sf_to_td; width=128; file=extendsftd
- desc="extension from float";;
- 64) define=L_df_to_td; width=128; file=extenddftd
- desc="extension from double";;
- 128) define=L_tf_to_td; width=128; file=extendtftd
- desc="extension from long double";;
- esac
- ;;
-
- trunc) case $width in
- 32) define=L_td_to_sd; width=128; file=trunctdsd2
- desc="truncation to {{{_Decimal32}}}";;
- 64) define=L_dd_to_sd; width=64; file=truncddsd2
- desc="truncation to {{{_Decimal32}}}";;
- 128) define=L_td_to_dd; width=128; file=trunctddd2
- desc="truncation to {{{_Decimal64}}}";;
- esac
- ;;
- trunc2) case $width in
- 32) define=L_sd_to_sf; width=32; file=truncsdsf
- desc="truncation to float";;
- 64) define=L_df_to_sd; width=32; file=truncdfsd
- desc="truncation from double";;
- 128) define=L_tf_to_sd; width=32; file=trunctfsd
- desc="truncation from long double";;
- esac
- ;;
- trunc3) case $width in
- 32) define=L_dd_to_sf; width=64; file=truncddsf
- desc="truncation to float";;
- 64) define=L_dd_to_df; width=64; file=truncdddf
- desc="truncation to double";;
- 128) define=L_tf_to_dd; width=64; file=trunctfdd
- desc="truncation from long double";;
- esac
- ;;
- trunc4) case $width in
- 32) define=L_td_to_sf; width=128; file=trunctdsf
- desc="truncation to float";;
- 64) define=L_td_to_df; width=128; file=trunctddf
- desc="truncation to double";;
- 128) define=L_td_to_tf; width=128; file=trunctdtf
- desc="truncation to long double";;
- esac
- ;;
-
- fixsi) define=L_${postfix}_to_si; file=fix${postfix}si; desc="conversion to signed integer";;
- fixdi) define=L_${postfix}_to_di; file=fix${postfix}di; desc="conversion to signed long";;
- fixunssi) define=L_${postfix}_to_usi; file=fixuns${postfix}si; desc="conversion to unsigned integer";;
- fixunsdi) define=L_${postfix}_to_udi; file=fixuns${postfix}di; desc="conversion to unsigned long";;
- floatsi) define=L_si_to_${postfix}; file=float${postfix}si; desc="conversion from signed integer";;
- floatdi) define=L_di_to_${postfix}; file=float${postfix}di; desc="conversion from signed long";;
- floatunssi) define=L_usi_to_${postfix}; file=floatuns${postfix}si; desc="conversion from unsigned integer";;
- floatunsdi) define=L_udi_to_${postfix}; file=floatuns${postfix}di; desc="conversion from unsigned long";;
-
- dfp_classify) define=L_classify_${postfix}; file=dfp_classify_${postfix}; desc="dfp classify";;
- dfp_frexp) define=L_frexp_${postfix}; file=dfp_frexp_${postfix}; desc="dfp frexp";;
- dfp_trunc) define=L_trunc_${postfix}; file=dfp_trunc_${postfix}; desc="dfp trunc";;
- dfp_classify_f) case $width in
- 32) define=L_classify_sf; file=dfp_classify_sf; desc="dfp classify float";;
- 64) define=L_classify_df; file=dfp_classify_df; desc="dfp classify double";;
- 128) define=L_classify_tf; file=dfp_classify_tf; desc="dfp classify long double";;
- esac
- ;;
- esac
- versionline="${versionline} __${file};"
-# echo ${define} ${file}.c ${width}
-# echo "||{{{__${file}}}}||<#FFCC66 (>libgcc||Power6|| ||gcc/gcc/config/rs6000/dfp.md||{{{_Decimal${width}}}} ${desc}||"
-# echo "||{{{__${file}}}}||<#99CC99 (>libdfp||generic||missing||libc/dfp/sysdeps/soft-dfp/${file}.c||{{{_Decimal${width}}}} ${desc}||"
-# echo "||{{{__${file}}}}||<#99CC99 (>libdfp||Power6||completed||libc/dfp/sysdeps/powerpc/powerpc32/power6/fpu/${file}.S||{{{_Decimal${width}}}} ${desc}||"
- echo "||{{{__${file}}}}||<#FFCC66 (>complete||<#99CC99 (>complete||<#99CC99 (>complete|| ||{{{_Decimal${width}}}} ${desc}||"
-
- makeline="${makeline} ${file}"
-
- cat > ${file}.c << EOF
-/* _Decimal${width} $desc for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-EOF
-
- if [ ${width} == 32 ]; then
- file32=${file}.c
- cat > ${file32} << EOF32
-#ifndef _DECIMAL_SIZE
-# include <decimal32.h>
-# define _DECIMAL_SIZE 32
-#endif
-#include <errno.h>
-
-
-${type} ${file} (
-
-EOF32
-
- elif [ ${width} == 64 ]; then
- echo "#define _DECIMAL_SIZE 64" >> ${file}.c
- echo "#include <decimal64.h>" >> ${file}.c
- echo "" >> ${file}.c
- echo "#include \"${file32}\"" >> ${file}.c
-
- elif [ ${width} == 128 ]; then
- echo "#define _DECIMAL_SIZE 128" >> ${file}.c
- echo "#include <decimal128.h>" >> ${file}.c
- echo "" >> ${file}.c
- echo "#include \"${file32}\"" >> ${file}.c
- fi
-
-
-
-
- done
- echo "${versionline}" >> ${versions}
- echo "${makeline} \\" >> ${makefile}
- makeline=" "
-
-done
-
-echo " }" >> ${versions}
-echo "}" >> ${versions}
-
-echo "endif" >> ${makefile}
-
-exit
-
-cat > ${file}.c << EOF
-/* Declare arithmetic operations using 32-bit decimal types
- Copyright (C) 2006 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define WIDTH 32
-
-#define L_addsub_sd
-#define L_mul_sd
-#define L_div_sd
-
-#define L_eq_sd
-#define L_ne_sd
-#define L_lt_sd
-#define L_gt_sd
-#define L_le_sd
-#define L_ge_sd
-
-#define DFP_EXCEPTIONS_ENABLED 1
-#define DFP_HANDLE_EXCEPTIONS feraiseexcept
-
-EOF
-
-
Index: dfp/sysdeps/soft-dfp/Makefile
===================================================================
--- dfp/sysdeps/soft-dfp/Makefile.orig 2008-08-28 15:23:11.000000000 +0200
+++ dfp/sysdeps/soft-dfp/Makefile 2008-08-28 15:23:13.000000000 +0200
@@ -1,34 +1,34 @@
# Makefile fragment for soft-dfp.
ifeq ($(subdir),dfp)
-sysdep-CFLAGS += -DWORDS_BIG_ENDIAN=1 -DLONG_DOUBLE_TYPE_SIZE=128 -DBITS_PER_UNIT=8 -Wall
-libdfp-routines += \
- addsd3 adddd3 addtd3 \
- subsd3 subdd3 subtd3 \
- mulsd3 muldd3 multd3 \
- divsd3 divdd3 divtd3 \
- eqsd2 eqdd2 eqtd2 \
- nesd2 nedd2 netd2 \
- ltsd2 ltdd2 lttd2 \
- gtsd2 gtdd2 gttd2 \
- lesd2 ledd2 letd2 \
- gesd2 gedd2 getd2 \
- unordsd2 unorddd2 unordtd2 \
- extendsddd2 extendsdtd2 extendddtd2 \
- extendsfsd extendsddf extendsdtf \
- extendsfdd extenddfdd extendddtf \
- extendsftd extenddftd extendtftd \
- trunctdsd2 truncddsd2 trunctddd2 \
- truncsdsf truncdfsd trunctfsd \
- truncddsf truncdddf trunctfdd \
- trunctdsf trunctddf trunctdtf \
- fixsdsi fixddsi fixtdsi \
- fixsddi fixdddi fixtddi \
- fixunssdsi fixunsddsi fixunstdsi \
- fixunssddi fixunsdddi fixunstddi \
- floatsisd floatsidd floatsitd \
- floatdisd floatdidd floatditd \
- floatunssisd floatunssidd floatunssitd \
- floatunsdisd floatunsdidd floatunsditd \
- decpowof2 binpowof10 classify
+sysdep-CFLAGS += -DWORDS_BIT_ENDIAN=1 -DLONG_DOUBLE_TYPE_SIZE=128 -DBITS_PER_UNIT=8
+libdfp-routines += \
+ dpd-addsd3 dpd-adddd3 dpd-addtd3 \
+ dpd-subsd3 dpd-subdd3 dpd-subtd3 \
+ dpd-mulsd3 dpd-muldd3 dpd-multd3 \
+ dpd-divsd3 dpd-divdd3 dpd-divtd3 \
+ dpd-eqsd2 dpd-eqdd2 dpd-eqtd2 \
+ dpd-nesd2 dpd-nedd2 dpd-netd2 \
+ dpd-ltsd2 dpd-ltdd2 dpd-lttd2 \
+ dpd-gtsd2 dpd-gtdd2 dpd-gttd2 \
+ dpd-lesd2 dpd-ledd2 dpd-letd2 \
+ dpd-gesd2 dpd-gedd2 dpd-getd2 \
+ dpd-unordsd2 dpd-unorddd2 dpd-unordtd2 \
+ dpd-extendsddd2 dpd-extendsdtd2 dpd-extendddtd2 \
+ dpd-extendsfsd dpd-extendsddf dpd-extendsdtf \
+ dpd-extendsfdd dpd-extenddfdd dpd-extendddtf \
+ dpd-extendsftd dpd-extenddftd dpd-extendtftd \
+ dpd-trunctdsd2 dpd-truncddsd2 dpd-trunctddd2 \
+ dpd-truncsdsf dpd-truncdfsd dpd-trunctfsd \
+ dpd-truncddsf dpd-truncdddf dpd-trunctfdd \
+ dpd-trunctdsf dpd-trunctddf dpd-trunctdtf \
+ dpd-fixsdsi dpd-fixddsi dpd-fixtdsi \
+ dpd-fixsddi dpd-fixdddi dpd-fixtddi \
+ dpd-fixunssdsi dpd-fixunsddsi dpd-fixunstdsi \
+ dpd-fixunssddi dpd-fixunsdddi dpd-fixunstddi \
+ dpd-floatsisd dpd-floatsidd dpd-floatsitd \
+ dpd-floatdisd dpd-floatdidd dpd-floatditd \
+ dpd-floatunssisd dpd-floatunssidd dpd-floatunssitd \
+ dpd-floatunsdisd dpd-floatunsdidd dpd-floatunsditd \
+ decpowof2 binpowof10 classify
endif
Index: dfp/sysdeps/soft-dfp/muldd3.c
===================================================================
--- dfp/sysdeps/soft-dfp/muldd3.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal64 multiplication for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 64
-#define ACTUAL_FUNCTION_NAME __muldd3
-#include <decimal64.h>
-
-#include "mulsd3.c"
Index: dfp/sysdeps/soft-dfp/mulsd3.c
===================================================================
--- dfp/sysdeps/soft-dfp/mulsd3.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,68 +0,0 @@
-/* _Decimal32 multiplication for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#ifndef _DECIMAL_SIZE
-# include <decimal32.h>
-# define _DECIMAL_SIZE 32
-# define ACTUAL_FUNCTION_NAME __mulsd3
-#endif
-
-#include <decContext.h>
-#include <decNumber.h>
-#include <math.h>
-
-#define FUNCTION_NAME mul
-
-#include <dfpmacro.h>
-DEC_TYPE
-ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
-{
- DEC_TYPE result;
- decNumber dn_x, dn_y, dn_result;
- decContext context;
- ___decContextDefault(&context, DEFAULT_CONTEXT);
-
- FUNC_CONVERT_TO_DN(&x, &dn_x);
- FUNC_CONVERT_TO_DN(&y, &dn_y);
-
- ___decNumberMultiply(&dn_result, &dn_x, &dn_y, &context);
-
- if (context.status != 0)
- {
- int ieee_flags = 0;
- if (context.status & DEC_IEEE_854_Division_by_zero)
- ieee_flags |= FE_DIVBYZERO;
- if (context.status & DEC_IEEE_854_Inexact)
- ieee_flags |= FE_INEXACT;
- if (context.status & DEC_IEEE_854_Invalid_operation)
- ieee_flags |= FE_INVALID;
- if (context.status & DEC_IEEE_854_Overflow)
- ieee_flags |= FE_OVERFLOW;
- if (context.status & DEC_IEEE_854_Underflow)
- ieee_flags |= FE_UNDERFLOW;
- if (ieee_flags != 0)
- feraiseexcept (ieee_flags);
- }
-
- FUNC_CONVERT_FROM_DN (&dn_result, &result, &context);
- return result;
-}
Index: dfp/sysdeps/soft-dfp/multd3.c
===================================================================
--- dfp/sysdeps/soft-dfp/multd3.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal128 multiplication for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 128
-#define ACTUAL_FUNCTION_NAME __multd3
-#include <decimal128.h>
-
-#include "mulsd3.c"
Index: dfp/sysdeps/soft-dfp/nedd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/nedd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal64 compare inequality for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 64
-#define ACTUAL_FUNCTION_NAME __nedd2
-#include <decimal64.h>
-
-#include "nesd2.c"
Index: dfp/sysdeps/soft-dfp/nesd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/nesd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,51 +0,0 @@
-/* _Decimal32 compare inequality for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#ifndef _DECIMAL_SIZE
-# include <decimal32.h>
-# define _DECIMAL_SIZE 32
-# define ACTUAL_FUNCTION_NAME __nesd2
-#endif
-
-#include <decContext.h>
-#include <decNumber.h>
-#include <math.h>
-
-#define FUNCTION_NAME ne
-
-#include <dfpmacro.h>
-int
-ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
-{
- decNumber dn_x, dn_y, result;
- decContext context;
- ___decContextDefault(&context, DEFAULT_CONTEXT);
-
- FUNC_CONVERT_TO_DN(&x, &dn_x);
- FUNC_CONVERT_TO_DN(&y, &dn_y);
-
- if(___decNumberIsNaN(&dn_x) || ___decNumberIsNaN(&dn_y))
- return 1;
-
- ___decNumberCompare(&result, &dn_x, &dn_y, &context);
- return !___decNumberIsZero(&result);
-}
Index: dfp/sysdeps/soft-dfp/netd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/netd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal128 compare inequality for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 128
-#define ACTUAL_FUNCTION_NAME __netd2
-#include <decimal128.h>
-
-#include "nesd2.c"
Index: dfp/sysdeps/soft-dfp/subdd3.c
===================================================================
--- dfp/sysdeps/soft-dfp/subdd3.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal64 subtraction for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 64
-#define ACTUAL_FUNCTION_NAME __subdd3
-#include <decimal64.h>
-
-#include "subsd3.c"
Index: dfp/sysdeps/soft-dfp/subsd3.c
===================================================================
--- dfp/sysdeps/soft-dfp/subsd3.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,68 +0,0 @@
-/* _Decimal32 subtraction for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#ifndef _DECIMAL_SIZE
-# include <decimal32.h>
-# define _DECIMAL_SIZE 32
-# define ACTUAL_FUNCTION_NAME __subsd3
-#endif
-
-#include <decContext.h>
-#include <decNumber.h>
-#include <math.h>
-
-#define FUNCTION_NAME sub
-
-#include <dfpmacro.h>
-DEC_TYPE
-ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
-{
- DEC_TYPE result;
- decNumber dn_x, dn_y, dn_result;
- decContext context;
- ___decContextDefault(&context, DEFAULT_CONTEXT);
-
- FUNC_CONVERT_TO_DN(&x, &dn_x);
- FUNC_CONVERT_TO_DN(&y, &dn_y);
-
- ___decNumberSubtract(&dn_result, &dn_x, &dn_y, &context);
-
- if (context.status != 0)
- {
- int ieee_flags = 0;
- if (context.status & DEC_IEEE_854_Division_by_zero)
- ieee_flags |= FE_DIVBYZERO;
- if (context.status & DEC_IEEE_854_Inexact)
- ieee_flags |= FE_INEXACT;
- if (context.status & DEC_IEEE_854_Invalid_operation)
- ieee_flags |= FE_INVALID;
- if (context.status & DEC_IEEE_854_Overflow)
- ieee_flags |= FE_OVERFLOW;
- if (context.status & DEC_IEEE_854_Underflow)
- ieee_flags |= FE_UNDERFLOW;
- if (ieee_flags != 0)
- feraiseexcept (ieee_flags);
- }
-
- FUNC_CONVERT_FROM_DN (&dn_result, &result, &context);
- return result;
-}
Index: dfp/sysdeps/soft-dfp/subtd3.c
===================================================================
--- dfp/sysdeps/soft-dfp/subtd3.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal128 subtraction for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 128
-#define ACTUAL_FUNCTION_NAME __subtd3
-#include <decimal128.h>
-
-#include "subsd3.c"
Index: dfp/sysdeps/soft-dfp/truncdddf.c
===================================================================
--- dfp/sysdeps/soft-dfp/truncdddf.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal64 to binary double (64)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_BINARY
-#define SRC 64
-#define DEST 64
-#define NAME trunc
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/truncddsd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/truncddsd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal64 to Decimal32
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_DECIMAL
-#define SRC 64
-#define DEST 32
-#define NAME trunc
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/truncddsf.c
===================================================================
--- dfp/sysdeps/soft-dfp/truncddsf.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal64 to binary float (32)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_BINARY
-#define SRC 64
-#define DEST 32
-#define NAME trunc
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/truncdfsd.c
===================================================================
--- dfp/sysdeps/soft-dfp/truncdfsd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary double (64) to Decimal32
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define BINARY_TO_DECIMAL
-#define SRC 64
-#define DEST 32
-#define NAME trunc
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/truncsdsf.c
===================================================================
--- dfp/sysdeps/soft-dfp/truncsdsf.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal32 to binary float (32)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_BINARY
-#define SRC 32
-#define DEST 32
-#define NAME trunc
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/trunctddd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/trunctddd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal128 to Decimal64
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_DECIMAL
-#define SRC 128
-#define DEST 64
-#define NAME trunc
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/trunctddf.c
===================================================================
--- dfp/sysdeps/soft-dfp/trunctddf.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal128 to binary double (64)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_BINARY
-#define SRC 128
-#define DEST 64
-#define NAME trunc
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/trunctdsd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/trunctdsd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal128 to Decimal32
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_DECIMAL
-#define SRC 128
-#define DEST 32
-#define NAME trunc
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/trunctdsf.c
===================================================================
--- dfp/sysdeps/soft-dfp/trunctdsf.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal128 to binary float (32)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_BINARY
-#define SRC 128
-#define DEST 32
-#define NAME trunc
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/trunctdtf.c
===================================================================
--- dfp/sysdeps/soft-dfp/trunctdtf.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from Decimal128 to binary long double (dual 64bit)
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define DECIMAL_TO_BINARY
-#define SRC 128
-#define DEST 128
-#define NAME trunc
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/trunctfdd.c
===================================================================
--- dfp/sysdeps/soft-dfp/trunctfdd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary long double (128) to Decimal64
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define BINARY_TO_DECIMAL
-#define SRC 128
-#define DEST 64
-#define NAME trunc
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/trunctfsd.c
===================================================================
--- dfp/sysdeps/soft-dfp/trunctfsd.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-/* Handle conversion from binary long double (128) to Decimal32
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define BINARY_TO_DECIMAL
-#define SRC 128
-#define DEST 32
-#define NAME trunc
-
-#include "convert.c"
Index: dfp/sysdeps/soft-dfp/unorddd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/unorddd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal64 compare unordered for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 64
-#define ACTUAL_FUNCTION_NAME __unorddd2
-#include <decimal64.h>
-
-#include "unordsd2.c"
Index: dfp/sysdeps/soft-dfp/unordsd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/unordsd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,48 +0,0 @@
-/* _Decimal32 compare unordered for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#ifndef _DECIMAL_SIZE
-# include <decimal32.h>
-# define _DECIMAL_SIZE 32
-# define ACTUAL_FUNCTION_NAME __unordsd2
-#endif
-
-#include <decContext.h>
-#include <decNumber.h>
-#include <math.h>
-
-#define FUNCTION_NAME unord
-
-#include <dfpmacro.h>
-int
-ACTUAL_FUNCTION_NAME (DEC_TYPE x, DEC_TYPE y)
-{
- decNumber dn_x;
- decNumber dn_y;
- decContext context;
- ___decContextDefault(&context, DEFAULT_CONTEXT);
-
- FUNC_CONVERT_TO_DN(&x, &dn_x);
- FUNC_CONVERT_TO_DN(&y, &dn_y);
-
- return (___decNumberIsNaN(&dn_x) || ___decNumberIsNaN(&dn_y));
-}
Index: dfp/sysdeps/soft-dfp/unordtd2.c
===================================================================
--- dfp/sysdeps/soft-dfp/unordtd2.c 2008-08-28 15:23:11.000000000 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-/* _Decimal128 compare unordered for soft-dfp
- Copyright (C) 2007 IBM Corporation.
-
- Author(s): Pete Eberlein <eberlein@xxxxxxxxxx>
-
- The Decimal Floating Point C Library is free software; you can
- redistribute it and/or modify it under the terms of the GNU Lesser
- General Public License version 2.1.
-
- The Decimal Floating Point 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 Lesser General Public License version 2.1 for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License version 2.1 along with the Decimal Floating Point C Library;
- if not, write to the Free Software Foundation, Inc., 59 Temple Place,
- Suite 330, Boston, MA 02111-1307 USA.
-
- Please see dfp/COPYING.txt for more information. */
-
-
-#define _DECIMAL_SIZE 128
-#define ACTUAL_FUNCTION_NAME __unordtd2
-#include <decimal128.h>
-
-#include "unordsd2.c"
Index: dfp/sysdeps/soft-dfp/Versions
===================================================================
--- dfp/sysdeps/soft-dfp/Versions.orig 2008-08-28 15:23:11.000000000 +0200
+++ dfp/sysdeps/soft-dfp/Versions 2008-08-28 15:23:13.000000000 +0200
@@ -1,32 +1,33 @@
libdfp {
GLIBC_2.7 {
- __addsd3; __adddd3; __addtd3;
- __subsd3; __subdd3; __subtd3;
- __mulsd3; __muldd3; __multd3;
- __divsd3; __divdd3; __divtd3;
- __eqsd2; __eqdd2; __eqtd2;
- __nesd2; __nedd2; __netd2;
- __ltsd2; __ltdd2; __lttd2;
- __gtsd2; __gtdd2; __gttd2;
- __lesd2; __ledd2; __letd2;
- __gesd2; __gedd2; __getd2;
- __unordsd2; __unorddd2; __unordtd2;
- __extendsddd2; __extendsdtd2; __extendddtd2;
- __extendsfsd; __extendsddf; __extendsdtf;
- __extendsfdd; __extenddfdd; __extendddtf;
- __extendsftd; __extenddftd; __extendtftd;
- __trunctdsd2; __truncddsd2; __trunctddd2;
- __truncsdsf; __truncdfsd; __trunctfsd;
- __truncddsf; __truncdddf; __trunctfdd;
- __trunctdsf; __trunctddf; __trunctdtf;
- __fixsdsi; __fixddsi; __fixtdsi;
- __fixsddi; __fixdddi; __fixtddi;
- __fixunssdsi; __fixunsddsi; __fixunstdsi;
- __fixunssddi; __fixunsdddi; __fixunstddi;
- __floatsisd; __floatsidd; __floatsitd;
- __floatdisd; __floatdidd; __floatditd;
- __floatunssisd; __floatunssidd; __floatunssitd;
- __floatunsdisd; __floatunsdidd; __floatunsditd;
+ __dpd_addsd3; __dpd_adddd3; __dpd_addtd3;
+ __dpd_subsd3; __dpd_subdd3; __dpd_subtd3;
+ __dpd_mulsd3; __dpd_muldd3; __dpd_multd3;
+ __dpd_divsd3; __dpd_divdd3; __dpd_divtd3;
+ __dpd_eqsd2; __dpd_eqdd2; __dpd_eqtd2;
+ __dpd_nesd2; __dpd_nedd2; __dpd_netd2;
+ __dpd_ltsd2; __dpd_ltdd2; __dpd_lttd2;
+ __dpd_gtsd2; __dpd_gtdd2; __dpd_gttd2;
+ __dpd_lesd2; __dpd_ledd2; __dpd_letd2;
+ __dpd_gesd2; __dpd_gedd2; __dpd_getd2;
+ __dpd_unordsd2; __dpd_unorddd2; __dpd_unordtd2;
+ __dpd_extendsddd2; __dpd_extendsdtd2; __dpd_extendddtd2;
+ __dpd_extendsfsd; __dpd_extendsddf; __dpd_extendsdtf;
+ __dpd_extendsfdd; __dpd_extenddfdd; __dpd_extendddtf;
+ __dpd_extendsftd; __dpd_extenddftd; __dpd_extendtftd;
+ __dpd_trunctdsd2; __dpd_truncddsd2; __dpd_trunctddd2;
+ __dpd_truncsdsf; __dpd_truncdfsd; __dpd_trunctfsd;
+ __dpd_truncddsf; __dpd_truncdddf; __dpd_trunctfdd;
+ __dpd_trunctdsf; __dpd_trunctddf; __dpd_trunctdtf;
+ __dpd_fixsdsi; __dpd_fixddsi; __dpd_fixtdsi;
+ __dpd_fixsddi; __dpd_fixdddi; __dpd_fixtddi;
+ __dpd_fixunssdsi; __dpd_fixunsddsi; __dpd_fixunstdsi;
+ __dpd_fixunssddi; __dpd_fixunsdddi; __dpd_fixunstddi;
+ __dpd_floatsisd; __dpd_floatsidd; __dpd_floatsitd;
+ __dpd_floatdisd; __dpd_floatdidd; __dpd_floatditd;
+ __dpd_floatunssisd; __dpd_floatunssidd; __dpd_floatunssitd;
+ __dpd_floatunsdisd; __dpd_floatunsdidd; __dpd_floatunsditd;
+
__dfp_classify_sd; __dfp_classify_dd; __dfp_classify_td;
__dfp_frexp_sd; __dfp_frexp_dd; __dfp_frexp_td;
__dfp_trunc_sd; __dfp_trunc_dd; __dfp_trunc_td;