public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "amylaar at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/52267] a&~N where N has all the bits set up till a specific point can be folded to ((unsigned)a) < N
Date: Sat, 29 Jun 2013 20:08:00 -0000	[thread overview]
Message-ID: <bug-52267-4-J7Qs23Cg8r@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-52267-4@http.gcc.gnu.org/bugzilla/>

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

--- Comment #9 from Jorn Wolfgang Rennecke <amylaar at gcc dot gnu.org> ---
(In reply to Jorn Wolfgang Rennecke from comment #8)
> (In reply to Georg-Johann Lay from comment #7)
> 
> > I just rediced the test case to find this thinko; I don't know if there are
> > more because of the sheer amount of values in this program.
> 
> Here is a summary of the failing subtests / iteration counts:
> f2,f1: i == 6,7
> f4,f5,f3: i == 13,15,16,24,25,31
> f7,f8,f6: i == 10..12,23
> f11,f9: i == 11,13,15,24,25,31
> f12,f10: i == 11,13,15,24,25,26,31
> f17: i == 12,13
> f21: i == 21,22,38..45

I've tried to shift/mask the values / tests to fit 16 bit ints while keeping
to the spirit of the tests and leaving the int >= 32 bit case unchanged,
but the various leading bits, 0000/ffff masking, and 16 bit value comparisons
are just to intertwined for this to make any sense.

I think we should simply restrict the test to target { ! int16 } .


  parent reply	other threads:[~2013-06-29 20:08 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-16  3:51 [Bug tree-optimization/52267] New: " pinskia at gcc dot gnu.org
2012-02-16 20:40 ` [Bug tree-optimization/52267] " pinskia at gcc dot gnu.org
2012-03-09  4:15 ` pinskia at gcc dot gnu.org
2012-03-09 17:53 ` jakub at gcc dot gnu.org
2012-03-13 17:58 ` jakub at gcc dot gnu.org
2012-03-15 10:43 ` jakub at gcc dot gnu.org
2012-03-15 12:15 ` jakub at gcc dot gnu.org
2012-03-22 12:53 ` gjl at gcc dot gnu.org
2013-06-29 16:21 ` amylaar at gcc dot gnu.org
2013-06-29 16:24 ` pinskia at gcc dot gnu.org
2013-06-29 20:08 ` amylaar at gcc dot gnu.org [this message]
2013-07-04 16:20 ` amylaar 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-52267-4-J7Qs23Cg8r@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: 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).