PROB_ALWAYS, PRED_FLAG_FIRST_MATCH)
/* Branch containing goto is probably not taken. */
-DEF_PREDICTOR (PRED_CONTINUE, "continue", HITRATE (50), 0)
+DEF_PREDICTOR (PRED_CONTINUE, "continue", HITRATE (67), 0)
/* Branch to basic block containing call marked by noreturn attribute. */
DEF_PREDICTOR (PRED_NORETURN, "noreturn call", PROB_VERY_LIKELY,
DEF_PREDICTOR (PRED_COLD_FUNCTION, "cold function call", PROB_VERY_LIKELY,
PRED_FLAG_FIRST_MATCH)
-/* Loopback edge is taken. */
+/* Loopback edge is taken.
+ FIXME: This is currently disabled because loop_optimizer_init force
+ loops to have simple latches. */
DEF_PREDICTOR (PRED_LOOP_BRANCH, "loop branch", HITRATE (86),
PRED_FLAG_FIRST_MATCH)
/* Edge causing loop to terminate is probably not taken. */
-DEF_PREDICTOR (PRED_LOOP_EXIT, "loop exit", HITRATE (91),
+DEF_PREDICTOR (PRED_LOOP_EXIT, "loop exit", HITRATE (92),
PRED_FLAG_FIRST_MATCH)
-/* Edge causing loop to terminate by computing value used by later conditional.
- */
-DEF_PREDICTOR (PRED_LOOP_EXTRA_EXIT, "extra loop exit", HITRATE (91),
+/* Edge causing loop to terminate by computing value used by later
+ conditional. */
+DEF_PREDICTOR (PRED_LOOP_EXTRA_EXIT, "extra loop exit", HITRATE (83),
PRED_FLAG_FIRST_MATCH)
/* Pointers are usually not NULL. */
-DEF_PREDICTOR (PRED_POINTER, "pointer", HITRATE (85), 0)
-DEF_PREDICTOR (PRED_TREE_POINTER, "pointer (on trees)", HITRATE (85), 0)
+DEF_PREDICTOR (PRED_POINTER, "pointer", HITRATE (70), 0)
+DEF_PREDICTOR (PRED_TREE_POINTER, "pointer (on trees)", HITRATE (70), 0)
/* NE is probable, EQ not etc... */
-DEF_PREDICTOR (PRED_OPCODE_POSITIVE, "opcode values positive", HITRATE (79), 0)
-DEF_PREDICTOR (PRED_OPCODE_NONEQUAL, "opcode values nonequal", HITRATE (71), 0)
+DEF_PREDICTOR (PRED_OPCODE_POSITIVE, "opcode values positive", HITRATE (64), 0)
+DEF_PREDICTOR (PRED_OPCODE_NONEQUAL, "opcode values nonequal", HITRATE (66), 0)
DEF_PREDICTOR (PRED_FPOPCODE, "fp_opcode", HITRATE (90), 0)
-DEF_PREDICTOR (PRED_TREE_OPCODE_POSITIVE, "opcode values positive (on trees)", HITRATE (73), 0)
-DEF_PREDICTOR (PRED_TREE_OPCODE_NONEQUAL, "opcode values nonequal (on trees)", HITRATE (72), 0)
+DEF_PREDICTOR (PRED_TREE_OPCODE_POSITIVE, "opcode values positive (on trees)", HITRATE (64), 0)
+DEF_PREDICTOR (PRED_TREE_OPCODE_NONEQUAL, "opcode values nonequal (on trees)", HITRATE (66), 0)
DEF_PREDICTOR (PRED_TREE_FPOPCODE, "fp_opcode (on trees)", HITRATE (90), 0)
/* Branch guarding call is probably taken. */
-DEF_PREDICTOR (PRED_CALL, "call", HITRATE (71), 0)
-
-/* Branch causing function to terminate is probably not taken. */
-DEF_PREDICTOR (PRED_TREE_EARLY_RETURN, "early return (on trees)", HITRATE (61), 0)
-
-/* Branch containing goto is probably not taken. */
+DEF_PREDICTOR (PRED_CALL, "call", HITRATE (67), 0)
+
+/* Branch causing function to terminate is probably not taken.
+ FIXME: early return currently predicts code:
+ int foo (int a)
+ {
+ if (a)
+ bar();
+ else
+ bar2();
+ }
+ even though there is no return statement involved. We probably want to track
+ this from FE or retire the predictor. */
+DEF_PREDICTOR (PRED_TREE_EARLY_RETURN, "early return (on trees)", HITRATE (54), 0)
+
+/* Branch containing goto is probably not taken.
+ FIXME: Currently not used. */
DEF_PREDICTOR (PRED_GOTO, "goto", HITRATE (70), 0)
/* Branch ending with return constant is probably not taken. */
-DEF_PREDICTOR (PRED_CONST_RETURN, "const return", HITRATE (67), 0)
+DEF_PREDICTOR (PRED_CONST_RETURN, "const return", HITRATE (69), 0)
/* Branch ending with return negative constant is probably not taken. */
-DEF_PREDICTOR (PRED_NEGATIVE_RETURN, "negative return", HITRATE (96), 0)
+DEF_PREDICTOR (PRED_NEGATIVE_RETURN, "negative return", HITRATE (98), 0)
/* Branch ending with return; is probably not taken */
-DEF_PREDICTOR (PRED_NULL_RETURN, "null return", HITRATE (90), 0)
+DEF_PREDICTOR (PRED_NULL_RETURN, "null return", HITRATE (91), 0)
/* Branches to compare induction variable to a loop bound is
extremely likely. */
DEF_PREDICTOR (PRED_LOOP_IV_COMPARE_GUESS, "guess loop iv compare",
- PROB_VERY_LIKELY, 0)
+ HITRATE (98), 0)
/* Use number of loop iterations determined by # of iterations analysis
to set probability of branches that compares IV to loop bound variable. */
of memory or when trying to allocate an already allocated allocated or
deallocating an already deallocated allocatable. This predictor only
occurs when the user explicitly asked for a return status. By default,
- the code aborts, which is handled via PRED_NORETURN. */
-DEF_PREDICTOR (PRED_FORTRAN_FAIL_ALLOC, "fail alloc", PROB_VERY_LIKELY, 0)
+ the code aborts, which is handled via PRED_NORETURN.
+ FIXME: the hitrate really ought to be close to 100%. */
+DEF_PREDICTOR (PRED_FORTRAN_FAIL_ALLOC, "fail alloc", HITRATE (62), 0)
/* Branch leading to an I/O failure status are unlikely. This predictor is
used for I/O failures such as for invalid unit numbers. This predictor
DEF_PREDICTOR (PRED_FORTRAN_WARN_ONCE, "warn once", HITRATE (75), 0)
/* Branch belonging to a zero-sized array. */
-DEF_PREDICTOR (PRED_FORTRAN_SIZE_ZERO, "zero-sized array", HITRATE(70), 0)
+DEF_PREDICTOR (PRED_FORTRAN_SIZE_ZERO, "zero-sized array", HITRATE(99), 0)
/* Branch belonging to an invalid bound index, in a context where it is
standard conform and well defined but rather pointless and, hence, rather