Usenet comp.sys.dec (1990-2013)
 help / color / mirror / Atom feed
* DEC Unix 4.0 IEEE floating point on Alpha
@ 1997-07-23  4:00 James Nau
  1997-07-23  4:00 ` Paul DeMone
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: James Nau @ 1997-07-23  4:00 UTC (permalink / raw)



Hi all,

I've come across a problem with the floating point format on
DEC alphas.  It happens under both VMS and Digital Unix.  It
appears to me that Alphas store IEEE floating point numbers
backwards.  On an Alpha, for value 511.0, I get:

00 80 FF 43

as the binary representation [written by 
fwrite( &x, sizeof(float), 1, outfile);]

while on every other Unix workstation I've been able to get my fingers
on yields:

43 FF 80 00

which all the tools and info I find say this is 511.0 in IEEE format.

Can someone tell me if it's possible to get the Alpha to read/write
IEEE in the right order?  I've tried cc with the -ieee switch, but
that didn't do anything useful, and I tried gcc, and under VMS, I
tried cc/float=ieee ..., all of which yielded the 'backwards' IEEE format.

[my immediate need is for reading IEEE binary format generated
elsewhere, into a canned program, without wanting to write a byte
re-ordering program...]

Thanks for any help

james

james@engrs.unl.edu



^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~1997-08-05  4:00 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1997-07-23  4:00 DEC Unix 4.0 IEEE floating point on Alpha James Nau
1997-07-23  4:00 ` Paul DeMone
1997-07-24  4:00   ` Emmanuel Choquet
1997-07-24  4:00 ` A.Arnold
1997-07-24  4:00   ` fairfield
1997-07-25  4:00     ` Steve Lionel
1997-07-24  4:00 ` Jim Griffin
1997-07-26  4:00   ` John Hascall
1997-08-05  4:00   ` Eugene Y C Chu

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