public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/21380] New: ICE compiling with -O
@ 2005-05-04 14:31 trt at acm dot org
  2005-05-04 14:55 ` [Bug tree-optimization/21380] [4.0 Regression] " pinskia at gcc dot gnu dot org
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: trt at acm dot org @ 2005-05-04 14:31 UTC (permalink / raw)
  To: gcc-bugs

When compiling the program below, gcc 4.0.0 dies with an ICE.
This also happens with gcc version 4.0.1 20050430 (prerelease)

gcc400 -v
Using built-in specs.
Target: i686-pc-linux-gnu
Configured with: ../gcc-4.0.0/configure --prefix=/opt/gcc400
Thread model: posix
gcc version 4.0.0


command line:
gcc400 -O -c foo.c

program:

void bar (void);
                                                                                
void
foo (int *diff)
{
  double deltay = 0.0;
  int Stangent = 0;
  int mindiff;
  int Sflipped = 0;
  int i;
  int Sturn, Snofit;
                                                                                
  Sturn = 1;
  if (Sturn)
    Stangent = 1;
  if (Sturn)
    {
      Sflipped = 0;
      Snofit = 1;
      while (Snofit)
        {
          Snofit = 0;
          mindiff = 0;
          for (i = 0; i < 4; i++)
            mindiff = diff[i];
          while (!Snofit && (mindiff < 0.0))
            {
              deltay = (Stangent ? deltay : 0.0);
              if (deltay < 0.0)
                Snofit = 1;
              for (i = 0; i < 4; i++)
                {
                }
            }
          if (Snofit)
            if (Sflipped)
              break;
        }
      if (Snofit)
        bar ();
    }
}

-- 
           Summary: ICE compiling with -O
           Product: gcc
           Version: 4.0.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: trt at acm dot org
                CC: gcc-bugs at gcc dot gnu dot org


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


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

* [Bug tree-optimization/21380] [4.0 Regression] ICE compiling with -O
  2005-05-04 14:31 [Bug c/21380] New: ICE compiling with -O trt at acm dot org
@ 2005-05-04 14:55 ` pinskia at gcc dot gnu dot org
  2005-05-04 15:10 ` law at redhat dot com
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-05-04 14:55 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-05-04 14:55 -------
Confirmed, backtrace:
#0  0x00112d98 in thread_block (bb=0x41485570) at /Users/pinskia/src/gcc-4.0/gcc/gcc/tree-ssa-
threadupdate.c:503
#1  0x00112eb8 in thread_through_all_blocks () at /Users/pinskia/src/gcc-4.0/gcc/gcc/tree-ssa-
threadupdate.c:565
#2  0x000ef914 in tree_ssa_dominator_optimize () at /Users/pinskia/src/gcc-4.0/gcc/gcc/tree-ssa-
dom.c:437


-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |pinskia at gcc dot gnu dot
                   |                            |org, law at gcc dot gnu dot
                   |                            |org
             Status|UNCONFIRMED                 |NEW
          Component|c                           |tree-optimization
     Ever Confirmed|                            |1
           Keywords|                            |ice-on-valid-code
   Last reconfirmed|0000-00-00 00:00:00         |2005-05-04 14:55:44
               date|                            |
            Summary|ICE compiling with -O       |[4.0 Regression] ICE
                   |                            |compiling with -O
   Target Milestone|---                         |4.0.1


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


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

* [Bug tree-optimization/21380] [4.0 Regression] ICE compiling with -O
  2005-05-04 14:31 [Bug c/21380] New: ICE compiling with -O trt at acm dot org
  2005-05-04 14:55 ` [Bug tree-optimization/21380] [4.0 Regression] " pinskia at gcc dot gnu dot org
@ 2005-05-04 15:10 ` law at redhat dot com
  2005-05-04 17:18 ` giovannibajo at libero dot it
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: law at redhat dot com @ 2005-05-04 15:10 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From law at redhat dot com  2005-05-04 15:10 -------
Subject: Re:  [4.0 Regression] ICE compiling
	with -O

On Wed, 2005-05-04 at 14:56 +0000, pinskia at gcc dot gnu dot org wrote:

If you want, go ahead and assign this to me...

Jeff



-- 


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


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

* [Bug tree-optimization/21380] [4.0 Regression] ICE compiling with -O
  2005-05-04 14:31 [Bug c/21380] New: ICE compiling with -O trt at acm dot org
  2005-05-04 14:55 ` [Bug tree-optimization/21380] [4.0 Regression] " pinskia at gcc dot gnu dot org
  2005-05-04 15:10 ` law at redhat dot com
@ 2005-05-04 17:18 ` giovannibajo at libero dot it
  2005-05-05 18:01 ` law at redhat dot com
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: giovannibajo at libero dot it @ 2005-05-04 17:18 UTC (permalink / raw)
  To: gcc-bugs



-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |law at gcc dot gnu dot org
                   |dot org                     |
             Status|NEW                         |ASSIGNED


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


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

