+2001-01-12 Aldy Hernandez <aldyh@redhat.com>
+
+ * toplev.c (flag_guess_branch_prob): New.
+ (f_options): Add guess-branch-probability option.
+ (rest_of_decl_compilation): Only estimate branch probability if
+ flag set.
+ (main): set flag_guess_branch_prob.
+
+ * flags.h (flag_guess_branch_prob): New.
+
2001-01-15 DJ Delorie <dj@redhat.com>
* gcc.texi (Makefile): Add documentation for Makefile targets.
/* Perform a peephole pass before sched2. */
extern int flag_peephole2;
+/* Try to guess branch probablities. */
+extern int flag_guess_branch_prob;
+
/* -fbounded-pointers causes gcc to compile pointers as composite
objects occupying three words: the pointer value, the base address
of the referent object, and the address immediately beyond the end
/* This will perform a peephole pass before sched2. */
int flag_peephole2 = 0;
+/* This will try to guess branch probabilities. */
+int flag_guess_branch_prob = 0;
+
/* -fbounded-pointers causes gcc to compile pointers as composite
objects occupying three words: the pointer value, the base address
of the referent object, and the address immediately beyond the end
"Process #ident directives"},
{ "peephole2", &flag_peephole2, 1,
"Enables an rtl peephole pass run before sched2" },
+ { "guess-branch-probability", &flag_guess_branch_prob, 1,
+ "Enables guessing of branch probabilities" },
{"math-errno", &flag_errno_math, 1,
"Set errno after built-in math functions"},
{"bounded-pointers", &flag_bounded_pointers, 1,
flow_loops_find (&loops, LOOP_TREE);
/* Estimate using heuristics if no profiling info is available. */
- estimate_probability (&loops);
+ if (flag_guess_branch_prob)
+ estimate_probability (&loops);
if (rtl_dump_file)
flow_loops_dump (&loops, rtl_dump_file, NULL, 0);
#ifdef CAN_DEBUG_WITHOUT_FP
flag_omit_frame_pointer = 1;
#endif
+ flag_guess_branch_prob = 1;
}
if (optimize >= 2)