[simplify-rtx][2/2] Simplify - (y ? -x : x) -> (!y ? -x : x)
commit5ced42f848b676f2528f544c99283bb49d76c5a6
authorktkachov <ktkachov@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 20 Jul 2015 12:51:45 +0000 (20 12:51 +0000)
committerktkachov <ktkachov@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 20 Jul 2015 12:51:45 +0000 (20 12:51 +0000)
treeb199851fd64c33575ae6c054bb768b03fabaf4d8
parentb8783ab25fcbe89a9268537eb21c9173ca79eb97
[simplify-rtx][2/2] Simplify - (y ? -x : x) -> (!y ? -x : x)

* simplify-rtx.c (simplify_unary_operation_1, NEG case):
(neg (x ? (neg y) : y)) -> !x ? (neg y) : y.

* gcc.target/aarch64/neg_abs_1.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@225997 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ChangeLog
gcc/simplify-rtx.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/aarch64/neg_abs_1.c [new file with mode: 0644]