This is the mail archive of the
mailing list for the GCC project.
ColdFire soft-float optimizations
- From: Peter Barada <peter at the-baradas dot com>
- To: gcc at gcc dot gnu dot org
- Date: Thu, 3 Jun 2004 12:42:11 -0400 (EDT)
- Subject: ColdFire soft-float optimizations
I'm thinking about a set of optimizations for single precision
floating point(SPFP) on ColdFire cores that don't have an FPU. These
optimizations make the assumption that the domain of the FP numbers do
not include NaN in any of its forms, and don't have to set errno. I
know that this optimization is not IEEE compliant, so I'm wrangling
with which set of flags to enable this optimization under. I'm
wondering what combination of -ffast-math and
-funsafe-math-optimizations should to be turned on to enable these
As an example, for the absolute value of a SPFP value, the sign bit can
be cleared via an integer instruction instead of having to call out to
the FP library. This would be valid for all normal SPFP values and
infinity. Also, a comparison of a SPFP value against a constant can be
handled via an signed/unsigned integer comparison depending on the
value of the constant.
All suggestions are appreciated.