Integral conversions in C/C++

Andrew Haley aph@redhat.com
Wed Apr 23 11:22:00 GMT 2008


Christian Böhme wrote:
> John Fine wrote:
> 
>> But, if the machine has a 32bit by 32bit multiply that produces the
>> identical 64bit result,  the optimizer is free to use it.
> 
> Here's the catch:
> 
> Optimizers aren't part of the standard.  If the standard(s) were to
> allow for much more explicit expressions, many optimizers would do a
> much better job.  Writing optimizers around standards is what since
> the 90ies characterizes ``good'' compilers.  Here's where the kewl
> stuff happens.
> 
> A strictly standard conforming C/C++ frontend would not (actually
> see the need to) propagate that information to the middle/back ends.

What ridiculous nonsense!  Where in the definition of "strictly standard
conforming" does it forbid the propagation of such information?

Andrew.



More information about the Gcc-help mailing list