1989-07-10 11:17:19 +00:00
|
|
|
/*
|
|
|
|
(c) copyright 1989 by the Vrije Universiteit, Amsterdam, The Netherlands.
|
|
|
|
See the copyright notice in the ACK home directory, in the file "Copyright".
|
|
|
|
*/
|
|
|
|
|
1994-06-24 11:31:16 +00:00
|
|
|
/* $Id$ */
|
1989-07-10 11:17:19 +00:00
|
|
|
|
1991-02-19 13:53:04 +00:00
|
|
|
#include "flt_misc.h"
|
1989-07-10 11:17:19 +00:00
|
|
|
|
|
|
|
int flt_status = 0;
|
1993-11-10 11:14:28 +00:00
|
|
|
|
1993-10-21 12:50:58 +00:00
|
|
|
void
|
1989-07-10 11:17:19 +00:00
|
|
|
flt_chk(e)
|
|
|
|
register flt_arith *e;
|
|
|
|
{
|
|
|
|
if (e->flt_exp >= EXT_MAX) {
|
|
|
|
flt_status = FLT_OVFL;
|
|
|
|
e->flt_exp = EXT_MAX;
|
1989-08-01 16:34:01 +00:00
|
|
|
e->m1 = 0x80000000;
|
1989-10-24 14:42:49 +00:00
|
|
|
e->m2 = 0;
|
1989-07-10 11:17:19 +00:00
|
|
|
}
|
|
|
|
if (e->flt_exp <= EXT_MIN) {
|
|
|
|
flt_status = FLT_UNFL;
|
|
|
|
e->flt_exp = 0;
|
1989-08-01 16:34:01 +00:00
|
|
|
e->m1 = 0;
|
1989-07-10 11:17:19 +00:00
|
|
|
e->flt_sign = 0;
|
1989-10-24 14:42:49 +00:00
|
|
|
e->m2 = 0;
|
1989-07-10 11:17:19 +00:00
|
|
|
}
|
|
|
|
}
|