[Bug ipa/63270] [5 Regression] internal compiler error: in odr_types_equivalent_p, at ipa-devirt.c:1075
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63270 --- Comment #5 from marxin at gcc dot gnu.org --- Author: marxin Date: Mon Sep 22 09:39:20 2014 New Revision: 215451 URL: https://gcc.gnu.org/viewcvs?rev=215451root=gccview=rev Log: PR lto/63270 - new test * g++.dg/lto/pr63270_0.C: New test. * g++.dg/lto/pr63270_1.C: New test. Added: trunk/gcc/testsuite/g++.dg/lto/pr63270_0.C trunk/gcc/testsuite/g++.dg/lto/pr63270_1.C Modified: trunk/gcc/testsuite/ChangeLog
[Bug ipa/61462] [4.10 Regression] ICE in ipa-prop.c:2562 caused by missing edge gimple call stmt
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61462 --- Comment #1 from marxin at gcc dot gnu.org --- Author: marxin Date: Thu Jun 12 07:48:23 2014 New Revision: 211490 URL: http://gcc.gnu.org/viewcvs?rev=211490root=gccview=rev Log: PR ipa/61462 * ipa-prop.c (ipa_make_edge_direct_to_target): Check that gimple call statement is reachable. Modified: trunk/gcc/ChangeLog trunk/gcc/ipa-prop.c
[Bug tree-optimization/63583] [5 Regression] ICF does not check that the template strings are the same
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63583 --- Comment #2 from marxin at gcc dot gnu.org --- Author: marxin Date: Mon Oct 20 10:44:54 2014 New Revision: 216458 URL: https://gcc.gnu.org/viewcvs?rev=216458root=gccview=rev Log: PR ipa/63583 * ipa-icf-gimple.c (func_checker::compare_gimple_asm): Gimple tempate string is compared. * gcc.dg/ipa/pr63595.c: New test. Modified: trunk/gcc/ChangeLog trunk/gcc/ipa-icf-gimple.c trunk/gcc/testsuite/ChangeLog
[Bug ipa/63587] [5 Regression] ICE : tree check: expected var_decl, have result_decl in add_local_variables, at tree-inline.c:4112
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63587 --- Comment #5 from marxin at gcc dot gnu.org --- (In reply to rguent...@suse.de from comment #4) On Sun, 19 Oct 2014, mliska at suse dot cz wrote: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63587 --- Comment #2 from Martin Liška mliska at suse dot cz --- Following two functions are merged: static boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::type boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::make(ActorTLeftExprT, RightT) [with ActorT = boost::actor; LeftExprT = int; RightT = boost::log::attribute_actorint, boost::log::value_extractor, void, boost::actor; ValueT = int; boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::type = boost::actorboost::log::attribute_output_terminalboost::actorint, boost::log::to_log_fun ] (struct actor left, struct attribute_actor right) static boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::type boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::make(ActorTLeftExprT, RightT) [with ActorT = boost::actor; LeftExprT = int; RightT = boost::log::attribute_actor{anonymous}::my_class, boost::log::value_extractor, void, boost::actor; ValueT = int; boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::type = boost::actorboost::log::attribute_output_terminalboost::actorint, boost::log::to_log_fun ] (struct actor left, struct attribute_actor right) with following body: { struct type D.3826; struct to_log_fun D.3825; struct attribute_name D.3824; int SR.9; struct actor left; bb 2: left = left; SR.9_4 = MEM[(struct attribute_terminal *)right_2(D)]; MEM[(struct attribute_name *)D.3824] = SR.9_4; boost::log::attribute_output_terminalboost::actorint, boost::log::to_log_fun::attribute_output_terminalint (D.3826, left, D.3824, D.3825, 0); D.3826 ={v} {CLOBBER}; return; } As I was debugging ao_ref_alias_sets, there's MEM_REF where we have different template arguments: attribute_actorint,... vs. attribute_actor{anonymous}::my_class, What do you think Richard about these record_types from alias set perspective: (gdb) p debug_tree(t1) mem_ref 0x76ab4000 type integer_type 0x76c33690 int public type_6 SI size integer_cst 0x76c51048 constant 32 unit size integer_cst 0x76c51060 constant 4 align 32 symtab 0 alias set 4 canonical type 0x76c33690 precision 32 min integer_cst 0x76c51000 -2147483648 max integer_cst 0x76c51018 2147483647 pointer_to_this pointer_type 0x76c55738 arg 0 ssa_name 0x76aae678 type reference_type 0x76e20d20 type record_type 0x76de7dc8 attribute_actor unsigned DI size integer_cst 0x76c2fdf8 constant 64 unit size integer_cst 0x76c2fe10 constant 8 align 64 symtab 0 alias set 7 canonical type 0x76e20d20 visited var parm_decl 0x76e1eb00 rightdef_stmt GIMPLE_NOP version 2 ptr-info 0x76a7e3d8 arg 1 integer_cst 0x76a4ee28 type pointer_type 0x76dbfa80 constant 0 $1 = void (gdb) p debug_tree(t2) mem_ref 0x76aa1ac8 type integer_type 0x76c33690 int public type_6 SI size integer_cst 0x76c51048 constant 32 unit size integer_cst 0x76c51060 constant 4 align 32 symtab 0 alias set 4 canonical type 0x76c33690 precision 32 min integer_cst 0x76c51000 -2147483648 max integer_cst 0x76c51018 2147483647 pointer_to_this pointer_type 0x76c55738 arg 0 ssa_name 0x76a77dc8 type reference_type 0x76e20540 type record_type 0x76ddd888 attribute_actor unsigned DI size integer_cst 0x76c2fdf8 constant 64 unit size integer_cst 0x76c2fe10 constant 8 align 64 symtab 0 alias set 7 canonical type 0x76e20540 visited var parm_decl 0x76e1ea00 rightdef_stmt GIMPLE_NOP version 2 ptr-info 0x76a7e300 arg 1 integer_cst 0x76a4ee28 type pointer_type 0x76dbfa80 constant 0 these types are called for alias_set comparison, with following record_types: (gdb) p debug_tree((tree_node*)0x76de7dc8) record_type 0x76de7dc8 attribute_actor needs-constructing type_5 type_6 SI size integer_cst 0x76c51048 type integer_type 0x76c33150 bitsizetype constant 32 unit size integer_cst 0x76c51060 type integer_type 0x76c330a8 sizetype constant 4 align 32 symtab 0 alias set 17 canonical type 0x76de7dc8 fields field_decl 0x76de4ed8 D.2798 type record_type 0x76dddb28 actor needs-constructing type_5 type_6 SI size integer_cst 0x76c51048 32 unit size integer_cst 0x76c51060
[Bug ipa/63587] [5 Regression] ICE : tree check: expected var_decl, have result_decl in add_local_variables, at tree-inline.c:4112
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63587 --- Comment #6 from marxin at gcc dot gnu.org --- Created attachment 33794 -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=33794action=edit PR63587.patch
[Bug ipa/63580] [5 Regression] ICE : error: invalid argument to gimple call
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63580 --- Comment #2 from marxin at gcc dot gnu.org --- (In reply to Richard Biener from comment #1) You miss to mark p1 addressable in the alias decl (that is, copy TREE_ADDRESSABLE). As I can see, ICF creates thunk to a localalias of foo. At which please I should preserve addressable attribute? Thanks, Martin
[Bug ipa/63587] [5 Regression] ICE : tree check: expected var_decl, have result_decl in add_local_variables, at tree-inline.c:4112
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63587 --- Comment #8 from Martin Liška marxin at gcc dot gnu.org --- I added assert to cgraphunit.c (expand_thunk):1547: /* Build call to the function being thunked. */ if (!VOID_TYPE_P (restype)) { if (DECL_BY_REFERENCE (resdecl)) restmp = gimple_fold_indirect_ref (resdecl); else if (!is_gimple_reg_type (restype)) { restmp = resdecl; gcc_assert (TREE_CODE (restmp) == VAR_DECL); add_local_decl (cfun, restmp); BLOCK_VARS (DECL_INITIAL (current_function_decl)) = restmp; } else restmp = create_tmp_reg (restype, retval); } It's triggered quite often, one example of a thunk created by IPA ICF: std::basic_streambuf_CharT, _Traits::pos_type std::basic_streambuf_CharT, _Traits::seekpos(std::basic_streambuf_CharT, _Traits::pos_type, std::ios_base::openmode) [with _CharT = char; _Traits = std::char_traitschar; std::basic_streambuf_CharT, _Traits::pos_type = std::fpos__mbstate_t; std::ios_base::openmode = std::_Ios_Openmode] (struct basic_streambuf * const this, struct pos_type D.23077, openmode D.23078) { struct pos_type retval; bb 2: retval = std::basic_streambufwchar_t::seekpos (this_2(D), D.23077, _3(D)); [tail call] return retval; } where std::basic_streambuf_CharT, _Traits::pos_type is: result_decl 0x74eec708 D.39821 type record_type 0x759c2150 pos_type sizes-gimplified asm_written used needs-constructing type_1 type_5 TI size integer_cst 0x76c2fe40 constant 128 unit size integer_cst 0x76c2fe58 constant 16 align 64 symtab -164402368 alias set -1 canonical type 0x7614adc8 fields field_decl 0x751cd850 _M_off type integer_type 0x7678c738 streamoff used private nonlocal decl_3 DI file /home/marxin/Programming/gcc/objdir/x86_64-unknown-linux-gnu/libstdc++-v3/include/bits/postypes.h line 115 col 33 size integer_cst 0x76c2fdf8 constant 64 unit size integer_cst 0x76c2fe10 constant 8 align 64 offset_align 128 offset integer_cst 0x76c2fe28 constant 0 bit offset integer_cst 0x76c2fe70 constant 0 context record_type 0x7614adc8 fpos chain field_decl 0x751cd8e8 _M_state context namespace_decl 0x76c4c098 std full-name std::basic_streambufchar::pos_type needs-constructor X() has-type-conversion X(constX) this=(X) n_parents=0 use_template=1 interface-unknown pointer_to_this pointer_type 0x75224e70 chain type_decl 0x76146da8 fpos ignored TI file /home/marxin/Programming/gcc/objdir/x86_64-unknown-linux-gnu/libstdc++-v3/include/streambuf line 602 col 7 size integer_cst 0x76c2fe40 128 unit size integer_cst 0x76c2fe58 16 align 64 context function_decl 0x75797948 seekoff Is there a bug in expand_thunk or do I miss something? Thanks, Martin
[Bug bootstrap/63573] [5 Regression] libgo: ICE building libgo on powerpc-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 --- Comment #2 from Martin Liška marxin at gcc dot gnu.org --- More precise back-trace: ../../../../libgo/go/path/filepath/path.go:158:1: internal compiler error: in expand_expr_addr_expr_1, at expr.c:7665 func ToSlash(path string) string { ^ 0x10501373 expand_expr_addr_expr_1 ../../gcc/expr.c:7665 0x10501d93 expand_expr_addr_expr ../../gcc/expr.c:7779 0x10510797 expand_expr_real_1(tree_node*, rtx_def*, machine_mode, expand_modifier, rtx_def**, bool) ../../gcc/expr.c:10604 0x105023af expand_expr_real(tree_node*, rtx_def*, machine_mode, expand_modifier, rtx_def**, bool) ../../gcc/expr.c:7947 0x1032b413 expand_normal ../../gcc/expr.h:457 0x1032d4bf precompute_register_parameters ../../gcc/calls.c:832 0x10335813 expand_call(tree_node*, rtx_def*, int) ../../gcc/calls.c:3009 0x1050f433 expand_expr_real_1(tree_node*, rtx_def*, machine_mode, expand_modifier, rtx_def**, bool) ../../gcc/expr.c:10372 0x105023af expand_expr_real(tree_node*, rtx_def*, machine_mode, expand_modifier, rtx_def**, bool) ../../gcc/expr.c:7947 0x104f5e1f store_expr(tree_node*, rtx_def*, int, bool) ../../gcc/expr.c:5337 0x104f47e3 expand_assignment(tree_node*, tree_node*, bool) ../../gcc/expr.c:5123 0x103505a3 expand_call_stmt ../../gcc/cfgexpand.c:2321 0x103545c7 expand_gimple_stmt_1 ../../gcc/cfgexpand.c:3218 0x10354df3 expand_gimple_stmt ../../gcc/cfgexpand.c:3370 0x10354f73 expand_gimple_tailcall ../../gcc/cfgexpand.c:3417 0x1035d3d7 expand_gimple_basic_block ../../gcc/cfgexpand.c:5182 0x1035f983 execute ../../gcc/cfgexpand.c:5811 Where debug_rtx(result): (reg/v:DI 157 [ path ]) if I go up in BT: #11 0x103505a4 in expand_call_stmt (stmt=0x3fffafcc5bb0) at ../../gcc/cfgexpand.c:2321 2321expand_assignment (lhs, exp, false); (gdb) call debug_gimple_stmt(stmt) # .MEM_2 = VDEF .MEM_1(D) retval = path_filepath.FromSlash.localalias.1 (path); [return slot optimization] [tail call] I think it would be duplicate of PR63587, where we expand thunk and RESULT_DECL is given as argument for add_local_decl. Thanks, Martin
[Bug bootstrap/63573] [5 Regression] libgo: ICE building libgo on powerpc-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|--- |DUPLICATE --- Comment #3 from Martin Liška marxin at gcc dot gnu.org --- Duplicate. *** This bug has been marked as a duplicate of bug 63587 ***
[Bug ipa/63587] [5 Regression] ICE : tree check: expected var_decl, have result_decl in add_local_variables, at tree-inline.c:4112
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63587 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added CC||doko at gcc dot gnu.org --- Comment #11 from Martin Liška marxin at gcc dot gnu.org --- *** Bug 63573 has been marked as a duplicate of this bug. ***
[Bug bootstrap/63622] [5.0 Regression] Bootstrap fails on x86_64-apple-darwin1[34] after revision r216305
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63622 --- Comment #3 from Martin Liška marxin at gcc dot gnu.org --- Created attachment 33843 -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=33843action=edit IPA ICF aliasing restriction Can you please try to apply following patch? It should disable alias creation for targets that do not support aliasing.
[Bug ipa/63587] [5 Regression] ICE : tree check: expected var_decl, have result_decl in add_local_variables, at tree-inline.c:4112
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63587 --- Comment #14 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Wed Oct 29 15:17:42 2014 New Revision: 216841 URL: https://gcc.gnu.org/viewcvs?rev=216841root=gccview=rev Log: PR ipa/63587 * g++.dg/ipa/pr63587-1.C: New test * g++.dg/ipa/pr63587-2.C: New test. * cgraphunit.c (cgraph_node::expand_thunk): Only VAR_DECLs are put to local declarations. * function.c (add_local_decl): Implementation moved from header file, assert introduced for tree type. * function.h: Likewise. Added: trunk/gcc/testsuite/g++.dg/ipa/pr63587-1.C trunk/gcc/testsuite/g++.dg/ipa/pr63587-2.C Modified: trunk/gcc/ChangeLog trunk/gcc/cgraphunit.c trunk/gcc/function.c trunk/gcc/function.h trunk/gcc/testsuite/ChangeLog
[Bug ipa/63587] [5 Regression] ICE : tree check: expected var_decl, have result_decl in add_local_variables, at tree-inline.c:4112
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63587 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|--- |FIXED --- Comment #15 from Martin Liška marxin at gcc dot gnu.org --- Resolved.
[Bug bootstrap/63573] [5 Regression] libgo: ICE building libgo on powerpc-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|RESOLVED|REOPENED Last reconfirmed||2014-10-29 Resolution|DUPLICATE |--- Ever confirmed|0 |1 --- Comment #4 from Martin Liška marxin at gcc dot gnu.org --- PR still persists after installation of patch for PR63587.
[Bug bootstrap/63622] [5.0 Regression] Bootstrap fails on x86_64-apple-darwin1[34] after revision r216305
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63622 --- Comment #6 from Martin Liška marxin at gcc dot gnu.org --- (In reply to Dominique d'Humieres from comment #4) Created attachment 33843 [details] IPA ICF aliasing restriction Can you please try to apply following patch? It should disable alias creation for targets that do not support aliasing. With the patch bootstrap proceeds up to stage 2 where it fails with /opt/gcc/build_w/./prev-gcc/xg++ -B/opt/gcc/build_w/./prev-gcc/ -B/opt/gcc/gcc4.10w/x86_64-apple-darwin14.0.0/bin/ -nostdinc++ -B/opt/gcc/build_w/prev-x86_64-apple-darwin14.0.0/libstdc++-v3/src/.libs -B/opt/gcc/build_w/prev-x86_64-apple-darwin14.0.0/libstdc++-v3/libsupc++/. libs -I/opt/gcc/build_w/prev-x86_64-apple-darwin14.0.0/libstdc++-v3/include/ x86_64-apple-darwin14.0.0 -I/opt/gcc/build_w/prev-x86_64-apple-darwin14.0.0/libstdc++-v3/include -I/opt/gcc/work/libstdc++-v3/libsupc++ -L/opt/gcc/build_w/prev-x86_64-apple-darwin14.0.0/libstdc++-v3/src/.libs -L/opt/gcc/build_w/prev-x86_64-apple-darwin14.0.0/libstdc++-v3/libsupc++/. libs -c -g -O2 -gtoggle -DIN_GCC-fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wmissing-format-attribute -Woverloaded-virtual -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -Werror -fno-common -DHAVE_CONFIG_H -I. -I. -I../../work/gcc -I../../work/gcc/. -I../../work/gcc/../include -I./../intl -I../../work/gcc/../libcpp/include -I/opt/mp/include -I../../work/gcc/../libdecnumber -I../../work/gcc/../libdecnumber/dpd -I../libdecnumber -I../../work/gcc/../libbacktrace -DCLOOG_INT_GMP -DCLOOG_INT_GMP -I/opt/mp/include -o tree-inline.o -MT tree-inline.o -MMD -MP -MF ./.deps/tree-inline.TPo ../../work/gcc/tree-inline.c ../../work/gcc/tree-inline.c: In function 'int estimate_num_insns_seq(gimple_seq, eni_weights*)': ../../work/gcc/tree-inline.c:5667:1: error: invalid argument to gimple call } ^ stmts # .MEM_3 = VDEF .MEM_1(D) retval.1640_4 = count_insns_seq (stmts, weights_2(D)); [tail call] ../../work/gcc/tree-inline.c:5667:1: internal compiler error: verify_gimple failed That looks like duplicate of PR63580. I hope the PR will be fixed today. Thanks, Martin ../../work/gcc/tree-inline.c:5667:1: internal compiler error: Abort trap: 6 xg++: internal compiler error: Abort trap: 6 (program cc1plus) make[3]: *** [tree-inline.o] Abort trap: 6 make[3]: Leaving directory `/opt/gcc/build_w/gcc' make[2]: *** [all-stage2-gcc] Error 2 make[2]: Leaving directory `/opt/gcc/build_w' make[1]: *** [stage2-bubble] Error 2 make[1]: Leaving directory `/opt/gcc/build_w' make: *** [all] Error 2
[Bug ipa/63664] ipa-icf pass fails with segfault
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63664 --- Comment #1 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Thu Oct 30 10:10:58 2014 New Revision: 216913 URL: https://gcc.gnu.org/viewcvs?rev=216913root=gccview=rev Log: PR ipa/63574 PR ipa/63664 * g++.dg/ipa/pr63574.C: New test. * ipa-icf-gimple.c (func_checker::parse_labels): Missing comment added. (func_checker::compare_gimple_label): Simlified comparison introduced. * ipa-icf-gimple.h: Missing comment added. Added: trunk/gcc/testsuite/g++.dg/ipa/pr63574.C Modified: trunk/gcc/ChangeLog trunk/gcc/ipa-icf-gimple.c trunk/gcc/ipa-icf-gimple.h trunk/gcc/testsuite/ChangeLog
[Bug tree-optimization/63574] [5 Regression] ICE building libjava (segfault) on arm-linux-gnueabihf
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63574 --- Comment #5 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Thu Oct 30 10:10:58 2014 New Revision: 216913 URL: https://gcc.gnu.org/viewcvs?rev=216913root=gccview=rev Log: PR ipa/63574 PR ipa/63664 * g++.dg/ipa/pr63574.C: New test. * ipa-icf-gimple.c (func_checker::parse_labels): Missing comment added. (func_checker::compare_gimple_label): Simlified comparison introduced. * ipa-icf-gimple.h: Missing comment added. Added: trunk/gcc/testsuite/g++.dg/ipa/pr63574.C Modified: trunk/gcc/ChangeLog trunk/gcc/ipa-icf-gimple.c trunk/gcc/ipa-icf-gimple.h trunk/gcc/testsuite/ChangeLog
[Bug bootstrap/63573] [5 Regression] libgo: ICE building libgo on powerpc-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 --- Comment #5 from Martin Liška marxin at gcc dot gnu.org --- Issue looks very similar, ICF identifies a pair of function which are transformed to thunk (with tail-call). Where: (gdb) call debug_gimple_stmt(stmt) # .MEM_3 = VDEF .MEM_1(D) encoding_json.error.pN25_encoding_json.encodeState.localalias.36 (d_2(D), err); [tail call] and: #9 0x102a315c in expand_expr (exp=0x3fffa79d3940, target=0x3fffaf8d0400, mode=VOIDmode, modifier=EXPAND_NORMAL) at ../../gcc/expr.h:382 382 return expand_expr_real (exp, target, mode, modifier, NULL, false); (gdb) call debug_tree(exp) call_expr 0x3fffa79d3940 type void_type 0x3fffaf8b1260 asm_written VOID align 8 symtab 0 alias set -1 canonical type 0x3fffaf8b1260 pointer_to_this pointer_type 0x3fffaf8b1308 side-effects addressable protected fn addr_expr 0x3fffafa9bc80 type pointer_type 0x3fffafb60a80 type function_type 0x3fffafb609d8 unsigned SI size integer_cst 0x3fffaf881158 constant 32 unit size integer_cst 0x3fffaf881170 constant 4 align 32 symtab 0 alias set -1 canonical type 0x3fffafb60a80 constant arg 0 function_decl 0x3fffa792d728 encoding_json.error.pN25_encoding_json.encodeState.localalias.36 type function_type 0x3fffafb609d8 addressable asm_written used SI file ../../../../libgo/go/encoding/json/encode.go line 272 col 1 align 32 result result_decl 0x3fffb1851ab8 D.3022 (mem:SI (symbol_ref:SI (encoding_json.error.pN25_encoding_json.encodeState.localalias.36) [flags 0x3] function_decl 0x3fffa792d728 encoding_json.error.pN25_encoding_json.encodeState.localalias.36) [0 S4 A8]) arg 0 ssa_name 0x3fffa7916078 type pointer_type 0x3fffaf9e03f0 type record_type 0x3fffaf8b8f10 .encoding/json.decodeState sizes-gimplified asm_written public unsigned SI size integer_cst 0x3fffaf881158 32 unit size integer_cst 0x3fffaf881170 4 align 32 symtab 16383 alias set 5 canonical type 0x3fffaf9e03f0 visited var parm_decl 0x3fffafad0980 ddef_stmt GIMPLE_NOP version 2 ptr-info 0x3fffa58b0c90 arg 1 parm_decl 0x3fffafad0a00 err type record_type 0x3fffaf8b6d98 error sizes-gimplified asm_written DI size integer_cst 0x3fffaf8811b8 constant 64 unit size integer_cst 0x3fffaf8811d0 constant 8 align 32 symtab 16383 alias set 28 canonical type 0x3fffaf8b6d98 fields field_decl 0x3fffaf961138 __methods pointer_to_this pointer_type 0x3fffaf9a6708 addressable used DI file ../../../../libgo/go/encoding/json/decode.go line 193 col 1 size integer_cst 0x3fffaf8811b8 64 unit size integer_cst 0x3fffaf8811d0 8 align 32 context function_decl 0x3fffaf979f78 json.error.pN25_encoding_json.decodeState (reg/v:DI 157 [ err ]) arg-type record_type 0x3fffaf8b6d98 error incoming-rtl (mem:DI (reg:SI 4 4) [0 S8 A8]) (gdb) frame 1 (gdb) call debug_rtx(result) (reg/v:DI 157 [ err ]) Am I right that problem comes up from TREE_ADDRESSABLE flag set on arg 1 (err)? I would appreciate any hint how should be thunk creation fixed. Thank you, Martin
[Bug ipa/63580] [5 Regression] ICE : error: invalid argument to gimple call
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63580 --- Comment #4 from Martin Liška marxin at gcc dot gnu.org --- diff --git a/gcc/cgraphunit.c b/gcc/cgraphunit.c index 6f61f5c..89c96dc 100644 --- a/gcc/cgraphunit.c +++ b/gcc/cgraphunit.c @@ -2342,6 +2342,14 @@ cgraph_node::create_wrapper (cgraph_node *target) cgraph_edge *e = create_edge (target, NULL, 0, CGRAPH_FREQ_BASE); +tree arguments = DECL_ARGUMENTS (decl); + +while (arguments) + { + TREE_ADDRESSABLE (arguments) = false; + arguments = TREE_CHAIN (arguments); + } + expand_thunk (false, true); e-call_stmt_cannot_inline_p = true; Following patch fixed the issue, boostrap works without any regression. But I guess it's just a partial fix. There's very similar issue: PR63573. Thanks, Martin
[Bug tree-optimization/63574] [5 Regression] ICE building libjava (segfault) on arm-linux-gnueabihf
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63574 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #6 from Martin Liška marxin at gcc dot gnu.org --- Resolved.
[Bug ipa/63664] ipa-icf pass fails with segfault
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63664 Bug 63664 depends on bug 63574, which changed state. Bug 63574 Summary: [5 Regression] ICE building libjava (segfault) on arm-linux-gnueabihf https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63574 What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED
[Bug ipa/63696] Alloc-dealloc-mismatch in ipa-icf.c
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63696 --- Comment #1 from Martin Liška marxin at gcc dot gnu.org --- Thank you Maxim for the fix, please send it to patches mailing list. Martin
[Bug rtl-optimization/63712] [5.0 regression] ICE in expand_expr_addr_expr_1, at expr.c:7662
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63712 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|--- |DUPLICATE --- Comment #2 from Martin Liška marxin at gcc dot gnu.org --- Dup. *** This bug has been marked as a duplicate of bug 63573 ***
[Bug bootstrap/63573] [5 Regression] libgo: ICE building libgo on powerpc-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added CC||sch...@linux-m68k.org --- Comment #9 from Martin Liška marxin at gcc dot gnu.org --- *** Bug 63712 has been marked as a duplicate of this bug. ***
[Bug tree-optimization/63595] [5.0 Regression] Segmentation faults inside kernel
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63595 --- Comment #8 from Martin Liška marxin at gcc dot gnu.org --- Same problem can be even seen on x86_64-linux-pc: _ZNK13TriangulationILi3EE3endEv: .LFB5569: .cfi_startproc subq$24, %rsp .cfi_def_cfa_offset 32 movq%rsp, %rdi call_ZNK13TriangulationILi3EE8end_quadEv addq$24, %rsp .cfi_def_cfa_offset 8 ret .cfi_endproc _ZNK13TriangulationILi3EE8end_quadEv: .LFB2586: .loc 3 2901 0 .cfi_startproc .LVL898: .loc 3 2901 0 movq%rdi, %rax .LBB27759: .LBB27760: .LBB27761: .LBB27762: .loc 14 41 0 movl$-1, (%rdi) movl$-1, 4(%rdi) movq%rsi, 8(%rdi) .LBE27762: .LBE27761: .LBE27760: .LBE27759: .loc 3 2905 0 ret .cfi_endproc Body of the function is created as tail-call trunk by IPA-ICF: Triangulationdim::raw_cell_iterator Triangulationdim::end() const [with int dim = 3; Triangulationdim::raw_cell_iterator = TriaRawIterator3, CellAccessor3 ] (const struct Triangulation * const this) { ;; basic block 2, loop depth 0 ;;pred: ENTRY Triangulation3::end_quad (this_2(D)); [tail call] return; ;;succ: EXIT } ;; Generating RTL for gimple basic block 2 ;; Triangulation3::end_quad (this_2(D)); [tail call] (insn 7 6 8 (parallel [ (set (reg:DI 85) (plus:DI (reg/f:DI 78 virtual-stack-vars) (const_int -16 [0xfff0]))) (clobber (reg:CC 17 flags)) ]) -1 (nil)) (insn 8 7 9 (set (reg:DI 4 si) (reg/f:DI 84 [ this ])) -1 (nil)) (insn 9 8 10 (set (reg:DI 5 di) (reg:DI 85)) -1 (nil)) (call_insn 10 9 0 (call (mem:QI (symbol_ref/i:DI (_ZNK13TriangulationILi3EE8end_quadEv) [flags 0x1] function_decl 0x7ff17d629bd0 end_quad) [0 end_quad S1 A8]) (const_int 0 [0])) -1 (expr_list:REG_CALL_DECL (symbol_ref/i:DI (_ZNK13TriangulationILi3EE8end_quadEv) [flags 0x1] function_decl 0x7ff17d629bd0 end_quad) (expr_list:REG_EH_REGION (const_int 0 [0]) (nil))) (expr_list:DI (use (reg:DI 5 di)) (expr_list:DI (use (reg:DI 4 si)) (nil
[Bug tree-optimization/63595] [5.0 Regression] Segmentation faults inside kernel
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63595 --- Comment #9 from Martin Liška marxin at gcc dot gnu.org --- Merged function by IPA ICF after expand_thunk is called: Triangulationdim::raw_quad_iterator Triangulationdim::end_quad() const [with int dim = 3; Triangulationdim::raw_quad_iterator = TriaRawIterator3, TriaObjectAccessor2, 3 ] (const struct Triangulation * const this) { bb 2: # DEBUG this = _2(D) # DEBUG parent = this_3(D) # DEBUG level = -1 # DEBUG index = -1 # DEBUG local_data = 0B # DEBUG this = _2(D) # DEBUG D#265 = MEM[(struct TriaRawIterator *)_2(D)].accessor # DEBUG this = D#265 # DEBUG parent = this_3(D) # DEBUG level = -1 # DEBUG index = -1 # DEBUG local_data = 0B # DEBUG D#264 = D#265-D.46601 # DEBUG this = D#264 # DEBUG parent = this_3(D) # DEBUG level = -1 # DEBUG index = -1 # DEBUG D.101330 = 0B MEM[(struct TriaAccessor *)_2(D)].present_level = -1; MEM[(struct TriaAccessor *)_2(D)].present_index = -1; MEM[(struct TriaAccessor *)_2(D)].tria = this_3(D); return _2(D); } Triangulationdim::raw_cell_iterator Triangulationdim::end() const [with int dim = 3; Triangulationdim::raw_cell_iterator = TriaRawIterator3, CellAccessor3 ] (const struct Triangulation * const this) { bb 2: Triangulation3::end_quad (this_2(D)); [tail call] return; }
[Bug tree-optimization/63595] [5.0 Regression] Segmentation faults inside kernel
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63595 --- Comment #10 from Martin Liška marxin at gcc dot gnu.org --- Created attachment 33896 -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=33896action=edit reduced test case for tria.ii
[Bug bootstrap/63622] [5.0 Regression] Bootstrap fails on x86_64-apple-darwin1[34] after revision r216305
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63622 --- Comment #21 from Martin Liška marxin at gcc dot gnu.org --- (In reply to Igor Zamyatin from comment #20) This is mentioned here - https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63534#c9 Fix for this is under review, start of the discussion is here - http://gcc.gnu.org/ml/gcc-patches/2014-10/msg01727.html If you apply both my IPA ICF alias restriction patch and this mentioned patch, can you bootstrap? As I don't have a machine with darwin1, I cannot verify if bootstrap works and there's no new regression? Thanks, Martin
[Bug target/63534] [5 Regression] Bootstrap failure on x86_64/i686-linux
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63534 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added CC||marxin at gcc dot gnu.org --- Comment #58 from Martin Liška marxin at gcc dot gnu.org --- Hello Jack. I would like to thank you for the effort you invested in testing. I'm going to push all IPA ICF related patches to mainline as soon as possible. Interesting think would be to have a machine with darwin platform in compile farm. But I know it must be a different machine than your MacPro :) Thanks, Martin
[Bug tree-optimization/63595] [5.0 Regression] Segmentation faults inside kernel
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63595 --- Comment #11 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Fri Nov 7 12:32:30 2014 New Revision: 217218 URL: https://gcc.gnu.org/viewcvs?rev=217218root=gccview=rev Log: PR ipa/63595 * g++.dg/ipa/pr63595.C: New test. * cgraphunit.c (cgraph_node::expand_thunk): DECL_BY_REFERENCE is correctly handled for thunks created by IPA ICF. Added: trunk/gcc/testsuite/g++.dg/ipa/pr63595.C Modified: trunk/gcc/ChangeLog trunk/gcc/cgraphunit.c trunk/gcc/testsuite/ChangeLog
[Bug tree-optimization/63747] [5 regression] icf mis-compares switch gimple
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63747 --- Comment #6 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Fri Nov 7 12:35:43 2014 New Revision: 217219 URL: https://gcc.gnu.org/viewcvs?rev=217219root=gccview=rev Log: PR ipa/63747 * gcc.dg/ipa/pr63747.c: New test. * ipa-icf-gimple.c (func_checker::compare_gimple_switch): Missing checking for CASE_LOW and CASE_HIGH added. Added: trunk/gcc/testsuite/gcc.dg/ipa/pr63747.c Modified: trunk/gcc/ChangeLog trunk/gcc/ipa-icf-gimple.c trunk/gcc/testsuite/ChangeLog
[Bug tree-optimization/63595] [5.0 Regression] Segmentation faults inside kernel
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63595 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|WAITING |RESOLVED Resolution|--- |FIXED --- Comment #12 from Martin Liška marxin at gcc dot gnu.org --- Resolved.
[Bug tree-optimization/63747] [5 regression] icf mis-compares switch gimple
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63747 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #7 from Martin Liška marxin at gcc dot gnu.org --- Resolved.
[Bug tree-optimization/63721] [5 Regression] IPA ICF cause atomic-comp-swap-release-acquire.c ICE on arm
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63721 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|--- |DUPLICATE --- Comment #4 from Martin Liška marxin at gcc dot gnu.org --- Dup. *** This bug has been marked as a duplicate of bug 63580 ***
[Bug ipa/63580] [5 Regression] ICE : error: invalid argument to gimple call
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63580 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added CC||jiwang at gcc dot gnu.org --- Comment #6 from Martin Liška marxin at gcc dot gnu.org --- *** Bug 63721 has been marked as a duplicate of this bug. ***
[Bug ipa/63580] [5 Regression] ICE : error: invalid argument to gimple call
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63580 --- Comment #7 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Fri Nov 7 13:37:41 2014 New Revision: 217222 URL: https://gcc.gnu.org/viewcvs?rev=217222root=gccview=rev Log: PR ipa/63580 * cgraphunit.c (cgraph_node::create_wrapper): TREE_ADDRESSABLE is set to false for a newly created thunk. * g++.dg/ipa/pr63580.C: New test. Added: trunk/gcc/testsuite/g++.dg/ipa/pr63580.C Modified: trunk/gcc/ChangeLog trunk/gcc/cgraphunit.c trunk/gcc/testsuite/ChangeLog
[Bug bootstrap/63573] [5 Regression] libgo: ICE building libgo on powerpc-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 --- Comment #14 from Martin Liška marxin at gcc dot gnu.org --- (In reply to Andreas Schwab from comment #12) This also breaks g++.dg/ipa/pr63587-2.C on powerpc -m32, but the patches in #c6 and #c8 don't fix that. $ gcc/xg++ -Bgcc/ ../gcc/testsuite/g++.dg/ipa/pr63587-2.C -nostdinc++ -Ipowerpc64-linux/32/libstdc++-v3/include/powerpc64-linux -Ipowerpc64-linux/32/libstdc++-v3/include -I../libstdc++-v3/libsupc++ -I../libstdc++-v3/include/backward -I../libstdc++-v3/testsuite/util -std=gnu++11 -O2 -S -m32 -o pr63587-2.s ../gcc/testsuite/g++.dg/ipa/pr63587-2.C: In static member function ‘static int boost::function_obj_invoker0FunctionObj::invoke(boost::function_buffer) [with FunctionObj = boost::test_case_template_invokerdefault_formatting_invoker]’: ../gcc/testsuite/g++.dg/ipa/pr63587-2.C:21:3: internal compiler error: in expand_expr_addr_expr_1, at expr.c:7725 There's really problem that both suggested patches can fix just cases where DECL_INCOMING_RTL is defined. In following situation: static boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::type boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::make(ActorTLeftExprT, RightT) [with ActorT = boost::actor; LeftExprT = boost::log::attribute_output_terminalboost::actorboost::log::attribute_output_terminalboost::actorint, boost::log::to_log_fun , boost::log::to_log_fun; RightT = boost::log::attribute_actorint, boost::log::value_extractor, void, boost::actor; ValueT = int; boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::type = boost::actorboost::log::attribute_output_terminalboost::actorboost::log::attribute_output_terminalboost::actorboost::log::attribute_output_terminalboost::actorint, boost::log::to_log_fun , boost::log::to_log_fun , boost::log::to_log_fun ] (struct actor left, struct attribute_actor right) { struct type D.4892; struct attribute_name D.4891; struct to_log_fun D.4890; struct actor left; bb 2: left = left; D.4891 = MEM[(struct attribute_terminal *)right_2(D)].m_name; boost::log::attribute_output_terminalboost::actorboost::log::attribute_output_terminalboost::actorboost::log::attribute_output_terminalboost::actorint, boost::log::to_log_fun , boost::log::to_log_fun , boost::log::to_log_fun::attribute_output_terminalint (D.4892, left, D.4891, D.4890, 0); D.4892 ={v} {CLOBBER}; return; } ICF introduces: static boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::type boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::make(ActorTLeftExprT, RightT) [with ActorT = boost::actor; LeftExprT = int; RightT = boost::log::attribute_actor{anonymous}::my_class, boost::log::value_extractor, void, boost::actor; ValueT = int; boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::type = boost::actorboost::log::attribute_output_terminalboost::actorint, boost::log::to_log_fun ] (struct actor left, struct attribute_actor right) { struct type retval; bb 2: retval = boost::log::make_output_actorboost::actorint, boost::log::attribute_actorint, boost::log::value_extractor, void, boost::actor, int::make (left, right_2(D)); [tail call] return retval; } with following call: call_expr 0x3fffafbc2fc0 type record_type 0x3fffafba type used needs-constructing type_5 type_6 QI size integer_cst 0x3fffaf881518 constant 8 unit size integer_cst 0x3fffaf881530 constant 1 align 8 symtab 0 alias set -1 canonical type 0x3fffafb3ff48 fields field_decl 0x3fffafb61138 proto_expr_ type record_type 0x3fffafb71458 type nonlocal decl_3 QI file ../gcc/testsuite/g++.dg/ipa/pr63587-2.C line 145 col 48 size integer_cst 0x3fffaf881518 8 unit size integer_cst 0x3fffaf881530 1 align 8 offset_align 128 offset integer_cst 0x3fffaf881410 constant 0 bit offset integer_cst 0x3fffaf881470 constant 0 context record_type 0x3fffafb3ff48 actor chain type_decl 0x3fffafb610a0 actor context namespace_decl 0x3fffaf984a38 boost full-name boost::log::make_output_actorboost::actorint, boost::log::attribute_actorint, boost::log::value_extractor, void, boost::actor, int::type needs-constructor X() X(constX) this=(X) n_parents=0 use_template=1 interface-unknown pointer_to_this pointer_type 0x3fffafbae9a0 chain type_decl 0x3fffafb60be0 actor side-effects private protected fn addr_expr 0x3fffafc130c0 type pointer_type 0x3fffafba0348 type function_type 0x3fffafba00a8 unsigned SI size integer_cst 0x3fffaf8813e0 constant 32 unit size integer_cst 0x3fffaf8813f8 constant 4 align 32 symtab 0 alias set -1 canonical type 0x3fffafba03f0 constant arg 0 function_decl 0x3fffafb51518 make type function_type 0x3fffafba00a8 addressable asm_written used public static weak autoinline decl_1 decl_5 decl_6 SI file ../gcc/testsuite/g++.dg/ipa/pr63587-2.C line 208 col 3 align
[Bug bootstrap/63573] [5 Regression] libgo: ICE building libgo on powerpc-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 --- Comment #16 from Martin Liška marxin at gcc dot gnu.org --- (In reply to Jan Hubicka from comment #15) https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 --- Comment #14 from Martin Liška marxin at gcc dot gnu.org --- (In reply to Andreas Schwab from comment #12) This also breaks g++.dg/ipa/pr63587-2.C on powerpc -m32, but the patches in #c6 and #c8 don't fix that. $ gcc/xg++ -Bgcc/ ../gcc/testsuite/g++.dg/ipa/pr63587-2.C -nostdinc++ -Ipowerpc64-linux/32/libstdc++-v3/include/powerpc64-linux -Ipowerpc64-linux/32/libstdc++-v3/include -I../libstdc++-v3/libsupc++ -I../libstdc++-v3/include/backward -I../libstdc++-v3/testsuite/util -std=gnu++11 -O2 -S -m32 -o pr63587-2.s ../gcc/testsuite/g++.dg/ipa/pr63587-2.C: In static member function ???static int boost::function_obj_invoker0FunctionObj::invoke(boost::function_buffer) [with FunctionObj = boost::test_case_template_invokerdefault_formatting_invoker]???: ../gcc/testsuite/g++.dg/ipa/pr63587-2.C:21:3: internal compiler error: in expand_expr_addr_expr_1, at expr.c:7725 There's really problem that both suggested patches can fix just cases where DECL_INCOMING_RTL is defined. In following situation: static boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::type boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::make(ActorTLeftExprT, RightT) [with ActorT = boost::actor; LeftExprT = boost::log::attribute_output_terminalboost::actorboost::log::attribute_output_terminalboost::actorint, boost::log::to_log_fun , boost::log::to_log_fun; RightT = boost::log::attribute_actorint, boost::log::value_extractor, void, boost::actor; ValueT = int; boost::log::make_output_actorActorTLeftExprT, RightT, ValueT::type = boost::actorboost::log::attribute_output_terminalboost::actorboost::log::attribute_output_terminalboost::actorboost::log::attribute_output_terminalboost::actorint, boost::log::to_log_fun , boost::log::to_log_fun , boost::log::to_log_fun ] (struct actor left, struct attribute_actor right) { struct type D.4892; struct attribute_name D.4891; struct to_log_fun D.4890; struct actor left; bb 2: left = left; The reason here is that thunk expansion introduce extra temporary. if (nargs) for (i = 1, arg = DECL_CHAIN (a); i nargs; i++, arg = DECL_CHAIN (arg)) { tree tmp = arg; if (!is_gimple_val (arg)) { tmp = create_tmp_reg (TYPE_MAIN_VARIANT (TREE_TYPE (arg)), arg); gimple stmt = gimple_build_assign (tmp, arg); gsi_insert_after (bsi, stmt, GSI_NEW_STMT); } vargs.quick_push (tmp); } the temporary obviously is not linked with the original memory expression. Ok, that makes sense. I supose we may want to simply drop the tailcall flag in cases copy is necessary, but I do not really see why a copy is desirable here: IMO whatever can be RHS of assignment can also be passed to function. What makes left to be !is_gimple_val here? The loops iterates from 1..(nargs-1), where 'left' is first argument and is put to vargs here: if (this_adjusting) vargs.quick_push (thunk_adjust (bsi, a, 1, fixed_offset, virtual_offset)); else if (nargs) vargs.quick_push (a); ---^ if (nargs) for (i = 1, arg = DECL_CHAIN (a); i nargs; i++, arg = DECL_CHAIN (arg)) Martin Honza
[Bug ipa/63795] ipa-icf ICE with noreturn functions (test case builtin-noret-1.c)
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63795 --- Comment #2 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Tue Nov 11 14:58:21 2014 New Revision: 217355 URL: https://gcc.gnu.org/viewcvs?rev=217355root=gccview=rev Log: PR ipa/63622 PR ipa/63795 * g++.dg/ipa/ipa-icf-4.C: Add more precise dump scan. * g++.dg/ipa/ipa-icf-5.C: Add condition for target with symbol alias support. * ipa-icf.c (sem_function::merge): Add new target symbol alias support guard. (sem_variable::merge): Likewise. * ipa-icf.h (target_supports_symbol_aliases_p): New function. Modified: trunk/gcc/ChangeLog trunk/gcc/ipa-icf.c trunk/gcc/ipa-icf.h trunk/gcc/testsuite/ChangeLog trunk/gcc/testsuite/g++.dg/ipa/ipa-icf-4.C trunk/gcc/testsuite/g++.dg/ipa/ipa-icf-5.C
[Bug bootstrap/63622] [5.0 Regression] Bootstrap fails on x86_64-apple-darwin1[34] after revision r216305
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63622 --- Comment #27 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Tue Nov 11 14:58:21 2014 New Revision: 217355 URL: https://gcc.gnu.org/viewcvs?rev=217355root=gccview=rev Log: PR ipa/63622 PR ipa/63795 * g++.dg/ipa/ipa-icf-4.C: Add more precise dump scan. * g++.dg/ipa/ipa-icf-5.C: Add condition for target with symbol alias support. * ipa-icf.c (sem_function::merge): Add new target symbol alias support guard. (sem_variable::merge): Likewise. * ipa-icf.h (target_supports_symbol_aliases_p): New function. Modified: trunk/gcc/ChangeLog trunk/gcc/ipa-icf.c trunk/gcc/ipa-icf.h trunk/gcc/testsuite/ChangeLog trunk/gcc/testsuite/g++.dg/ipa/ipa-icf-4.C trunk/gcc/testsuite/g++.dg/ipa/ipa-icf-5.C
[Bug ipa/63795] ipa-icf ICE with noreturn functions (test case builtin-noret-1.c)
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63795 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #3 from Martin Liška marxin at gcc dot gnu.org --- Resolved.
[Bug middle-end/63819] New: [5 Regression]: Cannot build compiler with --enable-gather-detailed-mem-stats (error: default argument given for parameter 5 of ‘void* ggc_internal_cleared_alloc)
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63819 Bug ID: 63819 Summary: [5 Regression]: Cannot build compiler with --enable-gather-detailed-mem-stats (error: default argument given for parameter 5 of ‘void* ggc_internal_cleared_alloc) Product: gcc Version: 5.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: middle-end Assignee: rguenth at gcc dot gnu.org Reporter: marxin at gcc dot gnu.org ../configure --prefix=/home/marxin/Programming/bin/gcc2 --disable-multilib --enable-languages=c,c++ --enable-checking=release --disable-bootstrap --enable-gather-detailed-mem-stats Error: g++ -c -g -DIN_GCC-fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wmissing-format-attribute -Woverloaded-virtual -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -DHAVE_CONFIG_H -DGENERATOR_FILE -I. -Ibuild -I../../gcc -I../../gcc/build -I../../gcc/../include -I../../gcc/../libcpp/include \ -o build/genmatch.o ../../gcc/genmatch.c ../../gcc/genmatch.c: In function ‘void* ggc_internal_cleared_alloc(size_t, void (*)(void*), size_t, size_t, const char*, int, const char*)’: ../../gcc/genmatch.c:41:24: error: default argument given for parameter 5 of ‘void* ggc_internal_cleared_alloc(size_t, void (*)(void*), size_t, size_t, const char*, int, const char*)’ [-fpermissive] CXX_MEM_STAT_INFO) ^ In file included from ../../gcc/genmatch.c:28:0: ../../gcc/ggc.h:153:14: error: after previous specification in ‘void* ggc_internal_cleared_alloc(size_t, void (*)(void*), size_t, size_t, const char*, int, const char*)’ [-fpermissive] extern void *ggc_internal_cleared_alloc (size_t, void (*)(void *), ^ ../../gcc/genmatch.c:41:24: error: default argument given for parameter 6 of ‘void* ggc_internal_cleared_alloc(size_t, void (*)(void*), size_t, size_t, const char*, int, const char*)’ [-fpermissive] CXX_MEM_STAT_INFO) ^ In file included from ../../gcc/genmatch.c:28:0: ../../gcc/ggc.h:153:14: error: after previous specification in ‘void* ggc_internal_cleared_alloc(size_t, void (*)(void*), size_t, size_t, const char*, int, const char*)’ [-fpermissive] extern void *ggc_internal_cleared_alloc (size_t, void (*)(void *), ^ ../../gcc/genmatch.c:41:24: error: default argument given for parameter 7 of ‘void* ggc_internal_cleared_alloc(size_t, void (*)(void*), size_t, size_t, const char*, int, const char*)’ [-fpermissive] CXX_MEM_STAT_INFO) ^ In file included from ../../gcc/genmatch.c:28:0: ../../gcc/ggc.h:153:14: error: after previous specification in ‘void* ggc_internal_cleared_alloc(size_t, void (*)(void*), size_t, size_t, const char*, int, const char*)’ [-fpermissive] extern void *ggc_internal_cleared_alloc (size_t, void (*)(void *), ^ ../../gcc/genmatch.c: At global scope: ../../gcc/genmatch.c:39:7: warning: unused parameter ‘_loc_name’ [-Wunused-parameter] void *ggc_internal_cleared_alloc (size_t, void (*)(void *), ^ ../../gcc/genmatch.c:39:7: warning: unused parameter ‘_loc_line’ [-Wunused-parameter] ../../gcc/genmatch.c:39:7: warning: unused parameter ‘_loc_function’ [-Wunused-parameter] In file included from ../../gcc/genmatch.c:32:0: ../../gcc/hash-table.h: In instantiation of ‘hash_tableDescriptor, Allocator, true::hash_table(size_t, bool) [with Descriptor = hash_mapconst char*, unsigned int, capture_id_map_hasher::hash_entry; Allocator = xcallocator; size_t = long unsigned int]’: ../../gcc/hash-map.h:190:72: required from ‘hash_map template-parameter-1-1, template-parameter-1-2, template-parameter-1-3 ::hash_map(size_t, bool) [with Key = const char*; Value = unsigned int; Traits = capture_id_map_hasher; size_t = long unsigned int]’ ../../gcc/genmatch.c:2843:21: required from here ../../gcc/hash-table.h:1234:56: error: call of overloaded ‘ggc_cleared_vec_alloc(size_t)’ is ambiguous m_entries = ggc_cleared_vec_allocvalue_type (size); ^ ../../gcc/hash-table.h:1234:56: note: candidates are: In file included from ../../gcc/genmatch.c:28:0: ../../gcc/ggc.h:233:1: note: T* ggc_cleared_vec_alloc(size_t, const char*, int, const char*) [with T = hash_mapconst char*, unsigned int, capture_id_map_hasher::hash_entry; size_t = long unsigned int] ggc_cleared_vec_alloc (size_t c CXX_MEM_STAT_INFO) ^ In file included from ../../gcc/genmatch.c:32:0: ../../gcc/hash-table.h:203:4: note: T* ggc_cleared_vec_alloc(size_t) [with T = hash_mapconst char*, unsigned int, capture_id_map_hasher::hash_entry; size_t = long unsigned int] T *ggc_cleared_vec_alloc (size_t); ^ ../../gcc/hash-table.h: In instantiation of ‘void hash_tableDescriptor, Allocator, true::expand() [with Descriptor
[Bug lto/45375] [meta-bug] Issues with building Mozilla with LTO
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=45375 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added CC||marxin at gcc dot gnu.org --- Comment #214 from Martin Liška marxin at gcc dot gnu.org --- I've just found ICE for r217480 with LTO and -O2: lto1: internal compiler error: in lto_output_node, at lto-cgraph.c:462 0x7ce411 lto_output_node ../../gcc/lto-cgraph.c:462 0x7ce411 output_symtab() ../../gcc/lto-cgraph.c:974 0x7db276 lto_output() ../../gcc/lto-streamer-out.c:2309 0x814671 write_lto ../../gcc/passes.c:2346 0x8177c1 ipa_write_optimization_summaries(lto_symtab_encoder_d*) ../../gcc/passes.c:2545 0x59512a do_stream_out ../../gcc/lto/lto.c:2475 0x59a41f stream_out ../../gcc/lto/lto.c:2538 0x59a41f lto_wpa_write_files ../../gcc/lto/lto.c:2655 0x59a41f do_whole_program_analysis ../../gcc/lto/lto.c:3323 0x59a41f lto_main() ../../gcc/lto/lto.c:3443 if (tag == LTO_symtab_analyzed_node) gcc_assert (clone_of || !node-clone_of); ^ if (!clone_of) streamer_write_hwi_stream (ob-main_stream, LCC_NOT_FOUND); else streamer_write_hwi_stream (ob-main_stream, ref); If needed I will try to reduce objects that are part of WPA phase. Martin
[Bug lto/63968] [5 Regression] 175.vpr from cpu2000 fails to build with LTO
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63968 --- Comment #2 from Martin Liška marxin at gcc dot gnu.org --- Problem was introduced by adding gcc_assert that guards if we really decrease a key. I'm testing patch that implements slow path: if a key is bigger than current value, we process correct increase operation (deletion + insertion). Old implementation suppress replace operation if a key is bigger and there's no notification about that. bb-reorder output for 175.vpr: lChanging key for bb 5 from -155 to -1015655. Changing key for bb 12 from -533 to -1049033. Changing key for bb 19 from -533 to -1049033. Changing key for bb 22 from -53 to -1004853. Changing key for bb 31 from -1250 to -1126250. Changing key for bb 27 from -533 to -1006133. Changing key for bb 23 from -53 to -1004853. Changing key for bb 50 from -533 to -1049033. Changing key for bb 51 from -53 to -1004853. Changing key for bb 58 from -533 to -1049033. Changing key for bb 61 from -53 to -1004853. Changing key for bb 197 from -27 to -1002727. Changing key for bb 205 from -9 to -1000809. Changing key for bb 70 from -37 to -1003737. Changing key for bb 79 from -37 to -1003737. Changing key for bb 98 from -1003468 to -1001768. Thanks, Martin
[Bug lto/63968] [5 Regression] 175.vpr from cpu2000 fails to build with LTO
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63968 --- Comment #3 from Martin Liška marxin at gcc dot gnu.org --- Created attachment 34050 -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=34050action=edit fh_fix.patch
[Bug ipa/63569] [5.0 Regression] Wrong code with volatile and ICF
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63569 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added CC||marxin at gcc dot gnu.org --- Comment #4 from Martin Liška marxin at gcc dot gnu.org --- Hello. There's suggested patch on mailing list: https://gcc.gnu.org/ml/gcc-patches/2014-10/msg01723.html. Reason why it hasn't been applied is that Richard prefers kind of refactoring for IPA ICF that will cover this case in purer way. Nevertheless, feel free to apply suggested patch if it fixes your issue? Thanks, Martin
[Bug bootstrap/63573] [5 Regression] libgo: ICE building libgo on powerpc-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 --- Comment #20 from Martin Liška marxin at gcc dot gnu.org --- Hello. I've just bootstrapped on ggc110 after r217307 was applied. Can you please verify if the problem still persists? Thanks, Martin
[Bug ipa/63569] [5.0 Regression] Wrong code with volatile and ICF
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63569 --- Comment #6 from Martin Liška marxin at gcc dot gnu.org --- Problem is that IPA ICF contains compare_operand that is called recursively and handles all tree types. Richard correctly pointed that we should split the method to memory-related operand comparison and the rest (declarations,..). I hope I can send the path on Monday-Tuesday next week. Thanks, Martin
[Bug ipa/63598] [5.0 Regression] ICE: in ipa_merge_profiles at ipa-utils.c:396
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63598 --- Comment #4 from Martin Liška marxin at gcc dot gnu.org --- Can you please check if the issue still persists? I would appreciate further information related to PR, or do we have any GCC fam machine I can debug it? Thanks, Martin
[Bug ipa/63856] [5 Regression] ICE: verify_gimple failed: invalid argument to gimple call with -O2 -fPIC
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63856 --- Comment #2 from Martin Liška marxin at gcc dot gnu.org --- I cannot reproduce the bug: ../configure --prefix=/home/marxin/Programming/bin/gcc3 --disable-multilib --enable-languages=c,c++ --disable-bootstrap ./xgcc -B ./ -O2 -fPIC ~/Programming/testcases/PR63856/testcase.c -fdump-ipa-icf-details uname -a Linux marxinbox.suse.cz 3.16.6-2-desktop #1 SMP PREEMPT Mon Oct 20 13:47:22 UTC 2014 (feb42ea) x86_64 x86_64 x86_64 GNU/Linux gcc version 5.0.0 20141121 (experimental) (GCC) ipa-icf-details log: Equal symbols: 1 Fraction of visited symbols: 33.33% debug message: All BBs are equal (equals_private:487) Equals called for:g:f (1:0) (g:f) with result: true Semantic equality hit:g-f Assembler symbol names:g-f g (v2si A, int N) { vector(4) short int D.1840; bb 2: _2 = VIEW_CONVERT_EXPRvector(4) short int(A_1(D)); D.1840 = _2; _6 = (long unsigned int) N_5(D); _7 = _6 * 2; _8 = D.1840 + _7; _9 = *_8; _10 = (int) _9; return _10; } f (v2si A, int N) { vector(4) short int D.1835; bb 2: _2 = VIEW_CONVERT_EXPRvector(4) short int(A_1(D)); D.1835 = _2; _6 = (long unsigned int) N_5(D); _7 = _6 * 2; _8 = D.1835 + _7; _9 = *_8; _10 = (int) _9; return _10; } Thanks, Martin
[Bug lto/63968] [5 Regression] 175.vpr from cpu2000 fails to build with LTO
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63968 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #6 from Martin Liška marxin at gcc dot gnu.org --- Fixed.
[Bug lto/63968] [5 Regression] 175.vpr from cpu2000 fails to build with LTO
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63968 --- Comment #7 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Mon Nov 24 10:25:06 2014 New Revision: 218006 URL: https://gcc.gnu.org/viewcvs?rev=218006root=gccview=rev Log: PR lto/63968 * bb-reorder.c (find_traces_1_round): decreate_key is replaced with replace_key method. * fibonacci_heap.h (fibonacci_heap::insert): New argument. (fibonacci_heap::replace_key_data): Likewise. (fibonacci_heap::replace_key): New method that can even increment key, this operation costs O(log N). (fibonacci_heap::extract_min): New argument. (fibonacci_heap::delete_node): Likewise. Modified: trunk/gcc/ChangeLog trunk/gcc/bb-reorder.c trunk/gcc/fibonacci_heap.h
[Bug ipa/63856] [5 Regression] ICE: verify_gimple failed: invalid argument to gimple call with -O2 -fPIC
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63856 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #4 from Martin Liška marxin at gcc dot gnu.org --- Fixed by r217909.
[Bug bootstrap/63573] [5 Regression] libgo: ICE building libgo on powerpc-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|REOPENED|RESOLVED Resolution|--- |FIXED --- Comment #22 from Martin Liška marxin at gcc dot gnu.org --- Resolved.
[Bug ipa/64060] [5 Regression] r218009 caused FAIL: g++.dg/ipa/devirt-42.C
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64060 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|--- |DUPLICATE --- Comment #1 from Martin Liška marxin at gcc dot gnu.org --- Dup. *** This bug has been marked as a duplicate of bug 64050 ***
[Bug bootstrap/64050] [5 Regression] r218009 causes LTO/PGO bootstrap failure: ICE: in inline_small_functions, at ipa-inline.c:1709
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64050 --- Comment #3 from Martin Liška marxin at gcc dot gnu.org --- *** Bug 64060 has been marked as a duplicate of this bug. ***
[Bug bootstrap/64050] [5 Regression] r218009 causes LTO/PGO bootstrap failure: ICE: in inline_small_functions, at ipa-inline.c:1709
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64050 --- Comment #4 from Martin Liška marxin at gcc dot gnu.org --- Created attachment 34110 -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=34110action=edit Suggested patch v1
[Bug ipa/64068] [5 Regression] ICE: in remove_unreachable_nodes, at ipa.c:546
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64068 --- Comment #1 from Martin Liška marxin at gcc dot gnu.org --- Introduced by r217973: commit ca92a2511ecb05fb7c84df998723c257f23b6ca7 Author: hubicka hubicka@138bc75d-0d04-0410-961f-82ee72b054a4 Date: Sat Nov 22 21:08:07 2014 + * ipa.c (symbol_table::remove_unreachable_nodes): Mark all inline clones as having abstract origin used. * ipa-inline-transform.c (can_remove_node_now_p_1): Drop abstract origin check. (clone_inlined_nodes): Copy abstract originflag. * lto-cgraph.c (compute_ltrans_boundary): Use get_create to get abstract origin node. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@217973 138bc75d-0d04-0410-961f-82ee72b054a4 Martin
[Bug bootstrap/64050] [5 Regression] r218009 causes LTO/PGO bootstrap failure: ICE: in inline_small_functions, at ipa-inline.c:1709
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64050 --- Comment #5 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Tue Nov 25 15:16:27 2014 New Revision: 218048 URL: https://gcc.gnu.org/viewcvs?rev=218048root=gccview=rev Log: 2014-11-25 Martin Liska mli...@suse.cz PR bootstrap/64050 PR ipa/64060 * sreal.c (sreal::operator+): Addition fixed. (sreal::signedless_plus): Negative numbers are handled correctly. (sreal::operator-): Subtraction is fixed. (sreal::signedless_minus): Negative numbers are handled correctly. * sreal.h (sreal::operator): Equal negative numbers are compared correctly. (sreal::shift): New checking asserts are introduced. Operation is fixed. * gcc.dg/plugin/plugin.exp: New plugin. * gcc.dg/plugin/sreal-test-1.c: New test. * gcc.dg/plugin/sreal_plugin.c: New test. Added: trunk/gcc/testsuite/gcc.dg/plugin/sreal-test-1.c trunk/gcc/testsuite/gcc.dg/plugin/sreal_plugin.c Modified: trunk/gcc/ChangeLog trunk/gcc/sreal.c trunk/gcc/sreal.h trunk/gcc/testsuite/ChangeLog trunk/gcc/testsuite/gcc.dg/plugin/plugin.exp
[Bug ipa/64060] [5 Regression] r218009 caused FAIL: g++.dg/ipa/devirt-42.C
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64060 --- Comment #2 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Tue Nov 25 15:16:27 2014 New Revision: 218048 URL: https://gcc.gnu.org/viewcvs?rev=218048root=gccview=rev Log: 2014-11-25 Martin Liska mli...@suse.cz PR bootstrap/64050 PR ipa/64060 * sreal.c (sreal::operator+): Addition fixed. (sreal::signedless_plus): Negative numbers are handled correctly. (sreal::operator-): Subtraction is fixed. (sreal::signedless_minus): Negative numbers are handled correctly. * sreal.h (sreal::operator): Equal negative numbers are compared correctly. (sreal::shift): New checking asserts are introduced. Operation is fixed. * gcc.dg/plugin/plugin.exp: New plugin. * gcc.dg/plugin/sreal-test-1.c: New test. * gcc.dg/plugin/sreal_plugin.c: New test. Added: trunk/gcc/testsuite/gcc.dg/plugin/sreal-test-1.c trunk/gcc/testsuite/gcc.dg/plugin/sreal_plugin.c Modified: trunk/gcc/ChangeLog trunk/gcc/sreal.c trunk/gcc/sreal.h trunk/gcc/testsuite/ChangeLog trunk/gcc/testsuite/gcc.dg/plugin/plugin.exp
[Bug bootstrap/64050] [5 Regression] r218009 causes LTO/PGO bootstrap failure: ICE: in inline_small_functions, at ipa-inline.c:1709
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64050 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #6 from Martin Liška marxin at gcc dot gnu.org --- Resolved.
[Bug ipa/63851] [5 Regression] ipa-icf miscompiles gfortran.dg/assumed_rank_(8|9|10).f90 at -O2 and above
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63851 --- Comment #2 from Martin Liška marxin at gcc dot gnu.org --- OK, I can reproduce the problem on x86_64 with following simple patch applied: diff --git a/gcc/ipa-icf.c b/gcc/ipa-icf.c index 4875dec..c985052 100644 --- a/gcc/ipa-icf.c +++ b/gcc/ipa-icf.c @@ -606,6 +606,12 @@ sem_function::merge (sem_item *alias_item) create_thunk = true; } + if (create_alias ) + { +create_thunk = true; +create_alias = false; + } + There's a pair of functions 'g' and 'h' that are proved by IPA ICF to be equal and thunk is created (darwin does not have alias support). Semantic equality hit:g-h Assembler symbol names:g.3324-h.3321 where 'h' looks is created as tail-call: h (struct array7_integer(kind=4) restrict x) { bb 2: g (x_2(D)); [tail call] return; } and MAIN__: bb 8: # kk_1 = PHI kk_36(6), kk_39(7) *kk_1 = 489; desc.6.dtype = 264; desc.6.data = kk_1; h (desc.6); [static-chain: FRAME.15] desc.6 ={v} {CLOBBER}; j.8_45 = FRAME.15.j; if (j.8_45 != 1) goto bb 9; else goto bb 10; It looks fine, but after inlining is done, we are given: assumed_rank_8.f90.063t.copyrename2: MAIN__: ... bb 24: # kk_11 = PHI kk_9(22), kk_10(23) *kk_11 = 489; desc.6.dtype = 264; desc.6.data = kk_11; g (desc.6); desc.6 ={v} {CLOBBER}; j.8_12 = FRAME.15.j; if (j.8_12 != 1) goto bb 25; else goto bb 26; Is missing [static-chain: FRAME.15] in 'g (desc.6);' problematic in this context? Thanks, Martin
[Bug bootstrap/63573] [5 Regression] libgo: ICE building libgo on powerpc-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 --- Comment #25 from Martin Liška marxin at gcc dot gnu.org --- There's updated version of Honza's patch that fixes testcase instroduced in https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573#c23: diff --git a/gcc/tree-inline.c b/gcc/tree-inline.c index d4864ae..0036f15 100644 --- a/gcc/tree-inline.c +++ b/gcc/tree-inline.c @@ -1617,8 +1617,12 @@ remap_gimple_stmt (gimple stmt, copy_body_data *id) /* Clear flags that need revisiting. */ if (gcall *call_stmt = dyn_cast gcall * (copy)) -if (gimple_call_tail_p (call_stmt)) - gimple_call_set_tail (call_stmt, false); +{ + if (gimple_call_tail_p (call_stmt)) +gimple_call_set_tail (call_stmt, false); + if (gimple_call_from_thunk_p (call_stmt)) +gimple_call_set_from_thunk (call_stmt, false); +} /* Remap the region numbers for __builtin_eh_{pointer,filter}, RESX and EH_DISPATCH. */ Honza, can we commit this hunk? Thanks, Martin
[Bug bootstrap/64086] [5 Regression] building patched libstdc++ on powerpc64-linux-gnu gets ICE in expand_expr_addr_expr_1, at expr.c:7716
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64086 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |DUPLICATE --- Comment #2 from Martin Liška marxin at gcc dot gnu.org --- Duplicate. *** This bug has been marked as a duplicate of bug 63573 ***
[Bug bootstrap/63573] [5 Regression] libgo: ICE building libgo on powerpc-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added CC||redi at gcc dot gnu.org --- Comment #26 from Martin Liška marxin at gcc dot gnu.org --- *** Bug 64086 has been marked as a duplicate of this bug. ***
[Bug bootstrap/63573] [5 Regression] libgo: ICE building libgo on powerpc-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|RESOLVED|REOPENED Resolution|FIXED |--- --- Comment #27 from Martin Liška marxin at gcc dot gnu.org --- Reopened.
[Bug ipa/64218] [5 Regression] ICE: Segmentation fault (symtab_node::get_alias_target()) running Boost testsuite
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64218 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added CC||hubicka at gcc dot gnu.org Assignee|marxin at gcc dot gnu.org |unassigned at gcc dot gnu.org --- Comment #6 from Martin Liška marxin at gcc dot gnu.org --- Hello. You are Markus right, that it started with r218048, but it's actually caused by: r218024. Reason for that is that sreal, utilized for inlining purpose, was broken between r218008-r218048. Problematic commit: 2014-11-22 Jan Hubicka hubi...@ucw.cz PR ipa/63671 * ipa-inline-transform.c (can_remove_node_now_p_1): Handle alises and -fno-devirtualize more carefully. (can_remove_node_now_p): Update. Thanks, Martin
[Bug ipa/64146] [5 Regression] ipa-icf breaks gold dynamic_test_2 test
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64146 --- Comment #4 from Martin Liška marxin at gcc dot gnu.org --- Hello. Test case you described should be covered by IPA ICF, where we create a non-interposable alias of a original symbol that is target of newly created thunk. There's -fpic snippet: _Z8test_barv: .LFB3: .cfi_startproc pushq%rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 movq%rsp, %rbp .cfi_def_cfa_register 6 callbar@PLT popq%rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE3: .size_Z8test_barv, .-_Z8test_barv .set_Z8test_barv.localalias.0,_Z8test_barv .identGCC: (GNU) 5.0.0 20141209 (experimental) .section.note.GNU-stack,,@progbits But it's probably not enough, what exactly means binds_local_p ? Thanks, Martin
[Bug ipa/64253] New: [5 Regression] IPA inline analysis processes a code transform operation
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64253 Bug ID: 64253 Summary: [5 Regression] IPA inline analysis processes a code transform operation Product: gcc Version: 5.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: ipa Assignee: unassigned at gcc dot gnu.org Reporter: marxin at gcc dot gnu.org CC: hubicka at ucw dot cz Hello. I created this issue as underlying problem for PR63909, where one can find a testcase. Problem is that a BB is split here: #0 gsi_split_seq_before (i=0x7fffd550, pnew_seq=0x7fffd528) at ../../gcc/gimple-iterator.c:429 #1 0x00b95a2a in gimple_split_block (bb=0x76c41548, stmt=0x0) at ../../gcc/tree-cfg.c:5707 #2 0x007563cf in split_block (bb=0x76c41548, i=i@entry=0x0) at ../../gcc/cfghooks.c:508 #3 0x00756b44 in split_block_after_labels (bb=optimized out) at ../../gcc/cfghooks.c:549 #4 make_forwarder_block (bb=optimized out, redirect_edge_p=redirect_edge_p@entry=0x75d4e0 mfb_keep_just(edge_def*), new_bb_cbk=new_bb_cbk@entry=0x0) at ../../gcc/cfghooks.c:842 #5 0x0076085a in create_preheader (loop=0x76d56948, flags=optimized out) at ../../gcc/cfgloopmanip.c:1563 #6 0x00760aea in create_preheaders (flags=1) at ../../gcc/cfgloopmanip.c:1613 #7 0x009bc6b0 in apply_loop_flags (flags=15) at ../../gcc/loop-init.c:75 #8 0x009bc7d3 in loop_optimizer_init (flags=15) at ../../gcc/loop-init.c:136 #9 0x00957914 in estimate_function_body_sizes (node=0x76c47620, early=false) at ../../gcc/ipa-inline-analysis.c:2480 #10 0x0095948b in compute_inline_parameters (node=0x76c47620, early=false) at ../../gcc/ipa-inline-analysis.c:2907 #11 0x0095bd88 in inline_analyze_function (node=0x76c47620) at ../../gcc/ipa-inline-analysis.c:3994 #12 0x0095bed3 in inline_generate_summary () at ../../gcc/ipa-inline-analysis.c:4045 #13 0x00a70b71 in execute_ipa_summary_passes (ipa_pass=0x1dcb9e0) Thanks, Martin
[Bug ipa/64253] [5 Regression] IPA inline analysis processes a code transform operation
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64253 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added CC||marxin at gcc dot gnu.org Target Milestone|--- |5.0
[Bug ipa/63909] [5 Regression] ICE: SIGSEGV in ipa_icf_gimple::func_checker::compare_bb()
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63909 --- Comment #2 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Wed Dec 10 14:07:47 2014 New Revision: 218578 URL: https://gcc.gnu.org/viewcvs?rev=218578root=gccview=rev Log: PR ipa/63909 * gimple-iterator.h (gsi_start_bb_nondebug): New function. * ipa-icf-gimple.c (func_checker::compare_bb): Correct iteration replaces loop based on precomputed number of non-debug statements. * gcc.dg/ipa/pr63909.c: New test. Added: trunk/gcc/testsuite/gcc.dg/ipa/pr63909.c Modified: trunk/gcc/ChangeLog trunk/gcc/gimple-iterator.h trunk/gcc/ipa-icf-gimple.c trunk/gcc/testsuite/ChangeLog
[Bug ipa/63909] [5 Regression] ICE: SIGSEGV in ipa_icf_gimple::func_checker::compare_bb()
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63909 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #3 from Martin Liška marxin at gcc dot gnu.org --- Fixed.
[Bug c++/64266] New: Can GCC produce local mergeable symbols for *.__FUNCTION__ and *.__PRETTY_FUNCTION__ function.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64266 Bug ID: 64266 Summary: Can GCC produce local mergeable symbols for *.__FUNCTION__ and *.__PRETTY_FUNCTION__ function. Product: gcc Version: 5.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: marxin at gcc dot gnu.org CC: jason at gcc dot gnu.org Created attachment 34250 -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=34250action=edit test case For the following testcase: extern C { extern int printf (char *, ...); } class a { public: void sub (int i) { printf (__FUNCTION__ = %s\n, __FUNCTION__); printf (__PRETTY_FUNCTION__ = %s\n, __PRETTY_FUNCTION__); } void sub() { printf (__FUNCTION__ = %s\n, __FUNCTION__); } }; int main (void) { a ax; ax.sub (0); ax.sub (); return 0; } Unlink clang, GCC produces a local symbol residing in .symtab and string values are not in mergeable section: $ g++ ~/Programming/testcases/pretty-function.c -o a.o $ readelf -s a.o --wide | grep PRE 15: 0040071017 OBJECT LOCAL DEFAULT 14 _ZZN1a3subEiE19__PRETTY_FUNCTION__ $ readelf -p '.rodata' a.out String dump of section '.rodata': [10] __FUNCTION__ = %s [23] __PRETTY_FUNCTION__ = %s [3d] sub [50] void a::sub(int) [61] sub and clang produces: $ clang++ ~/Programming/testcases/pretty-function.c -o a.o $ readelf -s a.out --wide | grep PRE (nothing) $ readelf -p '.rodata' a.o String dump of section '.rodata': [ 4] __FUNCTION__ = %s [17] sub [1b] __PRETTY_FUNCTION__ = %s [35] void a::sub(int) I'm wondering if we can also process such kind of optimization. For Inkscape (compiled with -O2), there are following differences: section portionsizesizecompared comparison .rodata 15.69 % 2.41 MB 2523277 2291412 90.81 % .strtab 13.06 % 2.00 MB 2099988 1933845 92.09 % Where column 'size' is related to GCC and 'compared' is size generated by clang. Thanks, Martin
[Bug other/64278] [5 Regression] /sreal.c:254:22: error: call of overloaded 'abs(const int64_t)' is ambiguous
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64278 --- Comment #2 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Tue Dec 16 14:55:29 2014 New Revision: 218779 URL: https://gcc.gnu.org/viewcvs?rev=218779root=gccview=rev Log: Fix for PR ipa/64278 * sreal.c (sreal::operator*): Replace std::abs with absu_hwi. Modified: trunk/gcc/ChangeLog trunk/gcc/sreal.c
[Bug other/64278] [5 Regression] /sreal.c:254:22: error: call of overloaded 'abs(const int64_t)' is ambiguous
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64278 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|--- |FIXED --- Comment #3 from Martin Liška marxin at gcc dot gnu.org --- Resolved.
[Bug ipa/63851] [5 Regression] ipa-icf miscompiles gfortran.dg/assumed_rank_(8|9|10).f90 at -O2 and above
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63851 --- Comment #5 from Martin Liška marxin at gcc dot gnu.org --- Yes, IPA ICF should respect 'restrict' attribute. May I ask you to rerun test suite with applied: diff --git a/gcc/ipa-icf-gimple.c b/gcc/ipa-icf-gimple.c index ec0290a..98f38ee 100644 --- a/gcc/ipa-icf-gimple.c +++ b/gcc/ipa-icf-gimple.c @@ -185,6 +185,9 @@ bool func_checker::compatible_types_p (tree t1, tree t2, if (TREE_CODE (t1) != TREE_CODE (t2)) return return_false_with_msg (different tree types); + if (TYPE_RESTRICT (t1) != TYPE_RESTRICT (t2)) +return return_false_with_msg (restrict flags are different); + if (!types_compatible_p (t1, t2)) return return_false_with_msg (types are not compatible); Thanks, Martin
[Bug tree-optimization/64330] [5 Regression] IPA-ICF merges const exported vars that could be addressable in other TUs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64330 --- Comment #8 from Martin Liška marxin at gcc dot gnu.org --- Thank you for the missing externally visible attribute. I've been testing following patch: diff --git a/gcc/ipa-icf.c b/gcc/ipa-icf.c index b193200..0685019 100644 --- a/gcc/ipa-icf.c +++ b/gcc/ipa-icf.c @@ -1131,8 +1131,12 @@ sem_variable::parse (varpool_node *node, bitmap_obstack *stack) tree decl = node-decl; bool readonly = TYPE_P (decl) ? TYPE_READONLY (decl) : TREE_READONLY (decl); - bool can_handle = readonly (DECL_VIRTUAL_P (decl) -|| !TREE_ADDRESSABLE (decl)); + if (!readonly) +return NULL; + + bool can_handle = DECL_VIRTUAL_P (decl) + || flag_merge_constants = 2 + || (!TREE_ADDRESSABLE (decl) !node-externally_visible); if (!can_handle) return NULL; As soon as tests finish, I will send it to ML. Martin
[Bug ipa/64146] [5 Regression] ipa-icf breaks gold dynamic_test_2 test
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64146 --- Comment #7 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Thu Dec 18 12:02:22 2014 New Revision: 218860 URL: https://gcc.gnu.org/viewcvs?rev=218860root=gccview=rev Log: Fix for PR ipa/64146 PR ipa/64146 * ipa-icf.c (sem_function::merge): Check for decl_binds_to_current_def_p is newly added to merge operation. * g++.dg/ipa/pr64146.C: New test. Added: trunk/gcc/testsuite/g++.dg/ipa/pr64146.C Modified: trunk/gcc/ChangeLog trunk/gcc/ipa-icf.c trunk/gcc/testsuite/ChangeLog
[Bug ipa/64146] [5 Regression] ipa-icf breaks gold dynamic_test_2 test
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64146 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #8 from Martin Liška marxin at gcc dot gnu.org --- Fixed in 5.0.0.
[Bug bootstrap/63573] [5 Regression] libgo: ICE building libgo on powerpc-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 --- Comment #29 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Thu Dec 18 12:06:34 2014 New Revision: 218861 URL: https://gcc.gnu.org/viewcvs?rev=218861root=gccview=rev Log: Fix for PR bootstrap/63573. PR bootstrap/63573 * tree-inline.c (remap_gimple_stmt): Handle gimple_call_from_thunk_p predicate. Modified: trunk/gcc/ChangeLog trunk/gcc/tree-inline.c
[Bug bootstrap/63573] [5 Regression] libgo: ICE building libgo on powerpc-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63573 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|REOPENED|RESOLVED Resolution|--- |FIXED --- Comment #30 from Martin Liška marxin at gcc dot gnu.org --- Fixed in 5.0.0.
[Bug tree-optimization/64330] [5 Regression] IPA-ICF merges const exported vars that could be addressable in other TUs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64330 --- Comment #10 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Thu Dec 18 13:32:18 2014 New Revision: 218864 URL: https://gcc.gnu.org/viewcvs?rev=218864root=gccview=rev Log: Fix for PR64330. PR tree-optimization/64330 * ipa-icf.c (sem_variable::parse): Add checking for externally visible symbols and do not introduce an alias for an external declaration. Modified: trunk/gcc/ChangeLog trunk/gcc/ipa-icf.c
[Bug tree-optimization/64330] [5 Regression] IPA-ICF merges const exported vars that could be addressable in other TUs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64330 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #11 from Martin Liška marxin at gcc dot gnu.org --- Fixed in 5.0.0.
[Bug ipa/63851] [5 Regression] ipa-icf miscompiles gfortran.dg/assumed_rank_(8|9|10).f90 at -O2 and above
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63851 --- Comment #11 from Martin Liška marxin at gcc dot gnu.org --- Hello. The problem is caused by missing static-chain in newly created GIMPLE_CALL in expand_thunk: fpi (struct array7_integer(kind=4) xx1, struct array7_t yy1) { bb 2: fpa (xx1_2(D), yy1_3(D)); [tail call] return; } where: main (integer(kind=4) argc, character(kind=1) * * argv) { ... fpa (desc.2, desc.3); [static-chain: FRAME.7] fpi (desc.4, desc.5); [static-chain: FRAME.7] ... } I've been testing following patch that stops ICF for such kind of situations: diff --git a/gcc/ipa-icf.c b/gcc/ipa-icf.c index b193200..7faaf56 100644 --- a/gcc/ipa-icf.c +++ b/gcc/ipa-icf.c @@ -685,6 +685,14 @@ sem_function::merge (sem_item *alias_item) return 0; } + if (DECL_STATIC_CHAIN (alias-decl)) +{ + if (dump_file) + fprintf (dump_file, Thunk creation is risky for static-chain functions.\n\n); + + return 0; +} + alias-icf_merged = true; ipa_merge_profiles (local_original, alias); alias-create_wrapper (local_original); Thanks, Martin
[Bug ipa/63569] [5.0 Regression] Wrong code with volatile and ICF
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63569 --- Comment #11 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Fri Dec 19 12:40:50 2014 New Revision: 218949 URL: https://gcc.gnu.org/viewcvs?rev=218949root=gccview=rev Log: Fix for PR ipa/63569. PR ipa/63569 * gcc.dg/ipa/pr63569.c: New test. PR ipa/63569 * ipa-icf-gimple.c (func_checker::compare_operand): Add missing comparison for volatile flag. Added: trunk/gcc/testsuite/gcc.dg/ipa/pr63569.c Modified: trunk/gcc/ChangeLog trunk/gcc/ipa-icf-gimple.c trunk/gcc/testsuite/ChangeLog
[Bug ipa/63569] [5.0 Regression] Wrong code with volatile and ICF
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63569 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|ASSIGNED|RESOLVED Resolution|--- |FIXED --- Comment #12 from Martin Liška marxin at gcc dot gnu.org --- Fixed in 5.0.0.
[Bug ipa/63851] [5 Regression] ipa-icf miscompiles gfortran.dg/assumed_rank_(8|9|10).f90 at -O2 and above
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63851 --- Comment #14 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Tue Dec 23 09:30:20 2014 New Revision: 219042 URL: https://gcc.gnu.org/viewcvs?rev=219042root=gccview=rev Log: Fix for PR ipa/63851 and ipa/63852. PR ipa/63851 PR ipa/63852 * ipa-icf.c (sem_function::merge): Ignore merge operation for a thunk created from static chain. * ipa-icf-gimple.c (func_checker::compatible_types_p): Verify that types have same restrict flag. Modified: trunk/gcc/ChangeLog trunk/gcc/ipa-icf-gimple.c trunk/gcc/ipa-icf.c
[Bug ipa/63852] [5 regression] acats failures on x86_64-apple-darwin14
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63852 --- Comment #4 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Tue Dec 23 09:30:20 2014 New Revision: 219042 URL: https://gcc.gnu.org/viewcvs?rev=219042root=gccview=rev Log: Fix for PR ipa/63851 and ipa/63852. PR ipa/63851 PR ipa/63852 * ipa-icf.c (sem_function::merge): Ignore merge operation for a thunk created from static chain. * ipa-icf-gimple.c (func_checker::compatible_types_p): Verify that types have same restrict flag. Modified: trunk/gcc/ChangeLog trunk/gcc/ipa-icf-gimple.c trunk/gcc/ipa-icf.c
[Bug ipa/63852] [5 regression] acats failures on x86_64-apple-darwin14
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63852 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #5 from Martin Liška marxin at gcc dot gnu.org --- Fixed in 5.0.0.
[Bug ipa/63851] [5 Regression] ipa-icf miscompiles gfortran.dg/assumed_rank_(8|9|10).f90 at -O2 and above
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63851 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #15 from Martin Liška marxin at gcc dot gnu.org --- Fixed in 5.0.0.
[Bug ipa/64801] [5 Regression] kernel build failure due to ICF
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64801 --- Comment #1 from Martin Liška marxin at gcc dot gnu.org --- You are right, the problem is hidden in cooperation between IPA inliner and ICF. If I run the test w/o ICF, inliner sets NULL to the fsp_detect FUNCTION_DECL: #0 0x0074541e in symtab_node::unregister (this=0x76c47620) at ../../gcc/symtab.c:407 #1 0x0074b0ef in cgraph_node::remove (this=0x76c47620) at ../../gcc/cgraph.c:1741 #2 0x00b891b9 in expand_call_inline (id=0x7fffd5c0, stmt=0x76d54aa0, bb=optimized out) at ../../gcc/tree-inline.c:4762 #3 gimple_expand_calls_inline (id=0x7fffd5c0, bb=optimized out) at ../../gcc/tree-inline.c:4787 so that cgraph_node::get(decl) == NULL here: if (symtab-state != LTO_STREAMING) │1784{ B+│1785 n = cgraph_node::get (decl); │1786 if (!n │1787 || (!n-clones !n-clone_of !n-global.inlined_to │1788 (symtab-global_info_ready │1789 (TREE_ASM_WRITTEN (n-decl) │1790 || DECL_EXTERNAL (n-decl) │1791 || !n-analyzed │1792 || (!flag_wpa n-in_other_partition) │1793release_body (); │1794} That's the reason why the body is not removed. On the contrary, with ICF, aforementioned condition is satisfied and fsp_detect's body is removed. I think the situation after IPA ICF is correct: fsp_detect/2 (fsp_detect) @0x76c47620 Type: function definition analyzed Visibility: external public References: Referring: Availability: available First run: 0 Function flags: body Called by: elantech_detect/1 (1.00 per call) psmouse_extensions/3 (1.00 per call) Calls: elantech_detect/1 (elantech_detect) @0x76c47498 Type: function definition analyzed Visibility: externally_visible public References: Referring: Availability: available First run: 0 Function flags: body icf_merged Called by: Calls: fsp_detect/2 (1.00 per call) Can you please help me Honza? Thanks, Martin
[Bug ipa/64776] [5 Regression] FAIL: gcc.dg/ipa/pr64307.c (internal compiler error) on x86_64-apple-darwin14
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64776 --- Comment #9 from Martin Liška marxin at gcc dot gnu.org --- May I please Dominique to put 'debug_tree(arg);' after following statement: error (invalid argument to gimple call); And send the stderr output? Thanks, Martin
[Bug ipa/64559] [5 Regression] ICE at -Os on x86_64-linux-gnu in remove_unreachable_nodes, at ipa.c:582
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64559 --- Comment #4 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Thu Jan 15 17:29:23 2015 New Revision: 219672 URL: https://gcc.gnu.org/viewcvs?rev=219672root=gccview=rev Log: Fix for PR64068 and PR64559. * g++.dg/ipa/pr64068.C: New test. * gcc.dg/ipa/PR64559.c: New test. PR ipa/64068 PR ipa/64559 * ipa.c (symbol_table::remove_unreachable_nodes): Do not put abstract origins into boundary. Added: trunk/gcc/testsuite/g++.dg/ipa/pr64068.C trunk/gcc/testsuite/gcc.dg/ipa/PR64559.c Modified: trunk/gcc/ChangeLog trunk/gcc/ipa.c trunk/gcc/testsuite/ChangeLog
[Bug ipa/64068] [5 Regression] ICE: in remove_unreachable_nodes, at ipa.c:546
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64068 Martin Liška marxin at gcc dot gnu.org changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|--- |FIXED --- Comment #10 from Martin Liška marxin at gcc dot gnu.org --- Fixed in 5.0.0.
[Bug ipa/64068] [5 Regression] ICE: in remove_unreachable_nodes, at ipa.c:546
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64068 --- Comment #9 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Thu Jan 15 17:29:23 2015 New Revision: 219672 URL: https://gcc.gnu.org/viewcvs?rev=219672root=gccview=rev Log: Fix for PR64068 and PR64559. * g++.dg/ipa/pr64068.C: New test. * gcc.dg/ipa/PR64559.c: New test. PR ipa/64068 PR ipa/64559 * ipa.c (symbol_table::remove_unreachable_nodes): Do not put abstract origins into boundary. Added: trunk/gcc/testsuite/g++.dg/ipa/pr64068.C trunk/gcc/testsuite/gcc.dg/ipa/PR64559.c Modified: trunk/gcc/ChangeLog trunk/gcc/ipa.c trunk/gcc/testsuite/ChangeLog
[Bug ipa/64068] [5 Regression] ICE: in remove_unreachable_nodes, at ipa.c:546
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64068 --- Comment #7 from Martin Liška marxin at gcc dot gnu.org --- I can confirm that the patch can compile all Chromium source files (unfortunately I hit another issued during LINK phase: PR64583). Apart from that, both testcases from this issue and PR64559 work (I prepared patch which installs these testcases). I run regression tests for c,c++ and no new regression is introduced. Martin
[Bug ipa/64068] [5 Regression] ICE: in remove_unreachable_nodes, at ipa.c:546
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64068 --- Comment #8 from Martin Liška marxin at gcc dot gnu.org --- Created attachment 34456 -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=34456action=edit Fix with new 2 testcases
[Bug lto/63704] -flto internal compiler error: in mems_in_disjoint_alias_sets_p, at alias.c:398
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63704 --- Comment #6 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Thu Jan 15 16:03:05 2015 New Revision: 219664 URL: https://gcc.gnu.org/viewcvs?rev=219664root=gccview=rev Log: Backport from mainline 2014-11-27 Richard Biener rguent...@suse.de PR middle-end/63704 * alias.c (mems_in_disjoint_alias_sets_p): Remove assert and instead return false when !fstrict-aliasing. Modified: branches/gcc-4_9-branch/gcc/ChangeLog branches/gcc-4_9-branch/gcc/alias.c
[Bug lto/63704] -flto internal compiler error: in mems_in_disjoint_alias_sets_p, at alias.c:398
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63704 --- Comment #5 from Martin Liška marxin at gcc dot gnu.org --- Author: marxin Date: Thu Jan 15 16:02:28 2015 New Revision: 219663 URL: https://gcc.gnu.org/viewcvs?rev=219663root=gccview=rev Log: Backport from mainline 2014-11-27 Richard Biener rguent...@suse.de PR middle-end/63704 * alias.c (mems_in_disjoint_alias_sets_p): Remove assert and instead return false when !fstrict-aliasing. Modified: branches/gcc-4_8-branch/gcc/ChangeLog branches/gcc-4_8-branch/gcc/alias.c
[Bug c++/64500] push_to_top_level() shows up high during Chromium build.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64500 --- Comment #1 from Martin Liška marxin at gcc dot gnu.org --- Created attachment 34498 -- https://gcc.gnu.org/bugzilla/attachment.cgi?id=34498action=edit perf report for the testcase