public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* adding floating point support
@ 2009-01-23 19:45 Navid Toosizadeh
  2009-01-23 22:43 ` Navid Toosizadeh
  2009-01-24  2:30 ` Ian Lance Taylor
  0 siblings, 2 replies; 3+ messages in thread
From: Navid Toosizadeh @ 2009-01-23 19:45 UTC (permalink / raw)
  To: gcc-help

Greetings,

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.

Best regards
Navid


      

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

* Re: adding floating point support
  2009-01-23 19:45 adding floating point support Navid Toosizadeh
@ 2009-01-23 22:43 ` Navid Toosizadeh
  2009-01-24  2:30 ` Ian Lance Taylor
  1 sibling, 0 replies; 3+ messages in thread
From: Navid Toosizadeh @ 2009-01-23 22:43 UTC (permalink / raw)
  To: gcc-help

If I make a copy of fp-bit.c and add "#define float" to it and then compile the new file with the original one using the target's gcc compiler? 



----- Original Message ----
From: Navid Toosizadeh <navid_toosizadeh@yahoo.com>
To: gcc-help@gcc.gnu.org
Sent: Friday, January 23, 2009 2:44:55 PM
Subject: adding floating point support

Greetings,

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.

Best regards
Navid


      

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

* Re: adding floating point support
  2009-01-23 19:45 adding floating point support Navid Toosizadeh
  2009-01-23 22:43 ` Navid Toosizadeh
@ 2009-01-24  2:30 ` Ian Lance Taylor
  1 sibling, 0 replies; 3+ messages in thread
From: Ian Lance Taylor @ 2009-01-24  2:30 UTC (permalink / raw)
  To: Navid Toosizadeh; +Cc: gcc-help

Navid Toosizadeh <navid_toosizadeh@yahoo.com> 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.

Ian

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

end of thread, other threads:[~2009-01-24  2:30 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-01-23 19:45 adding floating point support Navid Toosizadeh
2009-01-23 22:43 ` Navid Toosizadeh
2009-01-24  2:30 ` Ian Lance Taylor

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).