flow.c (ior_reg_cond): Return NULL if ! add and rtx wasn't optimized.
authorJakub Jelinek <jakub@redhat.com>
Tue, 4 Dec 2001 09:33:17 +0000 (10:33 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Tue, 4 Dec 2001 09:33:17 +0000 (10:33 +0100)
commitb318748ff4b6a9256695a3e768d4a951dd4b8ca6
treef4cbf2a19a8962de46bab2e668b5770fcd6f9668
parent108b7d3d316599861369de7c7f9bfaef915c7bd3
flow.c (ior_reg_cond): Return NULL if ! add and rtx wasn't optimized.

* flow.c (ior_reg_cond): Return NULL if ! add and rtx wasn't optimized.
Return correct value if one of the subexpressions was optimized to
0 resp. 1.  Optimize (x | A) | x and (x & A) | x.
(and_reg_cond): Similarly.

* gcc.c-torture/compile/20011130-2.c: New test.

From-SVN: r47602
gcc/ChangeLog
gcc/flow.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.c-torture/compile/20011130-2.c [new file with mode: 0644]