Here is a reduced version of 20050713-1.c.

extern void abort (void);

struct S
{
  int a, b, c;
};

int
foo2 (struct S x, struct S y)
{
  if (x.b != 4)
    abort ();
  return 0;
}

int
bar2 (struct S x, struct S y)
{
  return foo2 (y, x);
}

int
main (void)
{
  struct S a = { 3, 4, 5 }, b = { 6, 7, 8 };

  bar2 (b, a);
  return 0;
}

Unlike PR 23090, which is for powerpc and only about -O2,
this one fails with -O2 or -Os on arm-none-eabi.

Since I have not analyzed the failure, I cannot conclude that
this is a duplicate of PR 23090 yet.

-- 
           Summary: 20050713-1.c fails on arm-none-eabi with -O2 or -Os.
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: target
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: kazu at gcc dot gnu dot org
                CC: gcc-bugs at gcc dot gnu dot org
GCC target triplet: arm-none-eabi


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

Reply via email to