public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug middle-end/34088]  New: [4.3 regression] ICE with uninitialized variable and -Werror
@ 2007-11-13 22:35 reichelt at gcc dot gnu dot org
  2007-11-13 22:35 ` [Bug middle-end/34088] " reichelt at gcc dot gnu dot org
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2007-11-13 22:35 UTC (permalink / raw)
  To: gcc-bugs

The following valid code snippet triggers an ICE on mainline
when compiled with "gcc -O -Wall -Werror" on i686-pc-linux-gnu.

=====================================================
int F0 (int);
int F1 (int t) { return F0(t); }
int F2 (int t) { return F0(t); }

extern int X[];
static inline int foo(int i)
{
  return X[i];
}

int bar(int* p)
{
  int i;

  while ( ({ if (foo(*p) && foo(*p)); p; }) );

  return i;
}
=====================================================

cc1: warnings being treated as errors
bug.c: In function 'bar':
bug.c:17: error: 'i' is used uninitialized in this function
bug.c:12: internal compiler error: Segmentation fault
Please submit a full bug report, [etc.]

Although the first functions aren't used in bar where the ICE happens,
they're needed to reproduce the ICE.

I can trace the bug back to at least 2007-05-13.

Janis, a regression hunt might be useful here.
Would you mind running one?


-- 
           Summary: [4.3 regression] ICE with uninitialized variable and -
                    Werror
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code, monitored
          Severity: normal
          Priority: P3
         Component: middle-end
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: reichelt at gcc dot gnu dot org


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug middle-end/34088] [4.3 regression] ICE with uninitialized variable and -Werror
  2007-11-13 22:35 [Bug middle-end/34088] New: [4.3 regression] ICE with uninitialized variable and -Werror reichelt at gcc dot gnu dot org
@ 2007-11-13 22:35 ` reichelt at gcc dot gnu dot org
  2007-11-13 22:41 ` pinskia at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2007-11-13 22:35 UTC (permalink / raw)
  To: gcc-bugs



-- 

reichelt at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  GCC build triplet|                            |i686-pc-linux-gnu
   GCC host triplet|                            |i686-pc-linux-gnu
 GCC target triplet|                            |i686-pc-linux-gnu
   Target Milestone|---                         |4.3.0
            Version|unknown                     |4.3.0


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug middle-end/34088] [4.3 regression] ICE with uninitialized variable and -Werror
  2007-11-13 22:35 [Bug middle-end/34088] New: [4.3 regression] ICE with uninitialized variable and -Werror reichelt at gcc dot gnu dot org
  2007-11-13 22:35 ` [Bug middle-end/34088] " reichelt at gcc dot gnu dot org
@ 2007-11-13 22:41 ` pinskia at gcc dot gnu dot org
  2007-11-14  1:03 ` janis at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-11-13 22:41 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from pinskia at gcc dot gnu dot org  2007-11-13 22:41 -------
I think this showed up when may_alias became a TODO.

Confirmed.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |pinskia at gcc dot gnu dot
                   |                            |org
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
  GCC build triplet|i686-pc-linux-gnu           |
   GCC host triplet|i686-pc-linux-gnu           |
 GCC target triplet|i686-pc-linux-gnu           |
   Last reconfirmed|0000-00-00 00:00:00         |2007-11-13 22:41:26
               date|                            |


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug middle-end/34088] [4.3 regression] ICE with uninitialized variable and -Werror
  2007-11-13 22:35 [Bug middle-end/34088] New: [4.3 regression] ICE with uninitialized variable and -Werror reichelt at gcc dot gnu dot org
  2007-11-13 22:35 ` [Bug middle-end/34088] " reichelt at gcc dot gnu dot org
  2007-11-13 22:41 ` pinskia at gcc dot gnu dot org
@ 2007-11-14  1:03 ` janis at gcc dot gnu dot org
  2007-11-14  9:56 ` jakub at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: janis at gcc dot gnu dot org @ 2007-11-14  1:03 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from janis at gcc dot gnu dot org  2007-11-14 01:02 -------
