public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "rguenth at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/63380] [5 Regression] Wrong constant folding Date: Wed, 08 Oct 2014 14:58:00 -0000 [thread overview] Message-ID: <bug-63380-4-PFuz4oDw4x@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-63380-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63380 --- Comment #3 from Richard Biener <rguenth at gcc dot gnu.org> --- Hmm. We end up with main () { int d.0_4; int e.1_5; int _7; int b.7_11; int a.8_12; <bb 2>: d.0_4 = d; e.1_5 = 1 >> d.0_4; e = e.1_5; _7 = 31 / 0; in the end. Which is caused by tail-merging (part of PRE) optimizing <bb 2>: d.0_4 = d; e.1_5 = 1 >> d.0_4; e = e.1_5; if (e.1_5 <= 0) goto <bb 10>; else goto <bb 3>; <bb 10>: goto <bb 4>; <bb 3>: _7 = 31 / 0; <bb 4>: by removing bb 3 as having no side-effect appearantly (_7 is unused). It produces <bb 2>: d.0_4 = d; e.1_5 = 1 >> d.0_4; e = e.1_5; <bb 3>: _7 = 31 / 0; <bb 4>: not sure how it ends up doing that (I suppose it has code to merge an if diamond).
next prev parent reply other threads:[~2014-10-08 14:58 UTC|newest] Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top 2014-09-26 9:45 [Bug tree-optimization/63380] New: " ishiura-compiler at ml dot kwansei.ac.jp 2014-10-02 15:01 ` [Bug tree-optimization/63380] [5 Regression] " mpolacek at gcc dot gnu.org 2014-10-06 12:05 ` rguenth at gcc dot gnu.org 2014-10-08 14:58 ` rguenth at gcc dot gnu.org [this message] 2014-10-09 8:18 ` rguenth at gcc dot gnu.org 2014-10-09 12:45 ` rguenth at gcc dot gnu.org 2014-10-10 11:06 ` rguenth 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-63380-4-PFuz4oDw4x@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).