public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/46560] New: libstdc++ execute FAILs with -flto
@ 2010-11-19 13:11 rguenth at gcc dot gnu.org
2010-11-26 14:06 ` [Bug tree-optimization/46560] " rguenth at gcc dot gnu.org
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: rguenth at gcc dot gnu.org @ 2010-11-19 13:11 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46560
Summary: libstdc++ execute FAILs with -flto
Product: gcc
Version: 4.6.0
Status: UNCONFIRMED
Keywords: lto, wrong-code
Severity: normal
Priority: P3
Component: tree-optimization
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: rguenth@gcc.gnu.org
make -k check-target-libstdc++-v3 RUNTESTFLAGS="--target_board=unix/-flto"
yields
Running target unix/-flto
FAIL: 21_strings/basic_string/insert/char/1.cc execution test
FAIL: 21_strings/basic_string/insert/wchar_t/1.cc execution test
FAIL: 23_containers/deque/capacity/29134-2.cc execution test
FAIL: 23_containers/deque/cons/2.cc execution test
FAIL: 23_containers/forward_list/requirements/exception/basic.cc execution test
FAIL: 23_containers/list/modifiers/3.cc execution test
FAIL: 23_containers/list/modifiers/insert/25288.cc execution test
FAIL: 23_containers/list/operations/5.cc execution test
FAIL: 23_containers/list/requirements/exception/basic.cc execution test
FAIL: 23_containers/multimap/requirements/exception/basic.cc execution test
FAIL: 23_containers/multiset/requirements/exception/basic.cc execution test
FAIL: 23_containers/unordered_map/dr761.cc execution test
FAIL: 23_containers/unordered_map/requirements/exception/basic.cc execution
test
FAIL: 23_containers/unordered_multimap/requirements/exception/basic.cc
execution
test
FAIL: 23_containers/unordered_multiset/requirements/exception/basic.cc
execution
test
FAIL: 23_containers/unordered_set/requirements/exception/basic.cc execution
test
FAIL: 23_containers/vector/bool/modifiers/insert/31370.cc execution test
FAIL: 23_containers/vector/capacity/2.cc execution test
FAIL: 23_containers/vector/ext_pointer/modifiers/insert.cc execution test
FAIL: 30_threads/promise/members/set_exception2.cc execution test
FAIL: 30_threads/promise/members/set_value2.cc execution test
FAIL: ext/bitmap_allocator/check_allocate_max_size.cc execution test
FAIL: ext/pb_ds/regression/hash_data_map_rand.cc execution test
FAIL: ext/pb_ds/regression/hash_no_data_map_rand.cc execution test
FAIL: ext/pb_ds/regression/list_update_data_map_rand.cc execution test
FAIL: ext/pb_ds/regression/list_update_no_data_map_rand.cc execution test
FAIL: ext/pb_ds/regression/priority_queue_rand.cc execution test
FAIL: ext/pb_ds/regression/tree_data_map_rand.cc execution test
FAIL: ext/pb_ds/regression/tree_no_data_map_rand.cc execution test
FAIL: ext/pb_ds/regression/trie_data_map_rand.cc execution test
FAIL: ext/pb_ds/regression/trie_no_data_map_rand.cc execution test
FAIL: ext/throw_allocator/check_deallocate_null.cc execution test
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug tree-optimization/46560] libstdc++ execute FAILs with -flto
2010-11-19 13:11 [Bug tree-optimization/46560] New: libstdc++ execute FAILs with -flto rguenth at gcc dot gnu.org
@ 2010-11-26 14:06 ` rguenth at gcc dot gnu.org
2010-11-26 15:08 ` rguenth at gcc dot gnu.org
2010-11-26 15:09 ` rguenth at gcc dot gnu.org
2 siblings, 0 replies; 4+ messages in thread
From: rguenth at gcc dot gnu.org @ 2010-11-26 14:06 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46560
--- Comment #1 from Richard Guenther <rguenth at gcc dot gnu.org> 2010-11-26 14:02:28 UTC ---
FAIL: 21_strings/basic_string/insert/char/1.cc execution test
is because we optimize away EH code. A stripped-down testcase shows instead
of
Eh tree:
3 cleanup land:{3,<L16>}
6 cleanup
7 cleanup land:{5,<L14>}
11 try land:{7,<L11>} catch:{struct out_of_range},{}
8 try land:{6,<L8>} catch:{struct out_of_range},{}
Eh tree:
3 cleanup land:{3,<L14>}
6 cleanup
7 cleanup land:{5,<L12>}
8 try land:{6,<L6>} catch:{(void *) &_ZTISt12out_of_range},{}
it's already broken at .044i.inline - one insert call doesn't have eh info.
I suspect that nothrow discovery is broken somehow.
Function found to be nothrow: insert
insert/19(-1) @0x7ffff5d1fdc0 (asm: _ZNSs6insertEmRKSsmm) (inline copy in
test01/5) (clone of insert/0) availability:local analyzed 29 time, 20 benefit
25 size, 12 benefit reachable local finalized inlinable
called by: test01/5 (1.00 per call) (inlined)
calls: __throw_out_of_range/8 insert/7 (1.00 per call)
References:
Refering this function:
but we have before propagate nothrow:
insert/19(-1) @0x7ffff5d1fdc0 (asm: _ZNSs6insertEmRKSsmm) (inline copy in
test01/5) (clone of insert/0) availability:local analyzed 29 time, 20 benefit
25 size, 12 benefit reachable local finalized inlinable
called by: test01/5 (1.00 per call) (inlined)
calls: __throw_out_of_range/8 insert/7 (1.00 per call)
References:
Refering this function:
__throw_out_of_range/8(-1) @0x7ffff5d1ec60 (asm: _ZSt20__throw_out_of_rangePKc)
availability:not_available reachable
called by: insert/19 insert/0 (can throw external)
calls:
References:
Refering this function:
insert/0(-1) @0x7ffff5d1e160 (asm: _ZNSs6insertEmRKSsmm) availability:available
analyzed 29 time, 20 benefit 25 size, 12 benefit reachable finalized inlinable
called by: test01/5
calls: insert/7 (1.00 per call) (can throw external) __throw_out_of_range/8
(can throw external)
References:
Refering this function:
so __throw_out_of_range/8 can throw.
During propagation visiting insert/19 we visit the edge to
__throw_out_of_range.
The edge has e->can_throw_external == 0, probably because:
edge->can_throw_external
= call_stmt ? stmt_can_throw_external (call_stmt) : false;
in cgraph.c which isn't exactly a conservative assumption.
(gdb) p e
$13 = (struct cgraph_edge *) 0x7ffff5d20548
(gdb) p e->caller
$14 = (struct cgraph_node *) 0x7ffff5d1fdc0
(gdb) p e->callee
$15 = (struct cgraph_node *) 0x7ffff5d1ec60
which is an inline clone edge. I suppose cgraph_clone_edge should clone
the flags that depend on call_stmt as well.
That fixes it.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug tree-optimization/46560] libstdc++ execute FAILs with -flto
2010-11-19 13:11 [Bug tree-optimization/46560] New: libstdc++ execute FAILs with -flto rguenth at gcc dot gnu.org
2010-11-26 14:06 ` [Bug tree-optimization/46560] " rguenth at gcc dot gnu.org
@ 2010-11-26 15:08 ` rguenth at gcc dot gnu.org
2010-11-26 15:09 ` rguenth at gcc dot gnu.org
2 siblings, 0 replies; 4+ messages in thread
From: rguenth at gcc dot gnu.org @ 2010-11-26 15:08 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46560
--- Comment #2 from Richard Guenther <rguenth at gcc dot gnu.org> 2010-11-26 14:39:31 UTC ---
Author: rguenth
Date: Fri Nov 26 14:39:25 2010
New Revision: 167178
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=167178
Log:
2010-11-26 Richard Guenther <rguenther@suse.de>
PR lto/46560
* cgraph.c (cgraph_clone_edge): Clone call_stmt dependent
flags manually.
Modified:
trunk/gcc/ChangeLog
trunk/gcc/cgraph.c
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug tree-optimization/46560] libstdc++ execute FAILs with -flto
2010-11-19 13:11 [Bug tree-optimization/46560] New: libstdc++ execute FAILs with -flto rguenth at gcc dot gnu.org
2010-11-26 14:06 ` [Bug tree-optimization/46560] " rguenth at gcc dot gnu.org
2010-11-26 15:08 ` rguenth at gcc dot gnu.org
@ 2010-11-26 15:09 ` rguenth at gcc dot gnu.org
2 siblings, 0 replies; 4+ messages in thread
From: rguenth at gcc dot gnu.org @ 2010-11-26 15:09 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46560
Richard Guenther <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |FIXED
Target Milestone|--- |4.6.0
--- Comment #3 from Richard Guenther <rguenth at gcc dot gnu.org> 2010-11-26 14:40:22 UTC ---
All fixed. Yay.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2010-11-26 14:40 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-11-19 13:11 [Bug tree-optimization/46560] New: libstdc++ execute FAILs with -flto rguenth at gcc dot gnu.org
2010-11-26 14:06 ` [Bug tree-optimization/46560] " rguenth at gcc dot gnu.org
2010-11-26 15:08 ` rguenth at gcc dot gnu.org
2010-11-26 15:09 ` 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).