Re: [PATCH] match.pd: Add abs with bitwise and pattern [PR106243]

2022-08-26 Thread Richard Biener via Gcc-patches
On Wed, Aug 10, 2022 at 7:11 PM Sam Feifer via Gcc-patches wrote: > > This patch adds a simplification to match.pd that was discussed on the > thread for pr106243. It simplifies the pattern, abs(x) & 1, to x & 1. > > There are also tests for the simplification in this patch. I couldn't > figure ou

[PATCH] match.pd: Add abs with bitwise and pattern [PR106243]

2022-08-10 Thread Sam Feifer via Gcc-patches
This patch adds a simplification to match.pd that was discussed on the thread for pr106243. It simplifies the pattern, abs(x) & 1, to x & 1. There are also tests for the simplification in this patch. I couldn't figure out how to get abs to work with vectors. If a test for that is necessary, could