[PATCH v2]: Optimize a >= 0 && b >= 0 to (a | b) >= 0 [PR95731]

Joe Ramsay Joe.Ramsay@arm.com
Fri Jul 10 11:28:13 GMT 2020


Hi!

Apologies, resending as I previously attached the wrong patch file. This is a fix for PR95731, which adds a new pattern to simplify a >= 0 && b >= 0 to (a | b) >= 0. Bootstrapped and tested on x86_linux and aarch64_linux. Any comments are appreciated.

Thanks,
Joe

gcc/ChangeLog:

2020-05-20  Joe Ramsay  <joe.ramsay@arm.com<mailto:joe.ramsay@arm.com>>

        * match.pd: New simplication.

gcc/testsuite/ChangeLog:

2020-05-20  Joe Ramsay  <joe.ramsay@arm.com<mailto:joe.ramsay@arm.com>>

        * gcc.dg/tree-ssa/pr95731-1.c: New test.
        * gcc.dg/tree-ssa/pr95731-2.c: New test.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: pr95731.diff
Type: application/octet-stream
Size: 2399 bytes
Desc: pr95731.diff
URL: <https://gcc.gnu.org/pipermail/gcc-patches/attachments/20200710/59837e6a/attachment-0001.obj>


More information about the Gcc-patches mailing list