This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: /internet
- To: Joe Buck <jbuck at Synopsys dot COM>
- Subject: Re: /internet
- From: Jeffrey A Law <law at hurl dot cygnus dot com>
- Date: Tue, 15 Dec 1998 20:35:20 -0700
- cc: moshier at mediaone dot net, tprince at cat dot e-mail dot com, bosch at gnat dot com, burley at gnu dot org, egcs at cygnus dot com, hjstein at bfr dot co dot il
- Reply-To: law at cygnus dot com
In message <199812160320.TAA11586@atrus.synopsys.com>you write:
> If I understand correctly, Jeff's proposal was to respect ordering when
> the user provides parentheses, but to leave the compiler free to do
> reordering when the user does not provide parentheses.
>
> That is, for
>
> y = a * b * c * d;
>
> the compiler could do the multiplications in any order, but for
>
> y = a * (b * (c * d));
>
> the compiler is forced to follow the specified order.
>
> I believe that this is consistent with what the relevant language standards
> specify.
You understand my suggestions correctly.
But I'm neither a language lawyer, nor an ieee/fp expert, so you have to take
my suggestions with some care. I certainly wouldn't actually make such changes
without being 100% they're safe according to the language specs and don't
violate the principle of least suprise too often. For that I would have to
lean on folks in on this list to guide me through the pitfalls of each
language and ieee/fp.
jeff