public inbox for gcc-cvs@sourceware.org help / color / mirror / Atom feed
From: Richard Biener <rguenth@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org Subject: [gcc r13-2640] middle-end/106909 - CTRL altering flag after folding Date: Tue, 13 Sep 2022 08:52:42 +0000 (GMT) [thread overview] Message-ID: <20220913085242.83166385116F@sourceware.org> (raw) https://gcc.gnu.org/g:2c867232df70d3de304714906b4198ecb262eb32 commit r13-2640-g2c867232df70d3de304714906b4198ecb262eb32 Author: Richard Biener <rguenther@suse.de> Date: Tue Sep 13 08:59:41 2022 +0200 middle-end/106909 - CTRL altering flag after folding The following makes sure to clear the CTRL altering flag when folding emits a __builitin_unreachable in place of a virtual call which now might become a trap. PR middle-end/106909 * gimple-fold.cc (gimple_fold_call): Clear the ctrl-altering flag of a unreachable call. Diff: --- gcc/gimple-fold.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/gcc/gimple-fold.cc b/gcc/gimple-fold.cc index a1704784bc9..9055cd8982d 100644 --- a/gcc/gimple-fold.cc +++ b/gcc/gimple-fold.cc @@ -5512,6 +5512,7 @@ gimple_fold_call (gimple_stmt_iterator *gsi, bool inplace) { location_t loc = gimple_location (stmt); gimple *new_stmt = gimple_build_builtin_unreachable (loc); + gimple_call_set_ctrl_altering (new_stmt, false); /* If the call had a SSA name as lhs morph that into an uninitialized value. */ if (lhs && TREE_CODE (lhs) == SSA_NAME)
reply other threads:[~2022-09-13 8:52 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=20220913085242.83166385116F@sourceware.org \ --to=rguenth@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).