From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7957 invoked by alias); 2 Jan 2011 23:13:07 -0000 Received: (qmail 7946 invoked by uid 22791); 2 Jan 2011 23:13:06 -0000 X-SWARE-Spam-Status: No, hits=-2.9 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 02 Jan 2011 23:13:02 +0000 From: "hjl.tools at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug rtl-optimization/46755] ICE: in calc_dfs_tree, at dominance.c:395 with -O X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: rtl-optimization X-Bugzilla-Keywords: ice-on-valid-code, patch X-Bugzilla-Severity: normal X-Bugzilla-Who: hjl.tools at gmail dot com X-Bugzilla-Status: ASSIGNED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: steven at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Date: Sun, 02 Jan 2011 23:13:00 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2011-01/txt/msg00106.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46755 --- Comment #9 from H.J. Lu 2011-01-02 23:12:46 UTC --- (In reply to comment #8) > Not sure if this is still useful, but here's a fairly small failure-inducing > testcase for this bug for today's GCC. > > [regehr@gamow tmp437]$ current-gcc -O2 -c small.c > > small.c: In function 'func': > small.c:32:1: internal compiler error: in calc_dfs_tree, at dominance.c:395 > Please submit a full bug report, > with preprocessed source if appropriate. > See for instructions. > > [regehr@gamow tmp437]$ current-gcc -v > > Using built-in specs. > COLLECT_GCC=current-gcc > COLLECT_LTO_WRAPPER=/uusoc/exports/scratch/regehr/z/compiler-install/gcc-r168402-install/bin/../libexec/gcc/x86_64-unknown-linux-gnu/4.6.0/lto-wrapper > Target: x86_64-unknown-linux-gnu > Configured with: ../configure --with-libelf=/usr/local --enable-lto > --prefix=/home/regehr/z/compiler-install/gcc-r168402-install > --program-prefix=r168402- --enable-languages=c,c++ > Thread model: posix > gcc version 4.6.0 20110102 (experimental) (GCC) > > [regehr@gamow tmp437]$ cat small.c > > > static int > foo (int si1, short si2) > { > return ((si1 ^ si2) & ((si1 ^ (si1 ^ si2) & ~2147483647) - si2 ^ si2)) < > 0 ? si1 : si1 - si2; > } > > struct S0 > { > const unsigned f3:1; > const unsigned f8:1; > }; > struct S0 g_111 = { > 1 > }; > > struct S0 g_139 = { > 1 > }; > > unsigned long int g_22; > > void safe (int); > int func_42 (void); > > void func (void) > { > safe (foo (func_42 () != (g_139.f3 | g_111.f8), -1L)); > for (g_22 = 0; g_22; g_22 = 1) > { > } > } This is caused by revision 164431: http://gcc.gnu.org/ml/gcc-cvs/2010-09/msg00727.html