Usenet comp.unix.osf.osf1 (1992-2004)
 help / color / mirror / Atom feed
From: neideck@nestvx.enet.dec.com (Burkhard Neidecker-Lutz)
Subject: Re: Need help with FPE control
Date: 7 Nov 1994 15:26:12 GMT	[thread overview]
Message-ID: <39lgukINNds1@usenet.pa.dec.com> (raw)
In-Reply-To: CyvF71.CoH@plato.ds.boeing.com

In article <CyvF71.CoH@plato.ds.boeing.com> ian@flash.ds.boeing.com (Ian Searle) writes:
>I have been trying to set up a C program on a DEC-Alpha running OSF so
>that the following will behave properly (ala IEEE-754)
>
>	1/0 + 1 => Inf
>
>I can get the Alpha to ignore the FPE, or use my own signal handler,
>but I cannot get it to work properly with Infs and NaNs.
>
>I have been using the compiler flag -resumption_safe, and 
>ieee_fp_get_control() and ieee_fp_set_control() all to no avail.

Mmh. Works for me.

% uname -a
OSF1 sand2.kar.dec.com V3.0 347 alpha
% cat a.c
#include <stdio.h>

main(argc,argv)
int argc;
char *argv[];
{
  double a , b;

  a = 1.0;
  b = 0.0;

  printf("%f\n", a/b + a);
}
% cc -ieee_with_no_inexact a.c
./a.out
% ./a.out
INF

		Burkhard Neidecker-Lutz

GLASS Project, CEC Karlsruhe 
Advanced Technology Group, Digital Equipment Corporation
neideck@nestvx.enet.dec.com



      reply	other threads:[~1994-11-07 15:26 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1994-11-07  0:11 Need help with FPE control Ian Searle
1994-11-07 15:26 ` Burkhard Neidecker-Lutz [this message]
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox