This is the mail archive of the gcc-bugs@gcc.gnu.org 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]

Re: optimization/8110: GCC 3.2: wrong code optimization with -O2


Synopsis: GCC 3.2: wrong code optimization with -O2

State-Changed-From-To: open->closed
State-Changed-By: rth
State-Changed-When: Tue Oct  1 14:19:00 2002
State-Changed-Why:
    The code in rtx_alloc is broken in spec2k.  Use the following.
    
    --- rtl.c.orig  Tue Oct  1 14:16:34 2002
    +++ rtl.c       Tue Oct  1 14:17:35 2002
    @@ -234,9 +234,7 @@
          one int, but we don't want to assume that and it isn't very portable
          anyway; this is.  */
     
    -  length = (sizeof (struct rtx_def) - sizeof (rtunion) - 1) / sizeof (int);
    -  for (; length >= 0; length--)
    -    ((int *) rt)[length] = 0;
    +  memset (rt, 0, sizeof (struct rtx_def) - sizeof (rtunion));
     
       PUT_CODE (rt, code);
     

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=8110


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