The ICE also occurs on powerpc-linux, where a regression hunt identified this
patch:

    http://gcc.gnu.org/viewcvs?view=rev&rev=120373

    r120373 | hubicka | 2007-01-03 01:12:56 +0000 (Wed, 03 Jan 2007)


-- 


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug middle-end/34088] [4.3 regression] ICE with uninitialized variable and -Werror
  2007-11-13 22:35 [Bug middle-end/34088] New: [4.3 regression] ICE with uninitialized variable and -Werror reichelt at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2007-11-14  1:03 ` janis at gcc dot gnu dot org
@ 2007-11-14  9:56 ` jakub at gcc dot gnu dot org
  2007-11-14 19:33 ` jakub at gcc dot gnu dot org
  2007-11-14 19:34 ` jakub at gcc dot gnu dot org
  5 siblings, 0 replies; 7+ messages in thread
From: jakub at gcc dot gnu dot org @ 2007-11-14  9:56 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from jakub at gcc dot gnu dot org  2007-11-14 09:55 -------
Testing a fix.


-- 

jakub at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |jakub at gcc dot gnu dot org
                   |dot org                     |
             Status|NEW                         |ASSIGNED
   Last reconfirmed|2007-11-13 22:41:26         |2007-11-14 09:55:56
               date|                            |


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug middle-end/34088] [4.3 regression] ICE with uninitialized variable and -Werror
  2007-11-13 22:35 [Bug middle-end/34088] New: [4.3 regression] ICE with uninitialized variable and -Werror reichelt at gcc dot gnu dot org
                   ` (3 preceding siblings ...)
  2007-11-14  9:56 ` jakub at gcc dot gnu dot org
@ 2007-11-14 19:33 ` jakub at gcc dot gnu dot org
  2007-11-14 19:34 ` jakub at gcc dot gnu dot org
  5 siblings, 0 replies; 7+ messages in thread
From: jakub at gcc dot gnu dot org @ 2007-11-14 19:33 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from jakub at gcc dot gnu dot org  2007-11-14 19:32 -------
Subject: Bug 34088

Author: jakub
Date: Wed Nov 14 19:32:45 2007
New Revision: 130187

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=130187
Log:
        PR middle-end/34088
        * tree-ssa.c (delete_tree_ssa): Don't call fini_ssa_operands if
        init_ssa_operands has not been called for cfun.

        * gcc.dg/pr34088.c: New test.

Added:
    trunk/gcc/testsuite/gcc.dg/pr34088.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/tree-ssa.c


-- 


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug middle-end/34088] [4.3 regression] ICE with uninitialized variable and -Werror
  2007-11-13 22:35 [Bug middle-end/34088] New: [4.3 regression] ICE with uninitialized variable and -Werror reichelt at gcc dot gnu dot org
                   ` (4 preceding siblings ...)
  2007-11-14 19:33 ` jakub at gcc dot gnu dot org
@ 2007-11-14 19:34 ` jakub at gcc dot gnu dot org
  5 siblings, 0 replies; 7+ messages in thread
From: jakub at gcc dot gnu dot org @ 2007-11-14 19:34 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from jakub at gcc dot gnu dot org  2007-11-14 19:33 -------
Fixed.


-- 

jakub at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2007-11-14 19:34 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-11-13 22:35 [Bug middle-end/34088] New: [4.3 regression] ICE with uninitialized variable and -Werror reichelt at gcc dot gnu dot org
2007-11-13 22:35 ` [Bug middle-end/34088] " reichelt at gcc dot gnu dot org
2007-11-13 22:41 ` pinskia at gcc dot gnu dot org
2007-11-14  1:03 ` janis at gcc dot gnu dot org
2007-11-14  9:56 ` jakub at gcc dot gnu dot org
2007-11-14 19:33 ` jakub at gcc dot gnu dot org
2007-11-14 19:34 ` jakub at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).