adding floating point support
Ian Lance Taylor
Sat Jan 24 02:30:00 GMT 2009
Navid Toosizadeh <firstname.lastname@example.org> writes:
> Assume that we have gcc compiler for a target, and the gcc does not
> support floating point, but integers. Is there a simpler way rather
> than rebuilding the gcc to add support for floating point, for
> example by compiling fp-bit.c? So basically, I'm asking for steps
> to add floating point support without going the difficult path of
> rebuildong and modifying gcc.
I'm not sure what you mean when you say that gcc doesn't support
floating point. The normal gcc releases always support floating
point. If the processor does not have any floating point
instructions, then gcc generates calls to runtime library routines.
Those runtime library routines are generally found in libgcc, and are
often compiled from config/fp-bit.c or from config/soft-fp/* or from
hand-written assembler code. The first two choices should work even
for an unusual target.
More information about the Gcc-help