This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/70119] AArch64 should take advantage of implicit truncation of variable shift amount without defining SHIFT_COUNT_TRUNCATED
- From: "ubizjak at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 07 Mar 2016 12:13:12 +0000
- Subject: [Bug target/70119] AArch64 should take advantage of implicit truncation of variable shift amount without defining SHIFT_COUNT_TRUNCATED
- Auto-submitted: auto-generated
- References: <bug-70119-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70119
--- Comment #2 from UroÅ Bizjak <ubizjak at gmail dot com> ---
(In reply to Richard Biener from comment #1)
> Confirmed. SHIFT_COUNT_TRUNCATED should simply go away.
The same limitation is with x86. Shifts trucate the shift count, but bit-test
(BT) instructions take modulo of the bit offset operand. We have somehow hacked
around this by introducing <shift><mode>3_mask patterns to i386.md in the hope
that combine catches the masking, but the solution is far from optimal.