public inbox for gcc-cvs@sourceware.org help / color / mirror / Atom feed
From: Tamar Christina <tnfchris@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org Subject: [gcc r13-1975] middle-end: Guard value_replacement and store_elim from seeing diamonds. Date: Fri, 5 Aug 2022 13:54:14 +0000 (GMT) [thread overview] Message-ID: <20220805135414.1AC54385702C@sourceware.org> (raw) https://gcc.gnu.org/g:1878ab3650d8c646a4db364df388adaec2a29870 commit r13-1975-g1878ab3650d8c646a4db364df388adaec2a29870 Author: Tamar Christina <tamar.christina@arm.com> Date: Fri Aug 5 14:53:28 2022 +0100 middle-end: Guard value_replacement and store_elim from seeing diamonds. This excludes value_replacement and store_elim from diamonds as they don't handle the form properly. gcc/ChangeLog: PR middle-end/106534 * tree-ssa-phiopt.cc (tree_ssa_phiopt_worker): Guard the value_replacement and store_elim from diamonds. Diff: --- gcc/tree-ssa-phiopt.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gcc/tree-ssa-phiopt.cc b/gcc/tree-ssa-phiopt.cc index ef4c0b78f4e..0191b9cb254 100644 --- a/gcc/tree-ssa-phiopt.cc +++ b/gcc/tree-ssa-phiopt.cc @@ -283,7 +283,7 @@ tree_ssa_phiopt_worker (bool do_store_elim, bool do_hoist_loads, bool early_p) || (e1->flags & EDGE_FALLTHRU) == 0) continue; - if (do_store_elim) + if (do_store_elim && !diamond_p) { /* Also make sure that bb1 only have one predecessor and that it is bb. */ @@ -310,7 +310,7 @@ tree_ssa_phiopt_worker (bool do_store_elim, bool do_hoist_loads, bool early_p) /* Value replacement can work with more than one PHI so try that first. */ - if (!early_p) + if (!early_p && !diamond_p) for (gsi = gsi_start (phis); !gsi_end_p (gsi); gsi_next (&gsi)) { phi = as_a <gphi *> (gsi_stmt (gsi));
reply other threads:[~2022-08-05 13:54 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=20220805135414.1AC54385702C@sourceware.org \ --to=tnfchris@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).