This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: optimization bug in g77
- To: law at cygnus dot com
- Subject: Re: optimization bug in g77
- From: Mark Mitchell <mark at markmitchell dot com>
- Date: Sun, 21 Feb 1999 16:17:54 -0800
- CC: toon at moene dot indiv dot nluug dot nl, egcs-bugs at cygnus dot com
- References: <7945.919640946@hurl.cygnus.com>
- Reply-to: mark at markmitchell dot com
>>>>> "Jeffrey" == Jeffrey A Law <law@hurl.cygnus.com> writes:
Jeffrey> I think this is a little overly conservative, but I can
Jeffrey> live with it. -f[no]structure-alias or something like
Jeffrey> that?
Jeffrey> The docs might look something like:
Jeffrey> -fstructure-alias: Allow the compiler to assume that a
Jeffrey> structure or array reference at a varying address can
Jeffrey> never conflict with a scalar reference at a fixed
Jeffrey> address. In the vast majority of programs this is safe,
Jeffrey> but in a small number programs a bug in GCC's alias
Jeffrey> analysis can cause incorrect code generation. Thus the
Jeffrey> default is -fno-structure-alias.
This is good. I would suggest a minor modification. Instead of the
part from `In the vast majority' on, how about
Although this optimization is safe, GCC can occasionally lose track
of which references refer to scalars and which to structures,
leading it to perform unsafe transformations. Release 1.2 of EGCS
will incorporate changes which allow GCC to track the
scalar/structure distinction safely. Thus, the optimization will
always be same, and this option will likely be removed.
?
--
Mark Mitchell mark@markmitchell.com
Mark Mitchell Consulting http://www.markmitchell.com