re PR middle-end/81914 (gcc 7.1 generates branch for code which was branchless in...
authorJakub Jelinek <jakub@redhat.com>
Tue, 19 Dec 2017 16:43:04 +0000 (17:43 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Tue, 19 Dec 2017 16:43:04 +0000 (17:43 +0100)
commit972027748c2aa9f59ef1ab534763b0d6ed37b76d
tree4b28276b4df98bc91aaec6e977cad6164d0e067c
parent41bc2c0b217d727aa516978cac54594d00498411
re PR middle-end/81914 (gcc 7.1 generates branch for code which was branchless in earlier gcc version)

PR middle-end/81914
* predict.c (zero_one_minusone): New function.
(apply_return_prediction): Avoid return prediction for functions
returning only -1, 0 and 1 values, unless they only return -1 and 0
or 0 and 1.

From-SVN: r255829
gcc/ChangeLog
gcc/predict.c