[Bug c++/89976] missing uninitialized warning for uninitialized struct member (VOPs)

2021-04-01 Thread msebor at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89976
Bug 89976 depends on bug 79658, which changed state.

Bug 79658 Summary: [-Wuninitialized] referencing uninitialized field of POD 
struct should warn
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79658

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

[Bug c++/89976] missing uninitialized warning for uninitialized struct member (VOPs)

2020-06-23 Thread msebor at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89976
Bug 89976 depends on bug 49754, which changed state.

Bug 49754 Summary: Wuninitialized does not work with structs/unions/arrays
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=49754

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

[Bug c++/89976] missing uninitialized warning for uninitialized struct member (VOPs)

2019-11-02 Thread manu at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89976

Manuel López-Ibáñez  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2019-11-02
 CC||manu at gcc dot gnu.org
 Depends on||49754, 79658
Summary|missing uninitialized   |missing uninitialized
   |warning: laundering via |warning for uninitialized
   |passing object through a|struct member (VOPs)
   |function|
 Ever confirmed|0   |1

--- Comment #3 from Manuel López-Ibáñez  ---
I guess it doesn't warn because it gets converted to memory access.

bar ()
{
  int x$x;
  int _1;

   [local count: 1073741825]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG this => &x
  # DEBUG D#1 => {CLOBBER}
  # DEBUG x$x => D#1
  # DEBUG D#2 => {CLOBBER}
  # DEBUG x$y => D#2
  # DEBUG x$y => 0
  # DEBUG this => NULL
  # DEBUG BEGIN_STMT
  # DEBUG D#3 => {CLOBBER}
  # DEBUG x$x => D#3
  # DEBUG D#4 => {CLOBBER}
  # DEBUG x$y => D#4
  # DEBUG x$x => x$x_3(D)
  # DEBUG x$y => 0
  # DEBUG x$x => NULL
  # DEBUG BEGIN_STMT
  _1 = x$x_3(D) + 2;
  # DEBUG x$x => _1
  # DEBUG BEGIN_STMT
  # DEBUG D#5 => {CLOBBER}
  # DEBUG x$x => D#5
  return _1;
}


Referenced Bugs:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=49754
[Bug 49754] Wuninitialized does not work with structs/unions/arrays
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79658
[Bug 79658] [-Wuninitialized] referencing uninitialized field of POD struct
should warn