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

--- Comment #19 from Marc Glisse <glisse at gcc dot gnu.org> ---
(In reply to Joost VandeVondele from comment #17)
> Thanks Marc, I don't have write access, but I can try to dg-ify the testcase
> from comment #3.. however, first test, it still seems to contain a call to
> builtin_malloc at -O2, seems to work at -O3... expected ?

Yes, at -O2 you don't have a call to memset, so my patch does nothing. It is
the same as my C++ testcase basically, so we don't really need the extra
testcase.

> Also, my nightly CP2K tester fails with :
> 
> 0xa63a0f crash_signal
>         ../../gcc/gcc/toplev.c:337
> 0x871f76 bb_seq_addr
>         ../../gcc/gcc/gimple.h:1389
> 0x871f76 gsi_start_bb
>         ../../gcc/gcc/gimple-iterator.h:118
> 0x871f76 gsi_for_stmt(gimple_statement_base*)
>         ../../gcc/gcc/gimple-iterator.c:620
> 0xbfe1c1 handle_builtin_memset
>         ../../gcc/gcc/tree-ssa-strlen.c:1653
> 0xbfe1c1 strlen_optimize_stmt
>         ../../gcc/gcc/tree-ssa-strlen.c:1917
> 0xbfe1c1 strlen_dom_walker::before_dom_children(basic_block_def*)
>         ../../gcc/gcc/tree-ssa-strlen.c:2096
> 0xfa483a dom_walker::walk(basic_block_def*)
>         ../../gcc/gcc/domwalk.c:177
> 0xbf963d execute
>         ../../gcc/gcc/tree-ssa-strlen.c:2170
> Please submit a full bug report,
> 
> which I suppose is related to this patch... I'll see if I can get a testcase.

Yes, please open a new PR with the testcase and Cc: me, thanks.

Reply via email to