summaryrefslogtreecommitdiff
path: root/gcc/predict.def
diff options
context:
space:
mode:
authorxur <xur@138bc75d-0d04-0410-961f-82ee72b054a4>2013-10-03 17:13:50 +0000
committerxur <xur@138bc75d-0d04-0410-961f-82ee72b054a4>2013-10-03 17:13:50 +0000
commit21853731b64c28fda96c7e277f6459b2a2993c56 (patch)
tree48352394b524e6a8198bc62633939861961f8a7e /gcc/predict.def
parenta0b513fbd5078a14ab7385bff2f521eea161e38c (diff)
downloadgcc-21853731b64c28fda96c7e277f6459b2a2993c56.tar.gz
* predict.c (tree_predict_by_opcode): Get the probability
for builtin_expect from param builtin_expect_probability. * params.def (BUILTIN_EXPECT_PROBABILITY): New parameter. * predict.def (PRED_BUILTIN_EXPECT_RELAXED): Fix comments. * doc/invoke.texi: Add documentation for builtin-expect-probability. * gcc.target/i386/cold-attribute-2.c: Fix the test by using original probability. * gcc.dg/tree-ssa/ipa-split-5.c: Ditto. * gcc.dg/tree-ssa/ipa-split-6.c: Ditto. --This li (t)ene, and those below, will be ignored-- M gcc/params.def M gcc/predict.def M gcc/ChangeLog M gcc/testsuite/gcc.dg/tree-ssa/ipa-split-5.c M gcc/testsuite/gcc.dg/tree-ssa/ipa-split-6.c M gcc/testsuite/gcc.target/i386/cold-attribute-2.c M gcc/predict.c M gcc/doc/invoke.texi git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203167 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/predict.def')
-rw-r--r--gcc/predict.def5
1 files changed, 4 insertions, 1 deletions
diff --git a/gcc/predict.def b/gcc/predict.def
index 0006233da35..f8dba66e871 100644
--- a/gcc/predict.def
+++ b/gcc/predict.def
@@ -57,7 +57,10 @@ DEF_PREDICTOR (PRED_UNCONDITIONAL, "unconditional jump", PROB_ALWAYS,
DEF_PREDICTOR (PRED_LOOP_ITERATIONS, "loop iterations", PROB_ALWAYS,
PRED_FLAG_FIRST_MATCH)
-/* Hints dropped by user via __builtin_expect feature. */
+/* Hints dropped by user via __builtin_expect feature. Note: the
+ probability of PROB_VERY_LIKELY is now overwritten by param
+ builtin_expect_probability with a default value of HITRATE(90).
+ Refer to param.def for details. */
DEF_PREDICTOR (PRED_BUILTIN_EXPECT, "__builtin_expect", PROB_VERY_LIKELY,
PRED_FLAG_FIRST_MATCH)