public inbox for gcc-cvs@sourceware.org help / color / mirror / Atom feed
From: Andrew Pinski <pinskia@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org Subject: [gcc r12-6061] Improve location for new statements in match-and-simplify phiopt Date: Sun, 19 Dec 2021 07:16:57 +0000 (GMT) [thread overview] Message-ID: <20211219071657.87C923858401@sourceware.org> (raw) https://gcc.gnu.org/g:d957d250942b130142c62afa1a67146b655b91d7 commit r12-6061-gd957d250942b130142c62afa1a67146b655b91d7 Author: Andrew Pinski <apinski@marvell.com> Date: Sat Dec 18 11:52:37 2021 +0000 Improve location for new statements in match-and-simplify phiopt Before match-and-simplify was used in phiot, the location of the new stamtents were all of that of the conditional, this adds that back as I did not realize gimple_simplify didn't do that for you. OK? Bootstrapped and tested on x86_64 with no regressions. gcc/ChangeLog: * tree-ssa-phiopt.c (gimple_simplify_phiopt): Annotate the new sequence with the location of the conditional statement. Diff: --- gcc/tree-ssa-phiopt.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/gcc/tree-ssa-phiopt.c b/gcc/tree-ssa-phiopt.c index 3eac9b1ce46..714deab005a 100644 --- a/gcc/tree-ssa-phiopt.c +++ b/gcc/tree-ssa-phiopt.c @@ -900,6 +900,8 @@ gimple_simplify_phiopt (bool early_p, tree type, gimple *comp_stmt, result = maybe_push_res_to_seq (&op, &seq1); if (result) { + if (loc != UNKNOWN_LOCATION) + annotate_all_with_location (seq1, loc); gimple_seq_add_seq_without_update (seq, seq1); return result; } @@ -929,6 +931,8 @@ gimple_simplify_phiopt (bool early_p, tree type, gimple *comp_stmt, result = maybe_push_res_to_seq (&op1, &seq1); if (result) { + if (loc != UNKNOWN_LOCATION) + annotate_all_with_location (seq1, loc); gimple_seq_add_seq_without_update (seq, seq1); return result; }
reply other threads:[~2021-12-19 7:16 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=20211219071657.87C923858401@sourceware.org \ --to=pinskia@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).