public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Steve Ellcey <sellcey@cavium.com>
To: Jeff Law <law@redhat.com>, gcc-patches <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH/AARCH64] Improve aarch64 conditional compare usage
Date: Thu, 29 Jun 2017 18:30:00 -0000	[thread overview]
Message-ID: <1498761023.13519.6.camel@cavium.com> (raw)
In-Reply-To: <01f3fdcc-c3cc-e09f-f8e6-4084502e4a63@redhat.com>

On Tue, 2017-06-27 at 16:45 -0600, Jeff Law wrote:

> > +  /* If we have a boolean variable allow it and generate a compare
> > +     to zero reg when expanding.  */
> > +  if (!g)
> > +    return (TREE_CODE (TREE_TYPE (t)) == BOOLEAN_TYPE);
> Depending on how you use T, you might be better off checking T's range
> and considering anything with the [0,1] range as a boolean.  That would
> also pick up the case where T was set via a comparison, or the output of
> a PHI with arguments that are all [0,1], etc.  I've found that to be a
> useful improvement in a couple places.
> 
> See ssa_name_has_boolean_range.  I don't consider it a requirement for
> this patch to go forward, but more something you might want to
> investigate as a future improvement.
> 
> OK for the trunk.  Sorry about the delay.
> 
> jeff

Thanks Jeff, I checked this in.  I hadn't considered integers with a
restricted range but it might be worth adding.  I will look into that.

Steve Ellcey
sellcey@cavium.com

  reply	other threads:[~2017-06-29 18:30 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-01 17:16 Steve Ellcey
2017-06-27 22:46 ` Jeff Law
2017-06-29 18:30   ` Steve Ellcey [this message]
2017-06-16 17:06 Steve Ellcey
2017-06-20 13:58 ` James Greenhalgh
2017-06-20 15:21   ` Steve Ellcey

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=1498761023.13519.6.camel@cavium.com \
    --to=sellcey@cavium.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=law@redhat.com \
    /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).