flip@osu-cgrg.UUCP (Flip Phillips) (02/27/86)
If anyone using the cross compiler system for the sun is having problems
with floating point I/O heres the prob: I think...
The greenhills compiler compiles EVERY double/float into a FFP
number. When passing it to routines it doesnt really convert it into
a double as per the way you do things... it really puts a null byte up
there with it. So much for calling the SPTieee / SPFieee routines since
they return a 32 bit value.
The Lattice library for the sun dev. system is compiled with/does
floating point conversion to IEEE numbers... 32 bit floats, 64 bit doubles.
When, say, printf("%f",val) goes, it expects a double for val in iEEE
format. Fine. Even if you convert it with the afore mentioned things it
seems that it still gets converted into a FFP type pseudo-double with
null byte attached. Bummer. printf's / scanf's conversion routine pukes.
So... I came up with a sorta kluge that I'd be willing to share.
Respond to me via mail 'causin I dont want to clutter up the already
cluttered up net.
If any of you other folk have come up with sumpthin, let me know! I
really would appreciate it.
flip
--
Flip Phillips {ucbvax,decvax}!cbosg!osu-cgrg!flip
Computer Graphics Research Group, The Ohio State University