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]

[Bug target/78438] [7 Regression] incorrect comparison optimization


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78438

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED

--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
The over-sized bitfield isn't really needed for this, making it more severe:
struct S {
  long int : 23;
  long int a : 24;
  long int b : 10;
  long int c : 24;
  signed char d : 8;
} s;

__attribute__((noinline, noclone)) void
foo ()
{
  s.d = 0;
  s.c = -1193165L;
}

int
main ()
{
  foo ();
  if (s.d != 0)
    __builtin_abort ();
  return 0;
}

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