public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "rguenth at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/42117] VRP should do if-conversion
Date: Fri, 20 Nov 2009 13:12:00 -0000	[thread overview]
Message-ID: <20091120131234.10680.qmail@sourceware.org> (raw)
In-Reply-To: <bug-42117-11173@http.gcc.gnu.org/bugzilla/>



------- Comment #1 from rguenth at gcc dot gnu dot org  2009-11-20 13:12 -------
Confirmed.  We do see

x_2: [0, 1]  EQUIVALENCES: { x_3(D) } (1 elements)
y_11: [0, 1]  EQUIVALENCES: { y_5(D) } (1 elements)

but have no code that actually makes use of this information in

<bb 4>:
  if (x_3(D) != 0)
    goto <bb 5>;
  else
    goto <bb 6>;

<bb 5>:
  if (y_5(D) != 0)
    goto <bb 7>;
  else
    goto <bb 6>;

<bb 6>:

<bb 7>:
  # D.2047_1 = PHI <0(6), -1(3), -1(2), 1(5)>
  return D.2047_1;

which we want to if-convert to

<bb 4>:
  tmp = x_3 & y_5;

<bb 7>:
  # D.2047_1 = PHI <tmp(4), -1(3), -1(2)>

but there is no code in VRP that does if-conversion.


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|normal                      |enhancement
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
   Last reconfirmed|0000-00-00 00:00:00         |2009-11-20 13:12:34
               date|                            |
            Summary|VRP fails to get rid of     |VRP should do if-conversion
                   |compares                    |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42117


  reply	other threads:[~2009-11-20 13:12 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-11-20 12:49 [Bug tree-optimization/42117] New: VRP fails to get rid of compares krebbel at gcc dot gnu dot org
2009-11-20 13:12 ` rguenth at gcc dot gnu dot org [this message]
     [not found] <bug-42117-4@http.gcc.gnu.org/bugzilla/>
2021-06-06  6:24 ` [Bug tree-optimization/42117] VRP should do if-conversion pinskia at gcc dot gnu.org
2021-07-06  8:01 ` pinskia at gcc dot gnu.org
2023-06-10  2:12 ` pinskia 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=20091120131234.10680.qmail@sourceware.org \
    --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: link
Be 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).