https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93583

--- Comment #10 from Martin Liška <marxin at gcc dot gnu.org> ---
(In reply to Richard Biener from comment #9)
> Testing the patch.  Points to a memleak in rs6000-driver.c:
> 
>       cache = detect_caches_linux ();
>       /* PPC Linux does not provide any cache information yet.  */
>       cache = "";
> 
> but that function calls describe_cache which eventually does
> 
>   return concat (l1size, " ", line, " ", l2size, " ", NULL);
> 
> of course not really important if just called once.

Hm, it fails later:

Program received signal SIGSEGV, Segmentation fault.
update_bb_for_insn_chain (end=0x3fffaf854c80, end=0x3fffaf854c80,
bb=0x3fffaf614e68, begin=<optimized out>) at ../../gcc/cfgrtl.c:538
538         if (!BARRIER_P (insn))
Missing separate debuginfos, use: debuginfo-install
glibc-2.17-260.el7_6.5.ppc64le gmp-6.0.0-15.el7.ppc64le
libmpc-1.0.1-3.el7.ppc64le mpfr-3.1.1-4.el7.ppc64le
(gdb) bt
#0  update_bb_for_insn_chain (end=0x3fffaf854c80, end=0x3fffaf854c80,
bb=0x3fffaf614e68, begin=<optimized out>) at ../../gcc/cfgrtl.c:538
#1  update_bb_for_insn (bb=0x3fffaf614e68) at ../../gcc/cfgrtl.c:548
#2  0x00000000102675f0 in expand_gimple_cond (stmt=0x3fffad17bfe0,
bb=0x3fffaf614e68) at ../../gcc/cfgexpand.c:2540
#3  expand_gimple_basic_block (bb=<optimized out>, disable_tail_calls=false) at
../../gcc/cfgexpand.c:5742
#4  0x0000000010269f08 in (anonymous namespace)::pass_expand::execute
(this=<optimized out>, fun=0x3fffaf5a7fe0) at ../../gcc/cfgexpand.c:6542
#5  0x00000000107e9180 in execute_one_pass (pass=0x11f1ca20) at
../../gcc/passes.c:2500
#6  0x00000000107ea2e4 in execute_pass_list_1 (pass=0x11f1ca20) at
../../gcc/passes.c:2588
#7  0x00000000107ea388 in execute_pass_list (fn=<optimized out>,
pass=<optimized out>) at ../../gcc/passes.c:2599
#8  0x00000000102b84ec in cgraph_node::expand (this=0x3fffaf5e74b8) at
../../gcc/context.h:48
#9  0x00000000102ba09c in expand_all_functions () at
../../gcc/cgraphunit.c:2454
#10 symbol_table::compile (this=0x3fffaf280000) at ../../gcc/cgraphunit.c:2804
#11 0x00000000101b8918 in lto_main () at ../../gcc/lto/lto.c:658
#12 0x0000000010913cfc in compile_file () at ../../gcc/toplev.c:458
#13 0x0000000010186c9c in do_compile () at ../../gcc/toplev.c:2273
#14 toplev::main (this=0x3fffffffec80, argc=<optimized out>, argv=<optimized
out>) at ../../gcc/toplev.c:2412
#15 0x0000000010188ed8 in main (argc=<optimized out>, argv=0x3ffffffff0a8) at
../../gcc/main.c:39

Maybe we should drop the MALLOC attribute in IPA SRA where we make the function
void?

Reply via email to