public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug ipa/60518] New: [4.9 Regression] ICE: in verify_loop_structure, at cfgloop.c:1647
@ 2014-03-13 19:12 trippels at gcc dot gnu.org
2014-03-13 19:44 ` [Bug ipa/60518] " trippels at gcc dot gnu.org
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: trippels at gcc dot gnu.org @ 2014-03-13 19:12 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60518
Bug ID: 60518
Summary: [4.9 Regression] ICE: in verify_loop_structure, at
cfgloop.c:1647
Product: gcc
Version: 4.9.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: ipa
Assignee: unassigned at gcc dot gnu.org
Reporter: trippels at gcc dot gnu.org
(This happens without any .gcda file)
markus@x4 tmp % cat test.ii
int a;
int fn1 () { return a == ',' || a == ';'; }
void fn2 ()
{
do
while (fn1 ())
;
while (1);
}
markus@x4 tmp % c++ -c -fprofile-use -march=amdfam10 -std=gnu++0x -Os test.ii
test.ii:1:0: warning: -fprefetch-loop-arrays is not supported with -Os
int a;
^
test.ii: In function ‘fn2()’:
test.ii:10:1: error: loop 1’s latch does not have an edge to its header
}
^
test.ii:10:1: internal compiler error: in verify_loop_structure, at
cfgloop.c:1647
0x81c749 verify_loop_structure()
../../gcc/gcc/cfgloop.c:1647
0xa27d3a loop_optimizer_init(unsigned int)
../../gcc/gcc/loop-init.c:111
0x9ddf29 estimate_function_body_sizes
../../gcc/gcc/ipa-inline-analysis.c:2436
0x9e0e21 compute_inline_parameters(cgraph_node*, bool)
../../gcc/gcc/ipa-inline-analysis.c:2860
0x9e1130 inline_analyze_function
../../gcc/gcc/ipa-inline-analysis.c:3853
0x9e12b7 inline_generate_summary()
../../gcc/gcc/ipa-inline-analysis.c:3904
0xaa8e36 execute_ipa_summary_passes(ipa_opt_pass_d*)
../../gcc/gcc/passes.c:2027
0x839b28 ipa_passes
../../gcc/gcc/cgraphunit.c:2070
0x839b28 compile()
../../gcc/gcc/cgraphunit.c:2174
0x839df4 finalize_compilation_unit()
../../gcc/gcc/cgraphunit.c:2329
0x63378e cp_write_global_declarations()
../../gcc/gcc/cp/decl2.c:4610
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.
The warning looks bogus, too.
>From gcc-bugs-return-446225-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Thu Mar 13 19:12:47 2014
Return-Path: <gcc-bugs-return-446225-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 5332 invoked by alias); 13 Mar 2014 19:12:47 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 5297 invoked by uid 48); 13 Mar 2014 19:12:43 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/59779] [4.9 Regression] FAIL: gcc.dg/autopar/outer-1.c scan-tree-dump-times parloops "parallelizing outer loop"
Date: Thu, 13 Mar 2014 19:12:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub at gcc dot gnu.org
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: jakub at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 4.9.0
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_status resolution
Message-ID: <bug-59779-4-RKYK5DG43Z@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-59779-4@http.gcc.gnu.org/bugzilla/>
References: <bug-59779-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2014-03/txt/msg01094.txt.bz2
Content-length: 435
http://gcc.gnu.org/bugzilla/show_bug.cgi?idY779
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution|--- |FIXED
--- Comment #8 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Should be fixed now.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug ipa/60518] [4.9 Regression] ICE: in verify_loop_structure, at cfgloop.c:1647
2014-03-13 19:12 [Bug ipa/60518] New: [4.9 Regression] ICE: in verify_loop_structure, at cfgloop.c:1647 trippels at gcc dot gnu.org
@ 2014-03-13 19:44 ` trippels at gcc dot gnu.org
2014-03-14 9:18 ` rguenth at gcc dot gnu.org
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: trippels at gcc dot gnu.org @ 2014-03-13 19:44 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60518
Markus Trippelsdorf <trippels at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |amker at gcc dot gnu.org
--- Comment #1 from Markus Trippelsdorf <trippels at gcc dot gnu.org> ---
Started with r208165.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug ipa/60518] [4.9 Regression] ICE: in verify_loop_structure, at cfgloop.c:1647
2014-03-13 19:12 [Bug ipa/60518] New: [4.9 Regression] ICE: in verify_loop_structure, at cfgloop.c:1647 trippels at gcc dot gnu.org
2014-03-13 19:44 ` [Bug ipa/60518] " trippels at gcc dot gnu.org
@ 2014-03-14 9:18 ` rguenth at gcc dot gnu.org
2014-03-14 12:55 ` rguenth at gcc dot gnu.org
2014-03-14 12:55 ` rguenth at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: rguenth at gcc dot gnu.org @ 2014-03-14 9:18 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60518
--- Comment #3 from Richard Biener <rguenth at gcc dot gnu.org> ---
Ok, so it's branch_prob()s call of split_block that splits the common latch of
loops 1 and 2
<bb 3>: (header loop 1)
<bb 4>: (header loop 2, latch loop 2 and 1)
_2 = fn1 ();
if (_2 != 0)
goto <bb 4>;
else
goto <bb 3>;
the cfghook adjusts the latch of loop 2 properly (bb4s loop father is 2)
but fails to notice that bb4 is also the latch of loop 1 ... so this
CFG hook loop handling only handles this correctly if we have simple
latches (because there the latch always belongs to its loop).
Fix:
Index: gcc/cfghooks.c
===================================================================
--- gcc/cfghooks.c (revision 208536)
+++ gcc/cfghooks.c (working copy)
@@ -510,9 +510,13 @@ split_block (basic_block bb, void *i)
if (current_loops != NULL)
{
+ edge_iterator ei;
+ edge e;
add_bb_to_loop (new_bb, bb->loop_father);
- if (bb->loop_father->latch == bb)
- bb->loop_father->latch = new_bb;
+ /* Identify all loops bb may have been the latch of and adjust them. */
+ FOR_EACH_EDGE (e, ei, new_bb->succs)
+ if (e->dest->loop_father->latch == bb)
+ e->dest->loop_father->latch = new_bb;
}
res = make_single_succ_edge (bb, new_bb, EDGE_FALLTHRU);
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug ipa/60518] [4.9 Regression] ICE: in verify_loop_structure, at cfgloop.c:1647
2014-03-13 19:12 [Bug ipa/60518] New: [4.9 Regression] ICE: in verify_loop_structure, at cfgloop.c:1647 trippels at gcc dot gnu.org
` (2 preceding siblings ...)
2014-03-14 12:55 ` rguenth at gcc dot gnu.org
@ 2014-03-14 12:55 ` rguenth at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: rguenth at gcc dot gnu.org @ 2014-03-14 12:55 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60518
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |ice-checking,
| |ice-on-valid-code
Priority|P3 |P1
Status|ASSIGNED |RESOLVED
Resolution|--- |FIXED
--- Comment #5 from Richard Biener <rguenth at gcc dot gnu.org> ---
Fixed.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug ipa/60518] [4.9 Regression] ICE: in verify_loop_structure, at cfgloop.c:1647
2014-03-13 19:12 [Bug ipa/60518] New: [4.9 Regression] ICE: in verify_loop_structure, at cfgloop.c:1647 trippels at gcc dot gnu.org
2014-03-13 19:44 ` [Bug ipa/60518] " trippels at gcc dot gnu.org
2014-03-14 9:18 ` rguenth at gcc dot gnu.org
@ 2014-03-14 12:55 ` rguenth at gcc dot gnu.org
2014-03-14 12:55 ` rguenth at gcc dot gnu.org
3 siblings, 0 replies; 5+ messages in thread
From: rguenth at gcc dot gnu.org @ 2014-03-14 12:55 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60518
--- Comment #4 from Richard Biener <rguenth at gcc dot gnu.org> ---
Author: rguenth
Date: Fri Mar 14 12:54:25 2014
New Revision: 208567
URL: http://gcc.gnu.org/viewcvs?rev=208567&root=gcc&view=rev
Log:
2014-03-14 Richard Biener <rguenther@suse.de>
PR middle-end/60518
* cfghooks.c (split_block): Properly adjust all loops the
block was a latch of.
* g++.dg/pr60518.C: New testcase.
Added:
trunk/gcc/testsuite/g++.dg/pr60518.C
Modified:
trunk/gcc/ChangeLog
trunk/gcc/cfghooks.c
trunk/gcc/testsuite/ChangeLog
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2014-03-14 12:55 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-03-13 19:12 [Bug ipa/60518] New: [4.9 Regression] ICE: in verify_loop_structure, at cfgloop.c:1647 trippels at gcc dot gnu.org
2014-03-13 19:44 ` [Bug ipa/60518] " trippels at gcc dot gnu.org
2014-03-14 9:18 ` rguenth at gcc dot gnu.org
2014-03-14 12:55 ` rguenth at gcc dot gnu.org
2014-03-14 12:55 ` 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).