diff options
| author | Uros Bizjak <ubizjak@gmail.com> | 2026-01-28 21:57:47 +0100 |
|---|---|---|
| committer | Uros Bizjak <ubizjak@gmail.com> | 2026-01-28 21:59:19 +0100 |
| commit | b20e68022a3f49010028dc01dab570c68071e3db (patch) | |
| tree | 11aea5daf409bc95a5baf50b0176369d6049a0ad /libjava/gnu/java/security/ber/BER.java | |
| parent | cb0d29db88e367a709f32e49bfa540e54db02f82 (diff) | |
| download | gcc-b20e68022a3f49010028dc01dab570c68071e3db.zip gcc-b20e68022a3f49010028dc01dab570c68071e3db.tar.gz gcc-b20e68022a3f49010028dc01dab570c68071e3db.tar.bz2 | |
i386: Use x >> ~y for x >> 31-y [PR36503]
x86 targets mask 32-bit shifts with a 5-bit mask (and 64-bit with 6-bit mask),
so they can use x >> ~y instead of x >> 31-y.
The optimization converts:
movl $31, %ecx
subl %esi, %ecx
sall %cl, %eax
to:
notl %ecx
sall %cl, %eax
PR target/36503
gcc/ChangeLog:
* config/i386/i386.md (*<insn:any_shift><mode:SWI48>3_sub):
Also allow operands[3] & (<mode_bitsize>-1) == (<mode_bitsize>-1)
in insn condition. Emit NOT RTX instead of NEG RTX in this case.
(*<insn:any_shift><mode:SWI48>3_sub_1): Ditto.
gcc/testsuite/ChangeLog:
* gcc.target/i386/pr36503-5.c: New test.
* gcc.target/i386/pr36503-6.c: New test.
Diffstat (limited to 'libjava/gnu/java/security/ber/BER.java')
0 files changed, 0 insertions, 0 deletions
