public inbox for gcc-cvs@sourceware.org help / color / mirror / Atom feed
From: Jiu Fu Guo <guojiufu@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org Subject: [gcc(refs/users/guojiufu/heads/personal-branch)] make sure prev is the phi, and next is for the same phi Date: Wed, 9 Jun 2021 04:55:37 +0000 (GMT) [thread overview] Message-ID: <20210609045538.389A63988038@sourceware.org> (raw) https://gcc.gnu.org/g:c05852b0ee2c946dc06555c6c5649d5de661dfab commit c05852b0ee2c946dc06555c6c5649d5de661dfab Author: Jiufu Guo <guojiufu@linux.ibm.com> Date: Wed Jun 9 12:54:52 2021 +0800 make sure prev is the phi, and next is for the same phi Diff: --- gcc/tree-ssa-loop-split.c | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/gcc/tree-ssa-loop-split.c b/gcc/tree-ssa-loop-split.c index 3d9cd2e4cc3..e01d44a6b28 100644 --- a/gcc/tree-ssa-loop-split.c +++ b/gcc/tree-ssa-loop-split.c @@ -1730,6 +1730,12 @@ analyze_idx_elements (class loop *loop, edge e, idx_elements &data) if (TREE_CODE (gimple_assign_rhs2 (stmt)) != INTEGER_CST) return false; inc_stmt = stmt; + tree prev = gimple_assign_rhs1 (stmt); + if (TREE_CODE (prev) != SSA_NAME) + return false; + stmt = filter_conversions (loop, prev, &small_type, &large_type); + if (stmt != phi) + return false; data.gc = gc; data.phi = phi; @@ -1921,12 +1927,11 @@ split_wrap_boundary (class loop *loop, edge e, tree no_wrap_cond) /* Version the loop. */ initialize_original_copy_tables (); basic_block cond_bb; - class loop *loop1 - = loop_version (loop, no_wrap_cond, &cond_bb, - profile_probability::very_likely (), - profile_probability::very_unlikely (), - profile_probability::very_likely (), - profile_probability::very_unlikely (), true); + loop_version (loop, no_wrap_cond, &cond_bb, + profile_probability::very_likely (), + profile_probability::very_unlikely (), + profile_probability::very_likely (), + profile_probability::very_unlikely (), true); free_original_copy_tables (); /* Insert the statements that feed COND. */
reply other threads:[~2021-06-09 4:55 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20210609045538.389A63988038@sourceware.org \ --to=guojiufu@gcc.gnu.org \ --cc=gcc-cvs@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).