* [Bug tree-optimization/21380] [4.0 Regression] ICE compiling with -O
  2005-05-04 14:31 [Bug c/21380] New: ICE compiling with -O trt at acm dot org
                   ` (2 preceding siblings ...)
  2005-05-04 17:18 ` giovannibajo at libero dot it
@ 2005-05-05 18:01 ` law at redhat dot com
  2005-05-06  3:04 ` cvs-commit at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: law at redhat dot com @ 2005-05-05 18:01 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From law at redhat dot com  2005-05-05 18:01 -------
I know what's causing this and I'm testing a fix now.

-- 


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


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

* [Bug tree-optimization/21380] [4.0 Regression] ICE compiling with -O
  2005-05-04 14:31 [Bug c/21380] New: ICE compiling with -O trt at acm dot org
                   ` (3 preceding siblings ...)
  2005-05-05 18:01 ` law at redhat dot com
@ 2005-05-06  3:04 ` cvs-commit at gcc dot gnu dot org
  2005-05-06 16:44 ` cvs-commit at gcc dot gnu dot org
  2005-05-06 16:44 ` law at redhat dot com
  6 siblings, 0 replies; 8+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2005-05-06  3:04 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From cvs-commit at gcc dot gnu dot org  2005-05-06 03:04 -------
Subject: Bug 21380

CVSROOT:	/cvs/gcc
Module name:	gcc
Branch: 	gcc-4_0-branch
Changes by:	law@gcc.gnu.org	2005-05-06 03:04:16

Modified files:
	gcc            : ChangeLog tree-ssa-threadupdate.c 
	gcc/testsuite  : ChangeLog 
Added files:
	gcc/testsuite/gcc.c-torture/compile: pr21380.c 

Log message:
	PR tree-optimization/21380
	* tree-ssa-threadupdate.c (thread_through_all_blocks): Do not
	thread through a block with no preds.
	
	* gcc.c-torture/compile/pr21380.c: New test.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=2.7592.2.221&r2=2.7592.2.222
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/tree-ssa-threadupdate.c.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=2.20&r2=2.20.10.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=1.5084.2.161&r2=1.5084.2.162
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.c-torture/compile/pr21380.c.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=NONE&r2=1.1.2.1



-- 


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


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

* [Bug tree-optimization/21380] [4.0 Regression] ICE compiling with -O
  2005-05-04 14:31 [Bug c/21380] New: ICE compiling with -O trt at acm dot org
                   ` (4 preceding siblings ...)
  2005-05-06  3:04 ` cvs-commit at gcc dot gnu dot org
@ 2005-05-06 16:44 ` cvs-commit at gcc dot gnu dot org
  2005-05-06 16:44 ` law at redhat dot com
  6 siblings, 0 replies; 8+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2005-05-06 16:44 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From cvs-commit at gcc dot gnu dot org  2005-05-06 16:44 -------
Subject: Bug 21380

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	law@gcc.gnu.org	2005-05-06 16:43:58

Modified files:
	gcc            : ChangeLog tree-ssa-threadupdate.c 
	gcc/testsuite  : ChangeLog 
Added files:
	gcc/testsuite/gcc.c-torture/compile: pr21380.c 

Log message:
	PR tree-optimization/21380
	* tree-ssa-threadupdate.c (thread_through_all_blocks): Do not
	thread through a block with no preds.
	
	* gcc.c-torture/compile/pr21380.c: New test.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.8625&r2=2.8626
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/tree-ssa-threadupdate.c.diff?cvsroot=gcc&r1=2.24&r2=2.25
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.5443&r2=1.5444
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.c-torture/compile/pr21380.c.diff?cvsroot=gcc&r1=1.1&r2=1.2



-- 


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


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

* [Bug tree-optimization/21380] [4.0 Regression] ICE compiling with -O
  2005-05-04 14:31 [Bug c/21380] New: ICE compiling with -O trt at acm dot org
                   ` (5 preceding siblings ...)
  2005-05-06 16:44 ` cvs-commit at gcc dot gnu dot org
@ 2005-05-06 16:44 ` law at redhat dot com
  6 siblings, 0 replies; 8+ messages in thread
From: law at redhat dot com @ 2005-05-06 16:44 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From law at redhat dot com  2005-05-06 16:44 -------
Fixed.

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


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


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

end of thread, other threads:[~2005-05-06 16:44 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-05-04 14:31 [Bug c/21380] New: ICE compiling with -O trt at acm dot org
2005-05-04 14:55 ` [Bug tree-optimization/21380] [4.0 Regression] " pinskia at gcc dot gnu dot org
2005-05-04 15:10 ` law at redhat dot com
2005-05-04 17:18 ` giovannibajo at libero dot it
2005-05-05 18:01 ` law at redhat dot com
2005-05-06  3:04 ` cvs-commit at gcc dot gnu dot org
2005-05-06 16:44 ` cvs-commit at gcc dot gnu dot org
2005-05-06 16:44 ` law at redhat dot com

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).