grub2: bring back build of aros-side grub2 tools
[AROS.git] / workbench / libs / mathieeedoubbas / ieeedpsub.c
blob190f0dc055e6f38b10cf33da00ddce09ecfa5434
1 /*
2 Copyright © 1995-2003, The AROS Development Team. All rights reserved.
3 $Id$
4 */
6 #include "mathieeedoubbas_intern.h"
8 /*****************************************************************************
10 NAME */
12 AROS_LHQUAD2(double, IEEEDPSub,
14 /* SYNOPSIS */
15 AROS_LHAQUAD(double, y, D0, D1),
16 AROS_LHAQUAD(double, z, D2, D3),
18 /* LOCATION */
19 struct MathIeeeDoubBasBase *, MathIeeeDoubBasBase, 12, MathIeeeDoubBas)
21 /* FUNCTION
22 Subtracts two IEEE double precision numbers
24 INPUTS
26 RESULT
27 +1 : y > z
28 0 : y = z
29 -1 : y < z
31 Flags:
32 zero : y = z
33 negative : y < z
34 overflow : 0
36 BUGS
38 INTERNALS
40 *****************************************************************************/
42 AROS_LIBFUNC_INIT
44 QUAD * Qz = (QUAD *)&z;
46 XOR64QC(*Qz, IEEEDPSign_Mask_Hi, IEEEDPSign_Mask_Lo );
47 return IEEEDPAdd(y,z);
49 AROS_LIBFUNC_EXIT