This is the mail archive of the gcc-cvs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

r187661 - /branches/google/main/gcc/ChangeLog.g...


Author: tejohnson
Date: Fri May 18 16:53:58 2012
New Revision: 187661

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=187661
Log:
This change goes with r187660 (just adds the ChangeLog entry).

This patch adds heuristics to limit unrolling in loops with branches that may increase
branch mispredictions. It affects loops that are not frequently iterated, and that are
nested within a hot region of code that already contains many branch instructions.

2012-05-18   Teresa Johnson  <tejohnson@google.com>

	* doc/invoke.texi: Update the documentation with new params.
	* loop-unroll.c (loop_has_FP_comp): Remove function.
	(max_unroll_with_branches): New function.
	(decide_unroll_constant_iterations, decide_unroll_runtime_iterations):
        Add heuristic to avoid increasing branch mispredicts when unrolling.
	(limit_code_size, decide_peel_simple, decide_unroll_stupid): Retrieve
        number of branches from niter_desc instead of via function that walks
        loop.
	* loop-iv.c (get_simple_loop_desc): Invoke new analyze_loop_insns
        function, and add guards to enable this function to work for the
        outermost loop.
	* cfgloop.c (insn_has_fp_set, analyze_loop_insns): New functions.
        (num_loop_branches): Remove.
	* cfgloop.h (struct niter_desc): Added new fields to cache additional
        loop analysis information.
        (num_loop_branches): Remove.
	(analyze_loop_insns): Declare.
	* params.def (PARAM_MIN_ITER_UNROLL_WITH_BRANCHES): New param.
        (PARAM_UNROLL_OUTER_LOOP_BRANCH_BUDGET): Ditto.

Modified:
    branches/google/main/gcc/ChangeLog.google-main


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]