From: Aldy Hernandez <aldyh@redhat.com>
To: Segher Boessenkool <segher@kernel.crashing.org>
Cc: Jakub Jelinek <jakub@redhat.com>,
GCC patches <gcc-patches@gcc.gnu.org>,
"MacLeod, Andrew" <amacleod@redhat.com>,
Richard Biener <richard.guenther@gmail.com>
Subject: Re: [PATCH] Rename nonzero_bits to known_zero_bits.
Date: Tue, 1 Nov 2022 17:33:13 +0100 [thread overview]
Message-ID: <CAGm3qMUvkJKQcB44gyXVqkhPj+JN=+GhkaXBjVe9TRgiquDS0A@mail.gmail.com> (raw)
In-Reply-To: <20221021180029.GY25951@gate.crashing.org>
Folks. I have decided to put this aside until the next release. I
originally wanted a simple rename, and reimplementing things to align
with rtl, etc, is beyond what I want to tackle on this late.
I'll archive this away, and revisit it when we implement the
irange::known_ones mask.
Thanks for your input.
Aldy
On Fri, Oct 21, 2022 at 8:01 PM Segher Boessenkool
<segher@kernel.crashing.org> wrote:
>
> On Fri, Oct 21, 2022 at 06:54:32PM +0200, Jakub Jelinek wrote:
> > On Fri, Oct 21, 2022 at 06:51:19PM +0200, Jakub Jelinek wrote:
> > > Agreed.
> > >
> > > I think maybe_nonzero_bits would be fine.
> >
> > Or yet another option is to change what we track and instead of
> > having just one bitmask have 2 as tree-ssa-ccp.cc does,
> > one bitmask says which bits are known to be always the same
> > and the other which specifies the values of those bits.
> > "For X with a CONSTANT lattice value X & ~mask == value & ~mask. The
> > zero bits in the mask cover constant values. The ones mean no
> > information."
>
> I am still working on making the RTL nonzero_bits use DF (and indeed I
> do a known_zero instead :-) ). This makes the special version in
> combine unnecessary: instead of working better than the generic version
> it is strictly weaker then. This change then makes it possible to use
> nonzero_bits in instruction conditions (without causing ICEs as now --
> passes after combine return a subset of the nonzero_bits the version in
> combine does, which can make insns no longer match in later passes).
>
> My fear is tracking twice as many bits might become expensive. OTOH
> ideally we can get rid of combine's reg_stat completely at some point
> in the future (which has all the same problems as combine's version of
> nonzero_bits: the values it returns depend on the order combine tried
> possible combinations).
>
> Storage requirements are the same for known_zero_bits and known_one_bits
> vs. known_bits and known_bit_values, but the latter is a bit more
> costly to compute, but more importantly it is usually a lot less
> convenient in use. (A third option is known_bits and known_zero_bits?)
>
>
> Segher
>
next prev parent reply other threads:[~2022-11-01 16:33 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-21 13:14 Aldy Hernandez
2022-10-21 16:45 ` Segher Boessenkool
2022-10-21 16:51 ` Jakub Jelinek
2022-10-21 16:54 ` Jakub Jelinek
2022-10-21 18:00 ` Segher Boessenkool
2022-11-01 16:33 ` Aldy Hernandez [this message]
2022-10-21 17:44 ` Segher Boessenkool
2022-10-24 7:21 ` Richard Biener
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='CAGm3qMUvkJKQcB44gyXVqkhPj+JN=+GhkaXBjVe9TRgiquDS0A@mail.gmail.com' \
--to=aldyh@redhat.com \
--cc=amacleod@redhat.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=jakub@redhat.com \
--cc=richard.guenther@gmail.com \
--cc=segher@kernel.crashing.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).