pdp11-g77

Paul Koning pkoning@equallogic.com
Thu Feb 5 15:03:00 GMT 2004


>>>>> "Jim" == Jim Wilson <wilson@specifixinc.com> writes:

 Jim> Paul Koning wrote:
 >> 1. Change the default to -mfloat32.  2. Take out the selectable
 >> size and make float 32 bits, which seems like it would better
 >> match expectations anyway.  3. Have -mfloat32 supplied
 >> automatically by fortran compiles.

 Jim> (3) would confuse linking C code and Fortran code together,
 Jim> which might even break g77 as much of the runtime library is
 Jim> written in C.  I don't think this is a good option.

Good point, thanks.

 Jim> The size is selectable apparently because you will get poor
 Jim> performance with 32-bit floats, because the FPU requires
 Jim> mode-switching which is currently not implemented.  

Mode switching is not implemented, but there's another way, and that
is what's currently there: 32 bit floats appear only in memory, and
are converted to/from double in the CPU registers.  So the arithmetic
performance should be the same either way (and slower than the best
possible because the CPU is always doing 64 bit arithmetic).  But I
wouldn't expect 32 bit to be slower than 64.  Something to test...

  paul



More information about the Gcc mailing list