This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PATCH for Re: optimization/7557: gcc-3.1.1 (debian/i386): wrong codewith -O2 / bitfields / pointer aliasing

On Tue, 13 Aug 2002, Johannes Stezenbach wrote:
> I am not against including -fstrict-aliasing in -O2. I like
> good optimization.
> [...]
> Please consider adding a note to NEWS and/or
> or a similar document.



Index: caveats.html
RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-3.0/caveats.html,v
retrieving revision 1.5
diff -u -3 -p -r1.5 caveats.html
--- caveats.html	23 Jan 2002 15:42:27 -0000	1.5
+++ caveats.html	14 Aug 2002 07:48:32 -0000
@@ -8,6 +8,13 @@
 <h1>GCC 3.0 Caveats</h1>

+  <li><code>-fstrict-aliasing</code> is now part of <code>-O2</code>
+  and higher optimization levels.  This allows the compiler to assume
+  the strictest aliasing rules applicable to the language being
+  compiled.  For C and C++, this activates optimizations based on the
+  type of expressions.  This optimization may thus break old,
+  non-compliant code.
   <li>Enumerations are now properly promoted to <code>int</code> in
   function parameters and function returns.  Normally this change is
   not visible, but when using <code>-fshort-enums</code> this is an

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]