public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "zsojka at seznam dot cz" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/107956] New: [12/13 Regression] ICE: SIGSEGV in contains_struct_check (tree.h:3641) with -fsanitize=float-cast-overflow -ftree-slp-vectorize -fexceptions
Date: Sat, 03 Dec 2022 14:20:35 +0000	[thread overview]
Message-ID: <bug-107956-4@http.gcc.gnu.org/bugzilla/> (raw)

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

            Bug ID: 107956
           Summary: [12/13 Regression] ICE: SIGSEGV in
                    contains_struct_check (tree.h:3641) with
                    -fsanitize=float-cast-overflow -ftree-slp-vectorize
                    -fexceptions
           Product: gcc
           Version: 13.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: zsojka at seznam dot cz
  Target Milestone: ---
              Host: x86_64-pc-linux-gnu
            Target: x86_64-pc-linux-gnu

Created attachment 54007
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=54007&action=edit
reduced testcase

Compiler output:
$ x86_64-pc-linux-gnu-gcc -O -fsanitize=float-cast-overflow
-fno-delete-dead-exceptions -ftree-slp-vectorize -fexceptions -mavx512f
testcase.c -wrapper valgrind,-q
==25396== Invalid read of size 2
==25396==    at 0x2523A88: contains_struct_check (tree.h:3641)
==25396==    by 0x2523A88: vect_recog_mask_conversion_pattern(vec_info*,
_stmt_vec_info*, tree_node**) (tree-vect-patterns.cc:4967)
==25396==    by 0x2524C98: vect_pattern_recog_1(vec_info*, vect_recog_func*,
_stmt_vec_info*) (tree-vect-patterns.cc:6153)
==25396==    by 0x252C491: vect_pattern_recog(vec_info*)
(tree-vect-patterns.cc:6310)
==25396==    by 0x165225B: vect_slp_analyze_bb_1 (tree-vect-slp.cc:7310)
==25396==    by 0x165225B: vect_slp_region(vec<basic_block_def*, va_heap,
vl_ptr>, vec<data_reference*, va_heap, vl_ptr>, vec<int, va_heap, vl_ptr>*,
unsigned int, loop*) (tree-vect-slp.cc:7419)
==25396==    by 0x165450C: vect_slp_bbs(vec<basic_block_def*, va_heap, vl_ptr>
const&, loop*) (tree-vect-slp.cc:7610)
==25396==    by 0x1654786: vect_slp_function(function*) (tree-vect-slp.cc:7698)
==25396==    by 0x165D3C1: (anonymous
namespace)::pass_slp_vectorize::execute(function*) (tree-vectorizer.cc:1532)
==25396==    by 0x1294D1A: execute_one_pass(opt_pass*) (passes.cc:2644)
==25396==    by 0x129560F: execute_pass_list_1(opt_pass*) (passes.cc:2753)
==25396==    by 0x1295621: execute_pass_list_1(opt_pass*) (passes.cc:2754)
==25396==    by 0x1295621: execute_pass_list_1(opt_pass*) (passes.cc:2754)
==25396==    by 0x1295648: execute_pass_list(function*, opt_pass*)
(passes.cc:2764)
==25396==  Address 0x0 is not stack'd, malloc'd or (recently) free'd
==25396== 
during GIMPLE pass: slp
testcase.c: In function 'foo':
testcase.c:5:1: internal compiler error: Segmentation fault
    5 | foo (V v)
      | ^~~
0x139d00f crash_signal
        /repo/gcc-trunk/gcc/toplev.cc:314
0x2523a88 contains_struct_check(tree_node*, tree_node_structure_enum, char
const*, int, char const*)
        /repo/gcc-trunk/gcc/tree.h:3641
0x2523a88 vect_recog_mask_conversion_pattern
        /repo/gcc-trunk/gcc/tree-vect-patterns.cc:4967
0x2524c98 vect_pattern_recog_1
        /repo/gcc-trunk/gcc/tree-vect-patterns.cc:6153
0x252c491 vect_pattern_recog(vec_info*)
        /repo/gcc-trunk/gcc/tree-vect-patterns.cc:6310
0x165225b vect_slp_analyze_bb_1
        /repo/gcc-trunk/gcc/tree-vect-slp.cc:7310
0x165225b vect_slp_region
        /repo/gcc-trunk/gcc/tree-vect-slp.cc:7419
0x165450c vect_slp_bbs
        /repo/gcc-trunk/gcc/tree-vect-slp.cc:7610
0x1654786 vect_slp_function(function*)
        /repo/gcc-trunk/gcc/tree-vect-slp.cc:7698
0x165d3c1 execute
        /repo/gcc-trunk/gcc/tree-vectorizer.cc:1532
Please submit a full bug report, with preprocessed source (by using
-freport-bug).
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.

$ x86_64-pc-linux-gnu-gcc -v
Using built-in specs.
COLLECT_GCC=/repo/gcc-trunk/binary-latest-amd64/bin/x86_64-pc-linux-gnu-gcc
COLLECT_LTO_WRAPPER=/repo/gcc-trunk/binary-trunk-r13-4468-20221202115005-g76dd48f8956-checking-yes-rtl-df-extra-amd64/bin/../libexec/gcc/x86_64-pc-linux-gnu/13.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: /repo/gcc-trunk//configure --enable-languages=c,c++
--enable-valgrind-annotations --disable-nls --enable-checking=yes,rtl,df,extra
--with-cloog --with-ppl --with-isl --build=x86_64-pc-linux-gnu
--host=x86_64-pc-linux-gnu --target=x86_64-pc-linux-gnu
--with-ld=/usr/bin/x86_64-pc-linux-gnu-ld
--with-as=/usr/bin/x86_64-pc-linux-gnu-as --disable-libstdcxx-pch
--prefix=/repo/gcc-trunk//binary-trunk-r13-4468-20221202115005-g76dd48f8956-checking-yes-rtl-df-extra-amd64
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 13.0.0 20221202 (experimental) (GCC)

             reply	other threads:[~2022-12-03 14:20 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-03 14:20 zsojka at seznam dot cz [this message]
2022-12-04 19:20 ` [Bug tree-optimization/107956] " pinskia at gcc dot gnu.org
2022-12-04 19:25 ` pinskia at gcc dot gnu.org
2022-12-04 19:29 ` pinskia at gcc dot gnu.org
2022-12-05  8:08 ` rguenth at gcc dot gnu.org
2022-12-05  8:12 ` cvs-commit at gcc dot gnu.org
2022-12-05  8:14 ` cvs-commit at gcc dot gnu.org
2022-12-05  8:14 ` rguenth at gcc dot gnu.org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-107956-4@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).