public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "aldyh at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/97396] [11 Regression] ICE: Segmentation fault (in bounds_of_var_in_loop) Date: Tue, 13 Oct 2020 07:15:38 +0000 [thread overview] Message-ID: <bug-97396-4-mswkqFhDJO@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-97396-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97396 Aldy Hernandez <aldyh at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |amacleod at redhat dot com --- Comment #2 from Aldy Hernandez <aldyh at gcc dot gnu.org> --- In bounds_of_var_in_loop, evolution_part_in_loop_num is returning NULL: step = evolution_part_in_loop_num (chrec, loop->num); and we ICE while trying to calculate the range for STEP. This is for: (gdb) dd stmt qx.0_3 = PHI <qx.0_1(3)> (gdb) dd var qx.0_3 I'm not familiar with the SCEV code. It looks like NULL is a perfectly valid response from evolution_part_in_loop_num. Should we just bail if NULL? diff --git a/gcc/vr-values.c b/gcc/vr-values.c index da0b249278b..16f6c629f29 100644 --- a/gcc/vr-values.c +++ b/gcc/vr-values.c @@ -1827,6 +1827,8 @@ bounds_of_var_in_loop (tree *min, tree *max, range_query *query, init = initial_condition_in_loop_num (chrec, loop->num); step = evolution_part_in_loop_num (chrec, loop->num); + if (step == NULL_TREE) + return false; /* If INIT is an SSA with a singleton range, set INIT to said singleton, otherwise leave INIT alone. */
next prev parent reply other threads:[~2020-10-13 7:15 UTC|newest] Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-10-13 3:36 [Bug tree-optimization/97396] New: " asolokha at gmx dot com 2020-10-13 6:25 ` [Bug tree-optimization/97396] " rguenth at gcc dot gnu.org 2020-10-13 7:05 ` aldyh at gcc dot gnu.org 2020-10-13 7:15 ` aldyh at gcc dot gnu.org [this message] 2020-10-14 14:59 ` cvs-commit at gcc dot gnu.org 2020-10-14 15:06 ` aldyh 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-97396-4-mswkqFhDJO@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: linkBe 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).