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 middle-end/65686] [5/6 regression] inconsistent warning maybe-uninitialized: warn about 'unsigned', not warn about 'int'


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

--- Comment #10 from Richard Biener <rguenth at gcc dot gnu.org> ---
(In reply to Jakub Jelinek from comment #9)
> So, does the https://gcc.gnu.org/bugzilla/show_bug.cgi?id=13962#c9 patch
> help here?

Yes.  With it we simplify the function during early FRE to

f (struct S * e)
{
  mytype x;
  mytype * _4;
  unsigned int _6;
  mytype _8;

  <bb 2>:
  _4 = e_3(D)->pu;
  _6 = MEM[(char * {ref-all})_4];
  MEM[(char * {ref-all})&x] = _6;
  _8 = x;
  x ={v} {CLOBBER};
  return _8;

(missed optimization - alias stmt walking doesn't honor edge non-executablility
as figured out by FRE).  Later optimization turns this into

  <bb 2>:
  _3 = e_2(D)->pu;
  _4 = MEM[(char * {ref-all})_3];
  return _4;

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