This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: front-end target arithmetic (was: [G95] Re: [tree-ssa] Integrating g95)
- From: dewar at gnat dot com (Robert Dewar)
- To: guerby at acm dot org, mszick at goquest dot com
- Cc: bosch at gnat dot com, dberlin at dberlin dot org, gcc at gcc dot gnu dot org,law at redhat dot com, neil at daikokuya dot co dot uk
- Date: Tue, 3 Jun 2003 15:10:21 -0400 (EDT)
- Subject: Re: front-end target arithmetic (was: [G95] Re: [tree-ssa] Integrating g95)
> > On Tuesday 03 June 2003 07:40 am, Geert Bosch wrote:
> > > Now of course, this is mostly because Ada requires calculations of
> > > "static" expressions (subset of compile-time known expressions) to be
> > > performed exactly.
> > Ouch.
>
> Well for a language designed in 1995, I don't believe it's that silly
> to require this given the portability advantage it gives
> for not that much work on implementors.
The reason incidentally is the design principle that legality of programs should
not depend on target arithmetic properties. For example, if we have
case x is
when (big expression evaluating to true or false statically) => ...
when (big expression evaluating to true or false statically) => ...
end case;
then we don't want the legality of this case to depend on the evaluation details.