xref: /original-bsd/sys/vax/include/float.h (revision 5a948429)
1 /*
2  * Copyright (c) 1989 Regents of the University of California.
3  * All rights reserved.
4  *
5  * Redistribution and use in source and binary forms are permitted
6  * provided that the above copyright notice and this paragraph are
7  * duplicated in all such forms and that any documentation,
8  * advertising materials, and other materials related to such
9  * distribution and use acknowledge that the software was developed
10  * by the University of California, Berkeley.  The name of the
11  * University may not be used to endorse or promote products derived
12  * from this software without specific prior written permission.
13  * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
14  * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
15  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
16  *
17  *	@(#)float.h	7.1 (Berkeley) 08/15/89
18  */
19 
20 #define FLT_RADIX	2		/* b */
21 #define FLT_ROUNDS	1		/* FP addition rounds to nearest */
22 
23 #define FLT_MANT_DIG	24		/* p */
24 #define FLT_EPSILON	1.19209290E-07F	/* b**(1-p) */
25 #define FLT_DIG		6		/* floor((p-1)*log10(b))+(b == 10) */
26 #define FLT_MIN_EXP	-127		/* emin */
27 #define FLT_MIN		2.93873588E-39F	/* b**(emin-1) */
28 #define FLT_MIN_10_EXP	-38		/* ceil(log10(b**(emin-1))) */
29 #define FLT_MAX_EXP	127		/* emax */
30 #define FLT_MAX		1.70141173E+38F	/* (1-b**(-p))*b**emax */
31 #define FLT_MAX_10_EXP	38		/* floor(log10((1-b**(-p))*b**emax)) */
32 
33 #define DBL_MANT_DIG	56
34 #define DBL_EPSILON	2.775557561562891351E-17
35 #define DBL_DIG		16
36 #define DBL_MIN_EXP	-127
37 #define DBL_MIN		2.938735877055718770E-39
38 #define DBL_MIN_10_EXP	-38
39 #define DBL_MAX_EXP	127
40 #define DBL_MAX		1.701411834604692294E+38
41 #define DBL_MAX_10_EXP	38
42 
43 #define LDBL_MANT_DIG	DBL_MANT_DIG
44 #define LDBL_EPSILON	DBL_EPSILON
45 #define LDBL_DIG	DBL_DIG
46 #define LDBL_MIN_EXP	DBL_MIN_EXP
47 #define LDBL_MIN	DBL_MIN
48 #define LDBL_MIN_10_EXP	DBL_MIN_10_EXP
49 #define LDBL_MAX_EXP	DBL_MAX_EXP
50 #define LDBL_MAX	DBL_MAX
51 #define LDBL_MAX_10_EXP	DBL_MAX_10_EXP
52