public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/58957] New: compilation hangs at -O3 on x86_64-linux-gnu (both 32-bit and 64-bit modes)
@ 2013-11-01  5:25 su at cs dot ucdavis.edu
  2013-11-04 14:36 ` [Bug tree-optimization/58957] [4.8 Regression] compilation slow " rguenth at gcc dot gnu.org
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: su at cs dot ucdavis.edu @ 2013-11-01  5:25 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 58957
           Summary: compilation hangs at -O3 on x86_64-linux-gnu (both
                    32-bit and 64-bit modes)
           Product: gcc
           Version: 4.8.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: su at cs dot ucdavis.edu

The following code causes gcc 4.8.2 (as well as gcc 4.8.0 and gcc 4.8.1) to
hang at -O3 on x86_64-linux-gnu in both 32-bit and 64-bit modes. 

It doesn't affect gcc trunk, 4.7.x, and 4.6.x. 


$ gcc-trunk -O3 small.c  
$ gcc-4.6 -O3 small.c
$ gcc-4.7 -O3 small.c
$ 
$ gcc-4.8 -O3 small.c
^C
$
$ gcc-4.8 -v
Using built-in specs.
COLLECT_GCC=gcc-4.8
COLLECT_LTO_WRAPPER=/usr/local/gcc-4.8.2/bin/../libexec/gcc/x86_64-unknown-linux-gnu/4.8.2/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: ../gcc-4.8.2/configure
--enable-languages=c,c++,objc,obj-c++,fortran,lto --enable-checking=release
--with-gmp=/home/su/software/local/gcc-4.8.2
--with-mpfr=/home/su/software/local/gcc-4.8.2
--with-mpc=/home/su/software/local/gcc-4.8.2
--with-cloog=/home/su/software/local/gcc-4.8.2
--prefix=/home/su/software/local/gcc-4.8.2
Thread model: posix
gcc version 4.8.2 (GCC) 
$ 


----------------------------------


void __assert_fail () __attribute__ ((__noreturn__));

int a[10], b, c, d, *e, **f = &e, g, i, *j; 
unsigned int h;

int *
foo ()
{
  for (c = 0; c < 10; c++)
    for (i = 1; i >= 0; i--)
      for (d = 0; d < 10; d++)
    {
      j = &a[d];
      j >= &a[0] && j <= &a[9] ? (void) 0 : __assert_fail ();
    }
  return &b;
}

int
main ()
{
  for (g = 3; g < 10; g++)
    for (; h < 10; h++)
      *f = foo ();
  return 0;
}


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

end of thread, other threads:[~2015-06-23  8:44 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-11-01  5:25 [Bug tree-optimization/58957] New: compilation hangs at -O3 on x86_64-linux-gnu (both 32-bit and 64-bit modes) su at cs dot ucdavis.edu
2013-11-04 14:36 ` [Bug tree-optimization/58957] [4.8 Regression] compilation slow " rguenth at gcc dot gnu.org
2013-11-04 23:21 ` su at cs dot ucdavis.edu
2014-12-10 12:48 ` rguenth at gcc dot gnu.org
2014-12-19 13:42 ` jakub at gcc dot gnu.org
2015-06-23  8:46 ` rguenth at gcc dot gnu.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).