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]

Re: egcs1.1.1 bogus warning: "might be used uninitialized"



  In message <Pine.LNX.4.04.9902101547550.31679-100000@spud.eng.fore.com>you wr
ite:
  > On Wed, 10 Feb 1999, Jeffrey A Law wrote:
  > 
  > > Now, changing code in one function should not be changing the warnings gc
  > c
  > > emits for an unrelated function *unless* the function changed is actually
  > > a template or is inlined.  If neither of those cases are true, then there
  > 's
  > > a serious bug that needs to be addressed.
  > 
  > In my case, this is plain C code, being compiled with gcc, not g++.
  > They are not templates, and are not inlined.
  > 
  > On the linux machine, both warnings were in the same function.
  > On sunos, the 3rd additional warning was in an unrelated function.
  > 
  > When I deleted some other, unrelated, functions from the file, the
  > warnings went away!  If instead, I initialized *one* of those
  > variables, then *all* the warnings would again go away.
  > 
  > So, yes, it looks like a serious bug.  But luckily the only consequence
  > appears to be bogus warning messages.  That's still a pain though,
  > since we always like to compile with -Wall -Werror.
Can you get me a testcase?  This is *real* serious since it is a
non-deterministic problem -- which typically means memory corruption or a
dangling pointer.

It is critical that we nail those down as soon as they appear since they tend
to disappear without notice.
jeff


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