public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/49444] New: IV-OPTs changes an unaligned loads into aligned loads incorrectly
@ 2011-06-16 19:45 pinskia at gcc dot gnu.org
  2011-06-16 20:09 ` [Bug tree-optimization/49444] " rguenth at gcc dot gnu.org
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: pinskia at gcc dot gnu.org @ 2011-06-16 19:45 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49444

           Summary: IV-OPTs changes an unaligned loads into aligned loads
                    incorrectly
           Product: gcc
           Version: 4.5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: pinskia@gcc.gnu.org


Take:
/* { dg-do compile { target mips*-*-* } } */
/* { dg-options "-O2" } */
/* { dg-final { scan-assembler "uld\\t|ldr\\t|lwr\\t" } } */


struct s
{
  unsigned int l;
  unsigned int z[2];
};

struct r
{
  char c;
  struct s s;
} __attribute__ ((packed));

struct s *ss;

f (struct r *p, int l)
{
  int i;
  for (i = 0; i < l; i++)
    {
      *ss = p[i].s;
      g ();
    }
}
--- CUT ---
Currently this fails and the load from p[i].s is turned into an aligned load.


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2014-09-03 12:27 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-06-16 19:45 [Bug tree-optimization/49444] New: IV-OPTs changes an unaligned loads into aligned loads incorrectly pinskia at gcc dot gnu.org
2011-06-16 20:09 ` [Bug tree-optimization/49444] " rguenth at gcc dot gnu.org
2011-06-16 20:16 ` pinskia at gcc dot gnu.org
2011-06-16 21:10 ` pinskia at gcc dot gnu.org
2011-06-17  9:06 ` rguenth at gcc dot gnu.org
2011-06-17 16:25 ` pinskia at gcc dot gnu.org
2011-12-16  0:36 ` pinskia at gcc dot gnu.org
2011-12-16  8:02 ` ebotcazou at gcc dot gnu.org
2014-09-03 10:11 ` amker.cheng at gmail dot com
2014-09-03 11:07 ` rguenth at gcc dot gnu.org
2014-09-03 12:27 ` pinskia at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).