[Bug tree-optimization/79489] Strange static branch prediction for n != 0
marxin at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Jun 21 13:07:00 GMT 2017
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79489
--- Comment #7 from Martin Liška <marxin at gcc dot gnu.org> ---
Author: marxin
Date: Wed Jun 21 12:51:46 2017
New Revision: 249450
URL: https://gcc.gnu.org/viewcvs?rev=249450&root=gcc&view=rev
Log:
Make early return predictor more precise.
2017-06-21 Martin Liska <mliska@suse.cz>
PR tree-optimization/79489
* gimplify.c (maybe_add_early_return_predict_stmt): New
function.
(gimplify_return_expr): Call the function.
* predict.c (tree_estimate_probability_bb): Remove handling
of early return.
* predict.def: Update comment about early return predictor.
* gimple-predict.h (is_gimple_predict): New function.
* predict.def: Change default value of early return to 66.
* tree-tailcall.c (find_tail_calls): Skip GIMPLE_PREDICT
statements.
* passes.def: Put pass_strip_predict_hints to the beginning of
IPA passes.
Modified:
trunk/gcc/ChangeLog
trunk/gcc/gimple-low.c
trunk/gcc/gimple-predict.h
trunk/gcc/gimplify.c
trunk/gcc/passes.def
trunk/gcc/predict.c
trunk/gcc/predict.def
trunk/gcc/tree-tailcall.c
More information about the Gcc-bugs
mailing list