For convenient use in libc, add unions of the C floating types and their
corresponding structure definitions.
This commit is contained in:
parent
7ec692e7d5
commit
b37192f049
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: ieee.h,v 1.4 2003/10/26 20:55:30 kleink Exp $ */
|
||||
/* $NetBSD: ieee.h,v 1.5 2003/10/26 21:46:46 kleink Exp $ */
|
||||
|
||||
/* $OpenBSD: ieee.h,v 1.1 1999/04/20 19:44:04 mickey Exp $ */
|
||||
|
||||
|
@ -81,3 +81,11 @@ struct ieee_ext {
|
|||
* Exponent biases.
|
||||
*/
|
||||
#define EXT_EXP_BIAS 16383
|
||||
|
||||
/*
|
||||
* Convenience data structures.
|
||||
*/
|
||||
union ieee_ext_u {
|
||||
long double extu_ld;
|
||||
struct ieee_ext extu_ldbl;
|
||||
};
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: ieee.h,v 1.7 2003/10/26 20:59:51 kleink Exp $ */
|
||||
/* $NetBSD: ieee.h,v 1.8 2003/10/26 21:46:46 kleink Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1992, 1993
|
||||
|
@ -82,4 +82,12 @@ struct ieee_ext {
|
|||
*/
|
||||
#define EXT_EXP_BIAS 16383
|
||||
|
||||
/*
|
||||
* Convenience data structures.
|
||||
*/
|
||||
union ieee_ext_u {
|
||||
long double extu_ld;
|
||||
struct ieee_ext extu_ldbl;
|
||||
};
|
||||
|
||||
#endif /* !__mc68010__ */
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: ieee.h,v 1.5 2003/10/26 20:55:31 kleink Exp $ */
|
||||
/* $NetBSD: ieee.h,v 1.6 2003/10/26 21:46:46 kleink Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1992, 1993
|
||||
|
@ -86,4 +86,12 @@ struct ieee_ext {
|
|||
* Exponent biases.
|
||||
*/
|
||||
#define EXT_EXP_BIAS 16383
|
||||
|
||||
/*
|
||||
* Convenience data structures.
|
||||
*/
|
||||
union ieee_ext_u {
|
||||
long double extu_ld;
|
||||
struct ieee_ext extu_ldbl;
|
||||
};
|
||||
#endif /* __arch64__ */
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: ieee.h,v 1.6 2003/10/26 20:59:51 kleink Exp $ */
|
||||
/* $NetBSD: ieee.h,v 1.7 2003/10/26 21:46:46 kleink Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1992, 1993
|
||||
|
@ -86,3 +86,11 @@ struct ieee_ext {
|
|||
* Exponent biases.
|
||||
*/
|
||||
#define EXT_EXP_BIAS 16383
|
||||
|
||||
/*
|
||||
* Convenience data structures.
|
||||
*/
|
||||
union ieee_ext_u {
|
||||
long double extu_ld;
|
||||
struct ieee_ext extu_ldbl;
|
||||
};
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: ieee754.h,v 1.1 2003/10/26 20:48:17 kleink Exp $ */
|
||||
/* $NetBSD: ieee754.h,v 1.2 2003/10/26 21:46:46 kleink Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1992, 1993
|
||||
|
@ -136,3 +136,16 @@ struct ieee_double {
|
|||
*/
|
||||
#define SNG_EXP_BIAS 127
|
||||
#define DBL_EXP_BIAS 1023
|
||||
|
||||
/*
|
||||
* Convenience data structures.
|
||||
*/
|
||||
union ieee_single_u {
|
||||
float sngu_f;
|
||||
struct ieee_single sngu_flt;
|
||||
};
|
||||
|
||||
union ieee_double_u {
|
||||
double dblu_d;
|
||||
struct ieee_double dblu_dbl;
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue