This is the mail archive of the
mailing list for the GCC project.
Re: [RFC] Consider lrotate const rotation in vectorizer
- From: Segher Boessenkool <segher at kernel dot crashing dot org>
- To: Richard Biener <richard dot guenther at gmail dot com>
- Cc: Jakub Jelinek <jakub at redhat dot com>, "Kewen.Lin" <linkw at linux dot ibm dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>, Richard Sandiford <richard dot sandiford at arm dot com>, Bill Schmidt <wschmidt at linux dot ibm dot com>
- Date: Wed, 17 Jul 2019 08:48:39 -0500
- Subject: Re: [RFC] Consider lrotate const rotation in vectorizer
- References: <firstname.lastname@example.org> <20190715085929.GO2125@tucnak> <email@example.com> <firstname.lastname@example.org> <CAFiYyc1rVc=GsJTN1w9B5DAGATjrcb7vYp8UH1Sqjbm-G2vZzQ@mail.gmail.com> <20190717105432.GG2125@tucnak> <CAFiYyc2bUuQdVLoyhEoZBAbAcN-Rb0FuTmV+GFOhv4dEwasmEg@mail.gmail.com>
On Wed, Jul 17, 2019 at 01:32:50PM +0200, Richard Biener wrote:
> On Wed, Jul 17, 2019 at 12:54 PM Jakub Jelinek <email@example.com> wrote:
> Ick. I wouldn't even touch SHIFT_COUNT_TRUNCATED with a 10-foot pole
> here. And for rotates we can simply always truncate constant amounts to
> the rotated operands width, no? For non-constant ones I fear targets
> would need to support both to get reliable expansion.
SHIFT_COUNT_TRUNCATED has no meaning for rotate instructions, as far as
I can see. Mathematically it doesn't, and are there any CPUs that fail
for it for no reason? Any archs where some rotate amounts give
undefined results? So if this is true, SHIFT_COUNT_TRUNCATED can be
treated as always *on* for rotates.