Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
From: David Mosberger-Tang <davidm@azstarnet.com>
Subject: Re: SIGFPE -- the answer
Date: Mon, 21 Apr 1997 17:51:59 -0700	[thread overview]
Message-ID: <3e46146c294cafbb1628f26d5c5a0fd7.axp-list@archive.invalid> (raw)

[I'm replying to a mail that appeared in the axp-list mailing list archive.
 I may have missed some follow-ups and apologize if this is an old hat...]

 Jim> Here's da goods:  To read and write the floating-point exception 
 Jim> enable bits, you can use the following routines:

 Richard> Linux follows DEC in calling those functions ieee_get_fp_control()
 Richard> and ieee_set_fp_control() respectively.

Yes, those routines are for DEC Unix compatibility (not binary
compatibility, but to make it easier to port DEC Unix source code to
Linux/Alpha).  However, there is also the setfpucw() call which is
there for Linux/x86 compatibility.

 Richard> And to answer the question that came up elsewhere: those bits are
 Richard> on by default on Linux/Alpha because they are on by default on DU.

For the kernel that is true.  For Linux application, the behaviour _should_
be the same as for Linux/x86.  glibc's init-first.c has the following
call:

      /* Set the FPU control word to the proper default value.  */
      __setfpucw (__fpu_control);

This is intented to establish the same environment as under Linux/x86
(modulo extendend precision).  But I think it would be an exaggeration
to claim that this code has been thoroughly tested, so it wouldn't
surprise me if things do not fully work as intended.

	--david

--
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject.  Do not send it to axp-list@redhat.com

             reply	other threads:[~1997-04-22  0:51 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1997-04-22  0:51 David Mosberger-Tang [this message]
  -- strict thread matches above, loose matches on Subject: below --
1997-04-22 14:49 SIGFPE -- the answer Randy Chapman
     [not found] <3356D61F.78ED3FC1@jrp.tiac.net>
1997-04-21 18:32 ` Richard Henderson
1997-04-18  4:39 Randy Chapman
1997-04-18  2:02 Jim Paradis
     [not found] <33559394.1AD81EDB@jrp.tiac.net>
1997-04-17 19:51 ` Richard Henderson
1997-04-17 10:45 Uncle George
1997-04-17  3:05 Jim Paradis
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